• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • Create a faction for Warcraft 3 and enter Hive's 19th Techtree Contest: Co-Op Commanders! Click here to enter!
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 21st Texturing Contest: Upgrade is now concluded, time to vote for your favourite set of icons! Click here to vote!

Need help with some more gui please.

Status
Not open for further replies.
Level 2
Joined
Jun 25, 2009
Messages
19
Just multiply the money by amount of units of type Circle of Power owned by player.
 
  • Trigger1
  • Events
    • Time - Every 10.00 seconds of game-time
  • Conditions
  • Actions
    • For each (Integer A) from 1 to 12, do (Actions)
      • Loop - Actions
        • Set Temp_Group = (Units owned by Player(IntegerA) of type Circle of Power)
        • Player - Add ((your base gold amount)*(Number of units in Temp_Group)) to (Player(IntegerA))
        • Custom script: call DestoryGroup (udg_Temp_Group)
 
  • Trigger2
  • Events
    • Time - Every 1.00 second of game-time
  • Conditions
  • Actions
    • Set Group = (Units of type (Circle of Power))
    • Unit Group - Pick up every unit in Group and do (Actions)
      • Loop - Actions
        • If/ Then/ Else
          • If (Conditions)
            • ((Life of (Picked unit)) Less than or Equal to (0.5*(Max Life of (Picked unit)))
          • Then (Actions)
            • Unit - Change ownership of (Picked unit) to X
          • Else (Actions)
    • Custom script: call DestroyGroup (udg_Group)
 
Level 14
Joined
Mar 4, 2009
Messages
1,156
you can do it like this so you don´t have to pick units every second


use the first trigger only if you have <Your Unit Type> in beginning of game
  • PICK EVERY UNIT OF TYPE
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Set UNITGROUP = (Units of type <Your Unit Type>)
      • Unit Group - Pick every unit in UNITGROUP and do (Actions)
        • Loop - Actions
          • Trigger - Add to HEALTH LEASS THAN 50% <gen> the event (Unit - (Picked unit)'s life becomes Less than ((Percentage life of (Picked unit)) - 50.00))
      • Custom script: call DestroyGroup(udg_UNITGROUP)
      • Trigger - Turn off (This trigger)
  • IF NEW UNIT OF TYPE ENTERS (if you train/build new unit)
    • Events
      • Unit - A unit enters (Entire map)
    • Conditions
      • (Unit-type of (Entering unit)) Equal to <Your Unit Type>
    • Actions
      • Trigger - Add to HEALTH LEASS THAN 50% <gen> the event (Unit - (Entering unit)'s life becomes Less than ((Percentage life of (Entering unit)) - 50.00))
  • HEALTH LEASS THAN 50%
    • Events
    • Conditions
    • Actions
      • -------- whatever you want---------(use triggering unit to refer to the damaged unit) --------
 
Level 11
Joined
Jun 28, 2008
Messages
2,365
Well, you can do it by triggers witch is harder, and I cant post em right now.

Or, you can go to game settings. There you can select that 1 of 12 players is rescueable. So every unit that belongs to him will be rescued by another player when a unit comes close to rescueable unit.
But this requires that you separate 1 player spot unable to be played. So cant be used in maps for 12 players.

I am not in pozicion to make trigger version right now. Not at hmme :p
 
Status
Not open for further replies.
Top