• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Multiboard Help

Status
Not open for further replies.
Level 4
Joined
Jan 23, 2009
Messages
74
Hi guys I'm making another map, and I'm having trouble with the system that incorporates 3 custom resources
and whenever i use this multi board it only works if i enable the 1st part of it (the part for player 1)

  • Resources
    • Events
      • Time - Elapsed game time is 0.00 seconds
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[1] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[1] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[1] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[1] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[1] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[1] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[1]
          • Custom script: if GetLocalPlayer () ==Player(0) then
          • Multiboard - Show Resourceboard[1]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[2] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[2] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[2] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[2] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[2] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[2] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[2]
          • Custom script: if GetLocalPlayer () ==Player(1) then
          • Multiboard - Show Resourceboard[2]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[3] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[3] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[3] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[3] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[3] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[3] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[3]
          • Custom script: if GetLocalPlayer () ==Player(2) then
          • Multiboard - Show Resourceboard[3]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[4] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[4] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[4] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[4] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[4] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[4] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[4]
          • Custom script: if GetLocalPlayer () ==Player(3) then
          • Multiboard - Show Resourceboard[4]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[5] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[5] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[5] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[5] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[5] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[5] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[5]
          • Custom script: if GetLocalPlayer () ==Player(4) then
          • Multiboard - Show Resourceboard[5]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[6] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[6] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[6] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[6] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[6] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[6] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[6]
          • Custom script: if GetLocalPlayer () ==Player(5) then
          • Multiboard - Show Resourceboard[6]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[7] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[7] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[7] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[7] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[7] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[7] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[7]
          • Custom script: if GetLocalPlayer () ==Player(6) then
          • Multiboard - Show Resourceboard[7]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[8] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[8] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[8] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[8] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[8] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[8] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[8]
          • Custom script: if GetLocalPlayer () ==Player(7) then
          • Multiboard - Show Resourceboard[8]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[9] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[9] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[9] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[9] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[9] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[9] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[9]
          • Custom script: if GetLocalPlayer () ==Player(8) then
          • Multiboard - Show Resourceboard[9]
          • Custom script: endif
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard[10] = (Last created multiboard)
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard[10] item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard[10] item in column 2, row 1 to 15.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard[10] item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard[10] item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • Multiboard - Set the icon for (Last created multiboard) item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard[10] item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for (Last created multiboard) item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Hide Resourceboard[10]
          • Custom script: if GetLocalPlayer () ==Player(9) then
          • Multiboard - Show Resourceboard[10]
          • Custom script: endif
        • Else - Actions

And when it does work, i have trouble with the trigger that adds more of a certain resource

  • Crops
    • Events
      • Time - Every 30.00 seconds of game time
    • Conditions
    • Actions
      • Set Crops[(Player number of Player 1 (Red))] = Crops[(Crops[(Player number of Player 1 (Red))] + ((Number of living Grain Mill units owned by Player 1 (Red)) x 30))]
      • Set Crops[(Player number of Player 2 (Blue))] = Crops[(Crops[(Player number of Player 2 (Blue))] + ((Number of living Grain Mill units owned by Player 2 (Blue)) x 30))]
      • Set Crops[(Player number of Player 3 (Teal))] = Crops[(Crops[(Player number of Player 3 (Teal))] + ((Number of living Grain Mill units owned by Player 3 (Teal)) x 30))]
      • Set Crops[(Player number of Player 4 (Purple))] = Crops[(Crops[(Player number of Player 4 (Purple))] + ((Number of living Grain Mill units owned by Player 4 (Purple)) x 30))]
      • Set Crops[(Player number of Player 5 (Yellow))] = Crops[(Crops[(Player number of Player 5 (Yellow))] + ((Number of living Grain Mill units owned by Player 5 (Yellow)) x 30))]
      • Set Crops[(Player number of Player 6 (Orange))] = Crops[(Crops[(Player number of Player 6 (Orange))] + ((Number of living Grain Mill units owned by Player 6 (Orange)) x 30))]
      • Set Crops[(Player number of Player 7 (Green))] = Crops[(Crops[(Player number of Player 7 (Green))] + ((Number of living Grain Mill units owned by Player 7 (Green)) x 30))]
      • Set Crops[(Player number of Player 8 (Pink))] = Crops[(Crops[(Player number of Player 8 (Pink))] + ((Number of living Grain Mill units owned by Player 8 (Pink)) x 30))]
      • Set Crops[(Player number of Player 9 (Gray))] = Crops[(Crops[(Player number of Player 9 (Gray))] + ((Number of living Grain Mill units owned by Player 9 (Gray)) x 30))]
      • Set Crops[(Player number of Player 10 (Light Blue))] = Crops[(Crops[(Player number of Player 10 (Light Blue))] + ((Number of living Grain Mill units owned by Player 10 (Light Blue)) x 30))]
any help would be apreciated
 
Level 37
Joined
Mar 6, 2006
Messages
9,240
And when it does work, i have trouble with the trigger that adds more of a certain resource

  • Crops
    • Events
    • Conditions
    • Actions
      • For each (Integer A) from 1 to 10, do (Actions)
        • Loop - Actions
          • Set Crops[(Integer A)] = (Crops[(Integer A)] + ((Number of living Grain Mill units owned by Player 1 (Red)) x 30)))
You could do it like that. The unit group leaks.
 

Bribe

Code Moderator
Level 50
Joined
Sep 26, 2009
Messages
9,467
1. Resourceboard should *not* be an array, as the game can only support one resource board at a time (which is why only one of these works).

2. Use this for the Resources initial trigger:
  • Resources
    • Events
      • Time - Elapsed game time is 0.00 seconds
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
        • Then - Actions
          • Multiboard - Create a multiboard with 2 columns and 4 rows, titled Resources
          • Set Resourceboard = (Last created multiboard)
          • -------- Init Row 1 --------
          • Multiboard - Set the icon for Resourceboard item in column 1, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for Resourceboard item in column 1, row 1 to Resource
          • Multiboard - Set the width for Resourceboard item in column 1, row 1 to 10.00% of the total screen width
          • Multiboard - Set the icon for Resourceboard item in column 2, row 1 to ReplaceableTextures\CommandButtons\BTNPillage.blp
          • Multiboard - Set the text for Resourceboard item in column 2, row 1 to Resource Amount
          • Multiboard - Set the width for Resourceboard item in column 2, row 1 to 15.00% of the total screen width
          • -------- Init Row 2 --------
          • Multiboard - Set the icon for Resourceboard item in column 1, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for Resourceboard item in column 1, row 2 to Crops
          • Multiboard - Set the width for Resourceboard item in column 1, row 2 to 10.00% of the total screen width
          • Multiboard - Set the icon for Resourceboard item in column 2, row 2 to ReplaceableTextures\CommandButtons\BTNAcorn.blp
          • Multiboard - Set the text for Resourceboard item in column 2, row 2 to (String(Crops[(Player number of Player 1 (Red))]))
          • -------- Init Row 3 --------
          • Multiboard - Set the icon for Resourceboard item in column 1, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for Resourceboard item in column 1, row 3 to Stone
          • Multiboard - Set the width for Resourceboard item in column 1, row 3 to 10.00% of the total screen width
          • Multiboard - Set the icon for Resourceboard item in column 2, row 3 to ReplaceableTextures\PassiveButtons\PASBTNResistantSkin.blp
          • Multiboard - Set the text for Resourceboard item in column 2, row 3 to (String(Stone[(Player number of Player 1 (Red))]))
          • -------- Init Row 4 --------
          • Multiboard - Set the icon for Resourceboard item in column 1, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for Resourceboard item in column 1, row 4 to Wealth
          • Multiboard - Set the width for Resourceboard item in column 1, row 4 to 10.00% of the total screen width
          • Multiboard - Set the icon for Resourceboard item in column 2, row 4 to ReplaceableTextures\WorldEditUI\Editor-ItemSet.blp
          • Multiboard - Set the text for Resourceboard item in column 2, row 4 to (String(Wealth[(Player number of Player 1 (Red))]))
          • Multiboard - Show Resourceboard
        • Else - Actions
3. I have a question for you - every multiboard you have created only displays Player 1 (Red)'s initial values... is this what you initially want?

4. You update the leaderboard for each player by using GetLocalPlayer() with this action:

  • Actions
    • For each Integer A from 1 to 10 do
      • Loop - Actions
        • Custom script: if GetLocalPlayer() == Player[bj_forLoopAIndex + 1] then
        • Multiboard - Set the text for Resourceboard item in column 2, row 4 to (String(Wealth[(Player number of Player (Integer A))]))
        • Multiboard - Set the text for Resourceboard item in column 2, row 3 to (String(Stone[(Player number of Player (Integer A))]))
        • Multiboard - Set the text for Resourceboard item in column 2, row 2 to (String(Crops[(Player number of Player (Integer A))]))
        • Custom script: endif
 

Bribe

Code Moderator
Level 50
Joined
Sep 26, 2009
Messages
9,467
Also, to complete Maker's post, create a Unit Group variable called Group

  • Crops
    • Events
    • Conditions
    • Actions
      • For each (Integer A) from 1 to 10, do (Actions)
        • Loop - Actions
          • Set Group = (living Grain Mill units owned by Player[(Integer A)])
          • Set Crops[(Integer A)] = (Crops[(Integer A)] + ((Count units in (Group)) x 30)
          • Custom script: call DestroyForce( udg_Group )
Now, your only task is to post what you're using to track your other two resources (stone and wealth)
 
Status
Not open for further replies.
Top