• 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!

Food Cap

Status
Not open for further replies.
Level 37
Joined
Aug 14, 2006
Messages
7,614
I have a problem that I can't increase the food cap over 10. However I can increase the "food used" to whatever I want.

So, what can possibly prevent a map to have that maximum food to go over 10?
 

Attachments

  • 123123123.jpg
    123123123.jpg
    3 KB · Views: 74
Level 37
Joined
Aug 14, 2006
Messages
7,614
Food Limit: 100. That's what I have at the moment in Game Constansts. I try to give with triggers more food cap but it doesn't work. I wonder what makes it so that it stays in that 10?

Systems works perfectly, but Food Cap just won't go over 10.

Here's the system Food System I use.

  • CHECK Vitality ITEMS
    • Events
      • Time - Every 1.00 seconds of game time
    • Conditions
      • Cinematic Equal to False
    • Actions
      • -------- Anti-Cheat Mana --------
      • Unit - Order Anti_Cheat_Mana to Night Elf Druid Of The Claw - Roar
      • -------- === VITALITY === --------
      • Set Max_Vitality = 0
      • Set TempGroup = (Units owned by Player 1 (Red))
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has an item of type Magical Web) Equal to True
            • Then - Actions
              • Set Max_Vitality = (Max_Vitality + 1)
            • Else - Actions
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has an item of type Rikhano's Armor) Equal to True
            • Then - Actions
              • Set Max_Vitality = (Max_Vitality + 1)
            • Else - Actions
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has an item of type Rikhano's Boots) Equal to True
            • Then - Actions
              • Set Max_Vitality = (Max_Vitality + 1)
            • Else - Actions
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has an item of type Rikhano's Jewel) Equal to True
            • Then - Actions
              • Set Max_Vitality = (Max_Vitality + 1)
            • Else - Actions
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has an item of type Rikhano's Set) Equal to True
            • Then - Actions
              • Set Max_Vitality = (Max_Vitality + 3)
            • Else - Actions
      • Unit Group - Pick every unit in TempGroup and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) has an item of type Sack Of Endless Food) Equal to True
            • Then - Actions
              • Set Max_Vitality = (Max_Vitality + 3)
            • Else - Actions
      • Set Vitality[1] = (Player 1 (Red) Food used)
      • Set Vitality[2] = (10 + Max_Vitality)
      • Custom script: call DestroyGroup(udg_TempGroup)
      • -------- === SET VITALITY MAX AMOUNT === --------
      • Player - Set Player 1 (Red) Food cap to Vitality[2]
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Greater than (Player 1 (Red) Food cap)
        • Then - Actions
          • Player - Set Player 1 (Red) Food used to (Player 1 (Red) Food cap)
        • Else - Actions
      • -------- === INCREASE/DECREASE HIT POINTS === --------
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 0
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) - 4.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) - 4.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) - 4.00)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • (Player 1 (Red) Food used) Equal to 1
              • (Player 1 (Red) Food used) Equal to 2
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) - 2.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) - 2.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) - 2.00)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • (Player 1 (Red) Food used) Equal to 3
              • (Player 1 (Red) Food used) Equal to 4
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) - 1.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) - 1.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) - 1.00)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Or - Any (Conditions) are true
            • Conditions
              • (Player 1 (Red) Food used) Equal to 7
              • (Player 1 (Red) Food used) Equal to 8
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 0.50)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 0.50)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 0.50)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 9
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 1.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 1.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 1.00)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 10
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 1.50)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 1.50)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 1.50)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 11
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 2.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 2.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 2.00)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 12
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 2.50)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 2.50)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 2.50)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 13
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 3.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 3.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 3.00)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 14
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 3.50)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 3.50)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 3.50)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 15
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 4.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 4.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 4.00)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 16
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 4.50)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 4.50)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 4.50)%
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Equal to 17
        • Then - Actions
          • Unit - Set life of AAAFradz to ((Percentage life of AAAFradz) + 5.00)%
          • Unit - Set life of AAAGaleoth to ((Percentage life of AAAGaleoth) + 5.00)%
          • Unit - Set life of AAAPhodom to ((Percentage life of AAAPhodom) + 5.00)%
        • Else - Actions
  • Increase FOOD
    • Events
      • Unit - A unit Uses an item
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (Item-type of (Item being manipulated)) Equal to Glass Of Sludge
          • (Item-type of (Item being manipulated)) Equal to Banana
          • (Item-type of (Item being manipulated)) Equal to Cheese
          • (Item-type of (Item being manipulated)) Equal to Bread
          • (Item-type of (Item being manipulated)) Equal to Piece Of Meat
          • (Item-type of (Item being manipulated)) Equal to Berry Pie
          • (Item-type of (Item being manipulated)) Equal to Full Meat
          • (Item-type of (Item being manipulated)) Equal to Hero Drink
          • (Item-type of (Item being manipulated)) Equal to Elixir
          • (Item-type of (Item being manipulated)) Equal to Sack Of Endless Food
    • Actions
      • Player - Add (Item level of (Item being manipulated)) to Player 1 (Red) Food used
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Player 1 (Red) Food used) Greater than (Player 1 (Red) Food cap)
        • Then - Actions
          • Player - Set Player 1 (Red) Food used to (Player 1 (Red) Food cap)
        • Else - Actions
      • Set Vitality[1] = (Player 1 (Red) Food used)
      • Game - Display to (All players) for 2.00 seconds the text: (|c00FEBA0EVitality: |c00FF0303 + ((String(Vitality[1])) + (|c00FEBA0E/|c0020C000 + ((String(Vitality[2])) + |c00FEBA0E.|r))))
      • Set JustGainedVitality = True
  • Decrease FOOD
    • Events
      • Time - Every 90.00 seconds of game time
    • Conditions
      • (Player 1 (Red) Food used) Greater than 0
      • Cinematic Equal to False
      • Vitality_On_Off Equal to False
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • JustGainedVitality Equal to False
        • Then - Actions
          • Player - Set Player 1 (Red) Food used to ((Player 1 (Red) Food used) - 1)
          • Set Vitality[1] = (Player 1 (Red) Food used)
          • Game - Display to (All players) for 2.00 seconds the text: (|c00FEBA0EVitality: |c00FF0303 + ((String(Vitality[1])) + (|c00FEBA0E/|c0020C000 + ((String(Vitality[2])) + |c00FEBA0E.|r))))
        • Else - Actions
          • Set JustGainedVitality = False
 
Status
Not open for further replies.
Top