User Tools

Site Tools


prpl:destroyunit

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
prpl:destroyunit [2016/12/21 06:35] Oblivionprpl:destroyunit [2016/12/21 18:38] (current) – Removed return - testing shows that there is none GoodMorning
Line 1: Line 1:
 <- [[.:prplreference| PRPL reference]] <- [[.:prplreference#everything_else_2|Everything Else 2]] <- [[.:prplreference| PRPL reference]] <- [[.:prplreference#everything_else_2|Everything Else 2]]
  
-=====  DESTROYUNIT  =====+=====  DestroyUnit  =====
  
 ^Arguments^Result^Notation^ ^Arguments^Result^Notation^
-| UID, i1Unit Destroyed| [ UID, i1 Result ] |+| UID, Mode| | [ UID Mode - ] |
  
  
 === Description === === Description ===
-Destroys the Unit UID of the unit it receives, and what to play when destroyed.+Destroys the Unit of the UID it receives, and what to play when destroyed. 
 +Modes:
        0 - Nothing        0 - Nothing
        1 - Explosion Effect        1 - Explosion Effect
 +       
 +Note: This terminates script execution immediately if the Core carrying a script destroys itself. No statement after DestroyUnit will execute.
 +
 +Editors note: Testing indicates that this command does not produce a result. This page has been updated to reflect that.
  
 === Examples === === Examples ===
 <code> i2 = GetIntFromStack(); //mode  <code> i2 = GetIntFromStack(); //mode 
  i1 = GetIntFromStack(); //UID   i1 = GetIntFromStack(); //UID 
- + 
 +        Self 0 DestroyUnit //Destroys itself without effects 
 +        Self 1 DestroyUnit //Destroys itself while creating an explosion effect
 </code> </code>
  
prpl/destroyunit.1482320140.txt.gz · Last modified: 2016/12/21 06:35 by Oblivion