Jump to content

SetScript


kert349

Recommended Posts

Hello

does any one know how to use SetScript?

 

I tried this:

 


joiner.setscript GruntScript

 

where GruntScript is name of the script object.

 

But GECK has some problem with this syntaxt / the GruntScript paramenter.

 

any one knows how to use it?

Link to comment
Share on other sites

Looks fine to me, although I've only used GetScript.

Just noticed this in the doc...

 

SetScript

Alias: none

Parameters:2

scriptInRef:GenericObject

item:GenericObject

 

So maybe the script just needs to be stored in a ref ?

Yes you need to attach the script on a dummy item.

Link to comment
Share on other sites

No, like this:

 



REF_OF_WHAT_YOU_WANT_TO_BE_SCRIPTED.setscript DUMMY_OBJECT

 

Where DUMMY_OBJECT has the script attached

Edited by sagittarius22
Link to comment
Share on other sites

No, like this:

 



REF_OF_WHAT_YOU_WANT_TO_BE_SCRIPTED.setscript DUMMY_OBJECT

 

Where DUMMY_OBJECT has the script attached

 

Ok thx i tried that but it doesnt seem to work..

 

does dummy have to be ref or can it be baseobject ?

Link to comment
Share on other sites

You cannot have different scripts on different instances of an object. That is, you cannot call this on a "reference ID" which you give or see in the cell window. You must call it on a base object. In your original post, is "joiner" an object or an instance? Is it possible that the script is, for example a quest script, and you are trying to attach it to an object? Assuming you are using geck powerup, what is the exact error message?
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...