This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
set_entity_script [2017/05/18 15:39] – justin | set_entity_script [2020/04/28 10:23] – justin | ||
---|---|---|---|
Line 2: | Line 2: | ||
---- | ---- | ||
- | Sets the script of the specified tile or object. An empty string value can be specified for the script name in order to remove the entity' | + | Sets the script of the specified |
+ | ====Signature: | ||
<code python> | <code python> | ||
- | set_entity_script(entity, | + | set_entity_script(entity, |
</ | </ | ||
^Argument^Description^Type^Required^ | ^Argument^Description^Type^Required^ | ||
- | |entity|Entity | + | |entity|[[Entity]] to update the [[script]] for.|[[Entity]]|Yes| |
- | |script_name|Name of the new script.|[[String]]|Yes| | + | |script_name|Name of the new [[script]].|[[String]]|Yes| |
+ | |trigger_type|When to trigger the [[script]] (only applicable to [[tile|tiles]]).|Trigger Type|No| | ||
====Example: | ====Example: | ||
- | < | + | < |
set_entity_script(entity[" | set_entity_script(entity[" | ||
</ | </ | ||
- | // | + | // |
<WRAP center round tip 100%> | <WRAP center round tip 100%> | ||
- | Use the **Set Entity Script** function to change the behavior of an object after it has been interacted with or to removes | + | Use the **Set Entity Script** function to change the behavior of an [[object]] after it has been interacted with or to remove |
</ | </ | ||