ProjectVenus
New Member
- Reaction score
- 0
I am working on a map for WCIII: ROC and am having trouble telling the game, "a unit owned by any player is attacked"
I have the rest of the trigger set up, but I need to have the event for the conditions and actions to apply. If I can't find out a way to tell the game the event, then I'll have to copy paste the trigger and make an event for each player, which is going to take up more space than I'd like and take up too much of my time because I need to set up an inverse trigger for this trigger.
Here is exactly what the trigger does:
"a unit owned by any player is attacked"
(( Life of (attacked unit)) Less than or equal to 1200.00) and ((Unit-type of (attacked unit)) Equal to Wheat)
Unit-change ownership of (attacked unit) to (owner of attacking unit)) and change color
If ((owner of (attacking unit)) equal to player 1 (red)) then do (Set incomered = (incomered+10)) then do (set incomered2 = (incomered2+20)) else do nothing.
This last action is repeated for every player.
Then I will have an inverse trigger for each player(not just player 1) that states:
A unit owned by player 1(red) is attacked
(( Life of (attacked unit)) Less than or equal to 1200.00) and ((Unit-type of (attacked unit)) Equal to Wheat)
set incomered = (incomered-10)
set incomered2 = (incomered2-20)
Please help, I need to know how to tell the game, "a unit owned by any player is attacked"
I have the rest of the trigger set up, but I need to have the event for the conditions and actions to apply. If I can't find out a way to tell the game the event, then I'll have to copy paste the trigger and make an event for each player, which is going to take up more space than I'd like and take up too much of my time because I need to set up an inverse trigger for this trigger.
Here is exactly what the trigger does:
"a unit owned by any player is attacked"
(( Life of (attacked unit)) Less than or equal to 1200.00) and ((Unit-type of (attacked unit)) Equal to Wheat)
Unit-change ownership of (attacked unit) to (owner of attacking unit)) and change color
If ((owner of (attacking unit)) equal to player 1 (red)) then do (Set incomered = (incomered+10)) then do (set incomered2 = (incomered2+20)) else do nothing.
This last action is repeated for every player.
Then I will have an inverse trigger for each player(not just player 1) that states:
A unit owned by player 1(red) is attacked
(( Life of (attacked unit)) Less than or equal to 1200.00) and ((Unit-type of (attacked unit)) Equal to Wheat)
set incomered = (incomered-10)
set incomered2 = (incomered2-20)
Please help, I need to know how to tell the game, "a unit owned by any player is attacked"