Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Rez Event Never gets called!

CamperDave Proudfoot
(_)|33P\ 1337 $xor
Join date: 16 Sep 2004
Posts: 205
05-18-2005 12:44
CODE


build()
{
llOwnerSay("Starting Build");

llRezObject("The Rest TEMP", <246.407,143.892,34.833>, ZERO_VECTOR, ZERO_ROTATION, 42);


llRezObject("Back Wall TEMP", <246.465,158.591,35.589>, ZERO_VECTOR, ZERO_ROTATION, 42);


llSetTimerEvent(79.8);
}


default
{
state_entry()
{
build();
}

timer()
{
build();
}
}


\
NOTHING happens. No build(); ever gets called. why? :confused:
_____________________
The PWNED SHOP!


List of Cool Things I've done first... I think
  1. Put on sale a key mod that makes SL more like an FPS
  2. Made my own custom attachment points - looking for a good use
  3. Found "secret" login screen.
  4. Created a way to call Java methods from LSL --> Thread
Brian Mifflin
Scripting Addict
Join date: 15 Dec 2004
Posts: 182
05-18-2005 12:45
state_entry only gets called when the script is first run, on rez would be the on_rez(integer param) {} event
_____________________
CamperDave Proudfoot
(_)|33P\ 1337 $xor
Join date: 16 Sep 2004
Posts: 205
Reset didn't help either
05-18-2005 12:48
I tried ressetting the script. When I can get in-world, I'll try that. :cool:
_____________________
The PWNED SHOP!


List of Cool Things I've done first... I think
  1. Put on sale a key mod that makes SL more like an FPS
  2. Made my own custom attachment points - looking for a good use
  3. Found "secret" login screen.
  4. Created a way to call Java methods from LSL --> Thread
Ushuaia Tokugawa
Nobody of Consequence
Join date: 22 Mar 2005
Posts: 268
05-18-2005 12:50
From: CamperDave Proudfoot

NOTHING happens. No build(); ever gets called. why?


It should get called right after the script compiles.

Are you even seeing the object say "Starting Build"? If so, your object is probably more than 10 meters away from the coordinates you hard coded in.
CamperDave Proudfoot
(_)|33P\ 1337 $xor
Join date: 16 Sep 2004
Posts: 205
10m Restriction!
05-18-2005 14:11
I might have to check the 10m restriction! I didn't remember that! :eek:
_____________________
The PWNED SHOP!


List of Cool Things I've done first... I think
  1. Put on sale a key mod that makes SL more like an FPS
  2. Made my own custom attachment points - looking for a good use
  3. Found "secret" login screen.
  4. Created a way to call Java methods from LSL --> Thread
CamperDave Proudfoot
(_)|33P\ 1337 $xor
Join date: 16 Sep 2004
Posts: 205
Still no good.
05-18-2005 14:19
Object coordinates:

X: 248.490

Y: 152.253

Z: 31.854

That's withing 10m, I added on_rez, re-rezed and still no good. :confused:
_____________________
The PWNED SHOP!


List of Cool Things I've done first... I think
  1. Put on sale a key mod that makes SL more like an FPS
  2. Made my own custom attachment points - looking for a good use
  3. Found "secret" login screen.
  4. Created a way to call Java methods from LSL --> Thread
Douglas Callahan
Fresh Prince Of SL
Join date: 2 Jul 2004
Posts: 349
05-18-2005 18:10
lol, I bet the box for "Running" is not checked.

Check for us.
_____________________
Other than that, Mrs. Lincoln, how was the play?
CamperDave Proudfoot
(_)|33P\ 1337 $xor
Join date: 16 Sep 2004
Posts: 205
I feel dumb.
05-18-2005 19:09
It wasn't.
_____________________
The PWNED SHOP!


List of Cool Things I've done first... I think
  1. Put on sale a key mod that makes SL more like an FPS
  2. Made my own custom attachment points - looking for a good use
  3. Found "secret" login screen.
  4. Created a way to call Java methods from LSL --> Thread
Chage McCoy
Aerodrome Janitor
Join date: 23 Apr 2004
Posts: 336
05-18-2005 19:37
timer() only gets called when you set llSetTimerEvent(float time). The way you have that written leaves the opportunity for build() not to be called, and therefore nothing happens.

state_entry() only gets called when the script is saved or reset or first dropped into a prim, but not after that.

generally I script with:

init() { do stuff }

state_entry() { init(); }
on_rez (integer parms) { init(); }
Douglas Callahan
Fresh Prince Of SL
Join date: 2 Jul 2004
Posts: 349
05-18-2005 19:52
From: CamperDave Proudfoot
It wasn't.


wo0t, I fixed something, yay!
Too bad the only way I knew that is because I've spent quite a few hours debugging only to see that stupid little box blank. :p
_____________________
Other than that, Mrs. Lincoln, how was the play?