• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

help me with taxes please

Status
Not open for further replies.
(sorry no WE handy)

basically exactly what u said is the answer. every 30 seconds, a trigger runs, counts the footman and gives an arithmatic equation of 3 x footman gold, then adds it to the players gold.


Event: Periodic timer of 30 seconds
Condition: N/A
Actions:
set IntVar = 0
unit group - select all units of type "footman" matching owned by player X and do:
---set IntVar = IntVar + 1
player resource - set gold to (current gold + "IntVar")


****One for each player to be taxed or make a loop by player number
****leeks a unit group check things that leek sticky
 
  • Untitled Trigger 001
    • Events
      • Time - Elapsed game time is 1.00 seconds
    • Conditions
    • Actions
      • For each (Integer A) from 0 to -1, do (Actions)
        • Loop - Actions
          • Wait 30.00 seconds
          • Set tempgroup = (Units owned by Player 1 (Red) of type Footman)
          • Unit Group - Pick every unit in tempgroup and do (Actions)
            • Loop - Actions
              • Player - Add 1 to Player 1 (Red) Current gold
          • Custom script: call DestroyGroup( udg_tempgroup )
that should work
 
  • Untitled Trigger 001
    • Events
      • Time - Elapsed game time is 1.00 seconds
    • Conditions
    • Actions
      • For each (Integer A) from 0 to -1, do (Actions)
        • Loop - Actions
          • Wait 30.00 seconds
          • Set tempgroup = (Units owned by Player 1 (Red) of type Footman)
          • Unit Group - Pick every unit in tempgroup and do (Actions)
            • Loop - Actions
              • Player - Add 1 to Player 1 (Red) Current gold
          • Custom script: call DestroyGroup( udg_tempgroup )
that should work
Why don't you use as Event every 30 seconds and cut out the wait? o.O
 
I'd rather do like this;
  • Events
    • Time - Every 30 seconds.
  • Conditions
  • Actions
    • Custom script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in (Playable map area) matching (Matching unit equal to (Footman))
      • Loop - Actions
        • Player - Add 1 to (Owner of (Picked unit)) Current Gold
 
i have question about "set bj_wantDestroyGroup = true"
i don't wonna make new thread so i will post it here, if i have trigger like this
  • Actions
    • Custom script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in (Units of type foot small) and do (Player - Add 2 to (Owner of (Picked unit)) Current gold)
    • Custom script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in (Units of type foot) and do (Player - Add 3 to (Owner of (Picked unit)) Current gold)
    • Custom script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in (Units of type Foot big) and do (Player - Add 4 to (Owner of (Picked unit)) Current gold)
must look like this or like this

  • Actions
    • Custom script: set bj_wantDestroyGroup = true
    • Unit Group - Pick every unit in (Units of type foot small) and do (Player - Add 2 to (Owner of (Picked unit)) Current gold)
    • Unit Group - Pick every unit in (Units of type foot) and do (Player - Add 3 to (Owner of (Picked unit)) Current gold)
    • Unit Group - Pick every unit in (Units of type Foot big) and do (Player - Add 4 to (Owner of (Picked unit)) Current gold)
please tell me

Edit: every time when i use this my trigger don't work correctly or don't work at all u can try this trigger with periodic event and chek and tell me why don't add the gold at the time when must add it it's better the default trigger at WE
 
Last edited:
Status
Not open for further replies.
Back
Top