Difference between revisions of "MessageBox Tutorial/Token Scripts"
Jump to navigation
Jump to search
m
→Notes
imported>Wrye m (MessageBox Tutorial: Token Scripts moved to MessageBox Tutorial/Token Scripts: Rename as subpage.) |
imported>UDUN m (→Notes) |
||
|
* If you want to store any variables set on the token, you will need a persistent object. Set the variables you want to store on the persistent object, as such '''''set YourPersistentObject.SomeVar to SomeVar'''''.
* While it is not absolutely necessary to remove the token, it does make scripting easier as there is a clear beginning and a clear end. If you want to keep the token (for instance, to keep the variables on it), then you can remove it to a remote container (RemoveMe RemoteCont), and move it back to the player when you want to use it again. There are 2 ways to move it back to the player:
# Use '''''
# Otherwise, you can mark each token with a unique number (set a short variable). This number can be used to determine if the token should remove itself back to the player ('''''RemoveMe player'''''). Make each token check a persistent variable (global, quest variable, or persistent object variable) every frame, and load the remove container by setting a variable on it or moving it to the player (be sure to move it back afterwards).
<pre>short ID
| |||