Appearance
sp_script
Prototypeint sp_script(int active_sprite, string script[9])
sp_script()
kills any scripts currently owned by active_sprite
, sets the script for the active_sprite
, executes the main
procedure of the script, and returns the script number of the new script.
Dink
< 1.08
If a sprite replaced it's own script, there was a chance odd things would happen.
Dink
1.08
Freedink
all
A sprite can replace it's own script without issues. When a sprite replaces it's own script, the old script will be killed off automatically at that time (unless using script_attach(0) to keep the script alive).