| 03-14-2005, 06:09 PM | #1 |
How can I write up this trigger?: -only activate during the day (probably will have to have 2 triggers; one to turn it on and the actions) -only works if a character generated on the map(only one of type) is owned by a player -subtracts 5 life/second of the character k thanks |
| 03-14-2005, 08:46 PM | #2 |
A little more complicated then I expected, but still doable. Code:
Die during the day
Events
Time - Every 1.00 seconds of game time
Conditions
Actions
Unit Group - Pick every unit in (Units in (Playable map area) matching (((Owner of (Picked unit)) slot status) Equal to Is playing)) and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Owner of (Your Unit)) Equal to Whatever Player
Then - Actions
Unit - Set life of (Picked unit) to ((Life of (Picked unit)) - 5.00)
Else - Actions
TriggerTurnOn
Events
Game - The in-game time of day becomes Equal to 6.00
Conditions
Actions
Trigger - Turn on Die during the day <gen>
TriggerTurnOff
Events
Game - The in-game time of day becomes Equal to 6.00
Conditions
Actions
Trigger - Turn off Die during the day <gen>
Hopefully you can figure out what that does. |
