|
Keldaire DuCasse
Registered User
Join date: 24 Jan 2007
Posts: 18
|
02-10-2007 06:35
Is there a way to detect how long an Agent has been on a particlar sim?
Or is there a way to tell a script to run only once per agent on a sim? So that even if they trigger the script again, the script will only run once per session on a Sim.
I can't just use on_rez because I'm tying a collision event to it.
If I can pull the length of time they've been on the Sim, I think that will work too, so if they have been there longer than a couple minutes, it won't run.
|
|
Newgate Ludd
Out of Chesse Error
Join date: 8 Apr 2005
Posts: 2,103
|
02-10-2007 08:38
There is no direct way to look up exactly how long someone has been in a specific sim via a linden supplied function. However you could use a periodic timer and the on rez event handler to look up which sim they are in using llGetRegionName and update a timer accordingly.
Not 100% sure from your description why you cant use on rez?
|
|
Keldaire DuCasse
Registered User
Join date: 24 Jan 2007
Posts: 18
|
02-10-2007 08:49
Well, what the Prim to return a string or two upon a collision event, but then not repeat the string even if they collide again.
|
|
Newgate Ludd
Out of Chesse Error
Join date: 8 Apr 2005
Posts: 2,103
|
02-10-2007 09:15
From: Keldaire DuCasse Well, what the Prim to return a string or two upon a collision event, but then not repeat the string even if they collide again. Still not 100% sure why that precludes using on_rez but thats neither here nor there. You could switch state once the system has been activted once so that it no longer processes collisions or use a variable for the same purpose?
|