Innula Zenovka Posted May 8, 2011 Share Posted May 8, 2011 I'm making some items, containing animations, that people can rez from a hud. I want the items to delete themselves after use, but not immediately (so that if the user clicks the wrong button and unseats him- or herself, there's a grace period to get back on). What's safer -- start a timer on rez and start, reset and stop it in the changed event, or do the same with PRIM_TEMP_ON_REZ (or doesn't it matter?)? Link to comment Share on other sites More sharing options...
Jenni Darkwatch Posted May 8, 2011 Share Posted May 8, 2011 Temp has no grace period... the timer counts down even if the avi sits on it, meaning if they stand up a minute later the object will immediately disappear. Removing and re-applying the temp property also does not reset that temp timer. I guess you'll have to go with a timer. Link to comment Share on other sites More sharing options...
Rolig Loon Posted May 8, 2011 Share Posted May 8, 2011 You always have more control with a timer. It sounds like you really need that control too, if you want to limit the buyer to one-time use but guarantee a grace period. Since your rezzed object will have a script in it anyway, there's no overhead cost to adding a timer to it. Link to comment Share on other sites More sharing options...
Void Singer Posted May 8, 2011 Share Posted May 8, 2011 not that it's helpful in your use case, but if the temp rez flag expires while someone is sitting on it and THEN is set to non-temp and back, the timeout period will restart I'm assuming that your use case is for cleanup, especially in the case of no-script areas? if so making it temp rez to start, and then setting it to normal when the av sits and starting a timer to use llDie when they get up would be the ideal solution.... in that case, if it's no script land, the temp rez will take care of cleanup, (and the object wouldn't work anyways), and if it's normal land, once the sit, the script can take care of the rest. Link to comment Share on other sites More sharing options...
Jenni Darkwatch Posted May 9, 2011 Share Posted May 9, 2011 Neat trick, Void. Thanks for sharing. Link to comment Share on other sites More sharing options...
Innula Zenovka Posted May 9, 2011 Author Share Posted May 9, 2011 Thanks, everyone. Void's method seems ideal, combining the advantages of both. There's one thing I don't understand, though. If I set TEMP to FALSE when I sit down and then back to TRUE when I stand up, does the timeout period always restart or does it depend on whether the initial timeout period has expired while TEMP was FALSE or what? Link to comment Share on other sites More sharing options...
Void Singer Posted May 9, 2011 Share Posted May 9, 2011 relevant details here but long and short prim goes temp 60sec timeout is started if prim goes to inventory, timer is paused but not reset (continues from where it left off when rerezzed) if prim is made non-temp before time gets to 60 timeout is NOT halted if prim is temp when timeout is reached, it derezzes, otherwise timeout is reset to zero (and stays there until prim is temp again) for your case, just don't set it back to temp via script, and instead rely on die, since the script had to be working to set it non-temp to begin with Link to comment Share on other sites More sharing options...
Recommended Posts
Please take a moment to consider if this thread is worth bumping.
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now