These forums are CLOSED. Please visit the new forums HERE
Activate Scripts |
|
Nexus Nash
Undercover Linden
![]() Join date: 18 Dec 2002
Posts: 1,084
|
01-09-2004 22:12
Ok, I wish there was a way to turn a script on that has been dropped in an other object by an object. I know it can result in virus like scripting... but make an execption... like send && recieving object must be owned by the same person!
_____________________
|
Christopher Omega
Oxymoron
Join date: 28 Mar 2003
Posts: 1,828
|
01-10-2004 01:31
I TOTALLY agree with this product and/or service.
My reasons: I *loathe* manual labor. If I have to go around updating a script in my objects that became outdated, I dont want to go through the trouble of doing it all manually. This can help alot with that. Also, Im working on a network, and this would help in updating the scripts in remote network components. ==Chris |
Xylor Baysklef
Scripting Addict
![]() Join date: 4 May 2003
Posts: 109
|
01-10-2004 02:13
Yes, this would *really* help development, not to mention the many other uses it has.
As a side note, you can do script updates to a limited degree now. What I do is have one master script and slave scripts on all the objects I am working on which need script updates. The master script tells the slave scripts to remove old versions in each object's inventory, and then the slaves send their link numbers to the master so it can send an update of the new version to those objects. Then, once all the new scripts are in place, you select the objects which need to be updated (you can select the whole linked object, or you can cheat and use the "Select Texture" setting to select one texture on each of the objects you want to update), and go to Tools | Recompile Scripts in Selection. This activates the copied scripts. I hate manually updating, and this workaround has saved a lot of time, but I'd much rather not have to recompile all the new scripts. Xylor |
Azelda Garcia
Azelda Garcia
Join date: 3 Nov 2003
Posts: 819
|
01-10-2004 02:45
Bump bump bump!
The way this can work without introducing viruses is: - if an object injects a script into another object it is disactivated by default (this is current behavior) - you can add beforehand a script to the object which with a changed inventory event. When it sees a new script in the object, it will validate it (many ways of doign this) and then activate it What is missing currently is the possibility to activate a script via another scirpt in the same object, if the script was injected from anothre object. Summary: - it should be possible to activate any script in an object using llSetScriptState( scriptname, TRUE ); Azelda |
Azelda Garcia
Azelda Garcia
Join date: 3 Nov 2003
Posts: 819
|
01-10-2004 02:48
|
Bosozoku Kato
insurrectionist midget
![]() Join date: 16 Jun 2003
Posts: 452
|
01-10-2004 03:28
llSetScriptState(string_name_of_script, integer run)
set run to TRUE to activate the script. set to FALSE to deactivate it. Say the script "ThisScript" exists in an object, and you drop in "ThatScript". That script is: CODE
..ThisScript is now off. The reverse would be true if you set it to TRUE. This might require that you own the object you dropped the script into. I haven't tried using it on objects/scripts I don't own (which could open up a can of worms for abuse). Scripts can start other scripts, I've done it -- it's quite a handy little function. Edit Seems like you're putting a non-running script into the object. You could activate this new, non-running script with a secondary (preexisting) script via the changed() event. CODE
Bos |
Azelda Garcia
Azelda Garcia
Join date: 3 Nov 2003
Posts: 819
|
01-10-2004 03:31
Yeah, Bos, check the following thread:
/invalid_link.html Basically you cannot currently activate a script inserted from another object, even manually. You have to recompile it first, in order to give it a new UUID. Azelda |
Nexus Nash
Undercover Linden
![]() Join date: 18 Dec 2002
Posts: 1,084
|
01-10-2004 22:29
Bos you can't activate it... Unless you first activate it by hand!
_____________________
|
Bosozoku Kato
insurrectionist midget
![]() Join date: 16 Jun 2003
Posts: 452
|
01-11-2004 00:33
hrm didn't realize that. I never noticed it not activate a script, but i never tried various methods of activating/deactivating before using a script to do it.
I'd hope that for your own scripts it'd work regardless of the state of the script beforehand. I can understand limiting it's functionality so griefers can't drop script-stoppers in other's prims. Bos |
Azelda Garcia
Azelda Garcia
Join date: 3 Nov 2003
Posts: 819
|
01-11-2004 05:59
Bos, it's independent of who drops it in. It's not like this by design, it's a bug to do with uuids. I have Bug Reported it by the way, but it wouldnt hurt if other people did the same
![]() Azelda |