Hello sc2maoster community! Quick question. So what I want to do is make it so when player one and player 2 are in game, then the units owned by player 9 have twice the amount of life in the "p1 & p2 area". I used this trigger, thought it didn't work.
if: (controller of player 1) == user. and (controller of player 2) == 2.
Then: Pick all units in ( all units owned by player 9 with at most any amount blah blah blah blah blah) and do the current actions: modify life of picked unit by (picked unit) life x 2) and Modify picked unit maximum life by (picked unit) maximum life x 2) I did the same with shield and shield maximum. What did do wrong? Thanks!
Hello sc2maoster community! Quick question. So what I want to do is make it so when player one and player 2 are in game, then the units owned by player 9 have twice the amount of life in the "p1 p2 area". I used this trigger, thought it didn't work. if: (controller of player 1) == user. and (controller of player 2) == 2. Then: Pick all units in ( all units owned by player 9 with at most any amount blah blah blah blah blah) and do the current actions: modify life of picked unit by (picked unit) life x 2) and Modify picked unit maximum life by (picked unit) maximum life x 2) I did the same with shield and shield maximum. What did do wrong? Thanks!
Highlight - Copy as Text - paste the trigger here ...
Unit Group - Pick each unit in (Units in (Any units in p1 & p2 area owned by player 9 matching (No Value), with at most Any Amount) owned by player 9, with at most Any Amount) and do (Actions) -
Unit - Set (Picked unit) Life to (((Picked unit) Life (Current)) * 2.0)
Unit - Set (Picked unit) Maximum Life to (((Picked unit) Maximum Life (Current)) * 2.0)
Unit - Set (Picked unit) Shields to (((Picked unit) Shields (Current)) * 2.0)
Unit - Set (Picked unit) Maximum Shields to (((Picked unit) Maximum Shields (Current)) * 2.0)
Becuase I have multiple players in the game. If I set it so if both p1 and p2 are in game, then it'll become harder for everyone. So, this trigger is meant to set the life and life maximum and shield and shield maximum to double than what it originally is in the p1 & p2 region, so that it only applies to player 1 and player 2. Though, for some reason, it does not work.
I'm trying to get all of players 9's units (AI) to have double HP. I just want it so if both p1 and p2 are in game, then it doubles HP of all p9 units in "p1 & p2 area".
I'm trying to get all of players 9's units (AI) to have double HP. I just want it so if both p1 and p2 are in game, then it doubles HP of all p9 units in "p1 p2 area".
Create a buff (type of behavior) that modifies Vital Maximum Fraction - Life (set that to 1)
than do a trigger that happens when u want to apply the buff
Unit Group - Pick each unit in ([units in region matching condition] Any units in YourRegion owned by player YourPlayer matching (leave this alone) with at most Any Amount) and do actions
Unit - Add 1 YourBuff to PickedUnit from PickedUnit
than do another when a unit enters YourRegion
If (owner of triggering unit) = YourPlayer than unit - add 1 yourbuff to pickedunit from pickedunit
General - If (Conditions) then do (Actions) else do (Actions)
If
(Number of players in (Active Players)) == 2
Then
Player - Modify player 9 Handicap: Set To 200
Else
That's the best way to do it. Check if the number of players in game is equal to two, and if so change player 9 Handicap to 200% (which really means changing their unit's HP to x2).
OR like this for multiple players:
Player - Modify player 9 Handicap: Set To ((Number of players in (Active Players)) * 100)
Alhough this is quite helpful, there is one problem. I want to set the handicap in "p1 and p2 area" to be 200, not for everyone. Becuase in this map, people work in pairs of two, or they go solo. Hence, this would still make it harder for everyone
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hello sc2maoster community! Quick question. So what I want to do is make it so when player one and player 2 are in game, then the units owned by player 9 have twice the amount of life in the "p1 & p2 area". I used this trigger, thought it didn't work. if: (controller of player 1) == user. and (controller of player 2) == 2. Then: Pick all units in ( all units owned by player 9 with at most any amount blah blah blah blah blah) and do the current actions: modify life of picked unit by (picked unit) life x 2) and Modify picked unit maximum life by (picked unit) maximum life x 2) I did the same with shield and shield maximum. What did do wrong? Thanks!
Highlight - Copy as Text - paste the trigger here ...
Unit Group - Pick each unit in (Units in (Any units in p1 & p2 area owned by player 9 matching (No Value), with at most Any Amount) owned by player 9, with at most Any Amount) and do (Actions) -
Unit - Set (Picked unit) Life to (((Picked unit) Life (Current)) * 2.0)
Unit - Set (Picked unit) Maximum Life to (((Picked unit) Maximum Life (Current)) * 2.0)
Unit - Set (Picked unit) Shields to (((Picked unit) Shields (Current)) * 2.0)
Unit - Set (Picked unit) Maximum Shields to (((Picked unit) Maximum Shields (Current)) * 2.0)
Why not just do a trigger where...
Event
Unit is created
Condition
Triggering unit owned by player 9
Action
Blahblahblahstat * 2
Mmmm?
Becuase I have multiple players in the game. If I set it so if both p1 and p2 are in game, then it'll become harder for everyone. So, this trigger is meant to set the life and life maximum and shield and shield maximum to double than what it originally is in the p1 & p2 region, so that it only applies to player 1 and player 2. Though, for some reason, it does not work.
You could pick all of the units owned by both players and apply a buff that doubles HP.
I'm trying to get all of players 9's units (AI) to have double HP. I just want it so if both p1 and p2 are in game, then it doubles HP of all p9 units in "p1 & p2 area".
Create a buff (type of behavior) that modifies Vital Maximum Fraction - Life (set that to 1)
than do a trigger that happens when u want to apply the buff
Unit Group - Pick each unit in ([units in region matching condition] Any units in YourRegion owned by player YourPlayer matching (leave this alone) with at most Any Amount) and do actions
Unit - Add 1 YourBuff to PickedUnit from PickedUnit
than do another when a unit enters YourRegion
If (owner of triggering unit) = YourPlayer than unit - add 1 yourbuff to pickedunit from pickedunit
General - If (Conditions) then do (Actions) else do (Actions)
If
(Number of players in (Active Players)) == 2
Then
Player - Modify player 9 Handicap: Set To 200
Else
That's the best way to do it. Check if the number of players in game is equal to two, and if so change player 9 Handicap to 200% (which really means changing their unit's HP to x2).
OR like this for multiple players:
Player - Modify player 9 Handicap: Set To ((Number of players in (Active Players)) * 100)
The Action is set Player Property.
Alhough this is quite helpful, there is one problem. I want to set the handicap in "p1 and p2 area" to be 200, not for everyone. Becuase in this map, people work in pairs of two, or they go solo. Hence, this would still make it harder for everyone