|
Jenny Sparrow
Registered User
Join date: 11 Mar 2007
Posts: 7
|
01-22-2009 06:36
Hello, I've been reading the forums looking for some information but have not been able to find. Is it even possible to add a script to a prim that on touch can change the persons time of day setting? Example: On touching the prim you receive an option to set your world/time of day setting to mid-day. So if it's night, someone can just click to turn it to day time? Or, even better, on contact get the option, such as a welcome mat at the landing area offering to change that AV's setting to mid-day. Thanks for any help! 
|
|
Winter Seale
Registered User
Join date: 27 Dec 2006
Posts: 30
|
01-22-2009 07:05
The only way that I know to do this through a script is Restrained Life's @setenv suite of commands. But this doesn't seem like a very good solution for you. * http://wiki.secondlife.com/wiki/LSL_Protocol/RestrainedLifeAPI
_____________________
~~ Winter Seale ~~ http://winterseale.com/ ~~
|
|
Jenny Sparrow
Registered User
Join date: 11 Mar 2007
Posts: 7
|
01-22-2009 08:48
Thanks, I think I see the command that just might do this... but its over my head. "Force change an environment setting : @setenv_<setting>:<value>=force Implemented in v1.14 Forces the viewer to change a particular environment setting (time of day or Windlight) and set it to <value>. This command is actually a package of many sub-commands, that are regrouped under "@setenv_...", for instance "@setenv_daytime:0.5=force", "@setenv_bluehorizonr:0.21=force" etc." My limited understanding thinks this line is the key part. "@setenv_daytime:0.5=force", Is this correct? And can this be worked into a script to do as listed above? As in a welcome floor mat.
|
|
Winter Seale
Registered User
Join date: 27 Dec 2006
Posts: 30
|
01-22-2009 10:28
Yeah, probably the easiest way would be to have an invisible prim that people collide with where your welcome mat is. Something like this: integer RLV_CHANNEL = -1812221819; default { collision_start(integer num) { integer ii; for ( ii=0; ii<num; ++ii ) { llWhisper( RLV_CHANNEL, "SetTimeOfDay," + (string)llDetectedOwner(ii) + ",@setenv_daytime:0.5=force" ); } } }
Though do realize that this will only work for people who are: 1. Using a viewer implementing Restrained Life. (ie, the official Restrained Life viewer, Cool Viewer with the option on, etc). 2. Wearing a Restrained Life Relay. How likely these things are depends on venue. =p Still, it doesn't hurt to have this in addition to having instructions for people to set their time-of-day on their own.
_____________________
~~ Winter Seale ~~ http://winterseale.com/ ~~
|
|
Jenny Sparrow
Registered User
Join date: 11 Mar 2007
Posts: 7
|
01-22-2009 10:51
Ok, I see. So even getting this working would mean it only works on a very small % of people (next to zero).
Well, had to ask. Thanks for looking into it for me.
|