- Joined
- Sep 9, 2006
- Messages
- 15
I am trying to make a trigger so when I type in ".kill" the game kills the unit I am currently selecting. Here is my trigger, I want to know why it doesn't work.
Events:
Player - Player 1 (Red) types a chat message containing .kill as An exact match
Actions:
Set tempUnit = (Picked Unit)
If (tempUnit Equal to No unit) then do (Game - Display to Player Group - Player 1 (Red) the text: [Debug] No unit selected!) else do (Unit - Kill tempUnit)
Custom Script: call RemoveUnit(udg_tempUnit)
Note: Is there a special BBcode to show triggers, I see them around the site.
Events:
Player - Player 1 (Red) types a chat message containing .kill as An exact match
Actions:
Set tempUnit = (Picked Unit)
If (tempUnit Equal to No unit) then do (Game - Display to Player Group - Player 1 (Red) the text: [Debug] No unit selected!) else do (Unit - Kill tempUnit)
Custom Script: call RemoveUnit(udg_tempUnit)
Note: Is there a special BBcode to show triggers, I see them around the site.