Messed up Multibord

  • Thread starter Thread starter Starlite
  • Start date Start date
S

Starlite

Guest
ok so i got the lives and kills to work. but im having a little trouble with having the kills go in the right spot...

Code:
Create Multiboard
    Events
        Time - Elapsed game time is 1.00 seconds
    Conditions
    Actions
        Multiboard - Create a multiboard with 2 columns and 12 rows, titled ( Tower Defense - [Wave -  + ((String(Wave_Number)) + ]))
        Multiboard - Set the display style for (Last created multiboard) item in column 1, row 1 to Show text and Hide icons
        Multiboard - Set the display style for (Last created multiboard) item in column 2, row 1 to Show text and Hide icons
        Multiboard - Set the display style for (Last created multiboard) item in column 1, row 4 to Show text and Hide icons
        Multiboard - Set the display style for (Last created multiboard) item in column 2, row 4 to Show text and Hide icons
        Multiboard - Set the display style for (Last created multiboard) item in column 1, row 7 to Show text and Hide icons
        Multiboard - Set the display style for (Last created multiboard) item in column 2, row 7 to Show text and Hide icons
        Multiboard - Set the display style for (Last created multiboard) item in column 1, row 10 to Show text and Hide icons
        Multiboard - Set the display style for (Last created multiboard) item in column 2, row 10 to Show text and Hide icons
        For each (Integer A) from 2 to 3, do (Actions)
            Loop - Actions
                Multiboard - Set the icon for (Last created multiboard) item in column 1, row (Integer A) to ReplaceableTextures\CommandButtons\BTNWisp.blp
                Multiboard - Set the text for (Last created multiboard) item in column 2, row (Integer A) to (String(Kill_Count[(Player number of (Owner of (Killing unit)))]))
        For each (Integer A) from 5 to 6, do (Actions)
            Loop - Actions
                Multiboard - Set the icon for (Last created multiboard) item in column 1, row (Integer A) to ReplaceableTextures\CommandButtons\BTNWisp.blp
                Multiboard - Set the text for (Last created multiboard) item in column 2, row (Integer A) to (String(Kill_Count[(Player number of (Owner of (Killing unit)))]))
        For each (Integer A) from 8 to 9, do (Actions)
            Loop - Actions
                Multiboard - Set the icon for (Last created multiboard) item in column 1, row (Integer A) to ReplaceableTextures\CommandButtons\BTNWisp.blp
                Multiboard - Set the text for (Last created multiboard) item in column 2, row (Integer A) to (String(Kill_Count[(Player number of (Owner of (Killing unit)))]))
        For each (Integer A) from 11 to 12, do (Actions)
            Loop - Actions
                Multiboard - Set the icon for (Last created multiboard) item in column 1, row (Integer A) to ReplaceableTextures\CommandButtons\BTNWisp.blp
                Multiboard - Set the text for (Last created multiboard) item in column 2, row (Integer A) to (String(Kill_Count[(Player number of (Owner of (Killing unit)))]))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 1 to Team 1 Lives
        Multiboard - Set the text for (Last created multiboard) item in column 2, row 1 to (String(Lives[1]))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 2 to (Name of Player 1 (Red))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 3 to (Name of Player 2 (Blue))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 4 to Team 2 Lives
        Multiboard - Set the text for (Last created multiboard) item in column 2, row 4 to (String(Lives[2]))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 5 to (Name of Player 3 (Teal))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 6 to (Name of Player 4 (Purple))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 7 to Team 3 Lives
        Multiboard - Set the text for (Last created multiboard) item in column 2, row 7 to (String(Lives[3]))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 8 to (Name of Player 5 (Yellow))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 9 to (Name of Player 6 (Orange))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 10 to Team 4 Lives
        Multiboard - Set the text for (Last created multiboard) item in column 2, row 10 to (String(Lives[4]))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 11 to (Name of Player 7 (Green))
        Multiboard - Set the text for (Last created multiboard) item in column 1, row 12 to (Name of Player 8 (Pink))
        For each (Integer B) from 1 to 12, do (Actions)
            Loop - Actions
                Multiboard - Set the display style for (Last created multiboard) item in column 2, row (Integer B) to Show text and Hide icons
                Multiboard - Set the width for (Last created multiboard) item in column 1, row (Integer B) to 8.00% of the total screen width
                Multiboard - Set the width for (Last created multiboard) item in column 2, row (Integer B) to 3.00% of the total screen width


Kills Update
    Events
        Unit - A unit Dies
    Conditions
        (Owner of (Dying unit)) Equal to Player 12 (Brown)
    Actions
        Set Kill_Count[(Player number of (Owner of (Killing unit)))] = (Kill_Count[(Player number of (Owner of (Killing unit)))] + 1)
        Multiboard - Set the text for (Last created multiboard) item in column 2, row (Player number of (Owner of (Killing unit))) to (String(Kill_Count[(Player number of (Owner of (Killing unit)))]))

would it work if i did an if/then/else like this?
Code:
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    If - Conditions
        Or - Any (Conditions) are true
            Conditions
                (Owner of (Killing unit)) Equal to Player 1 (Red)
                (Owner of (Killing unit)) Equal to Player 2 (Blue)
    Then - Actions
        Multiboard - Set the text for (Last created multiboard) item in column 1, row ((Player number of (Owner of (Killing unit))) + 1) to (String(Kill_Count[(Player number of (Owner of (Killing unit)))]))
    Else - Actions
 
its cause you used the var for the value in the board, you have to leave it at 0, then update it, it wont work if it starts as a var. :D
 
lol it works fine, just instead of updating where the player is actually on the board, it updates to the row the player would be at, if i didnt add any extra things in...
 
So you mean that Player 1 is like in Row 3 instead of Row 1? Then just add the number of extra rows at the top. So the row number would be like this:
(Player number of (Owner of (Killing unit))) + (number of extra rows)\

EDIT: Cool avatar. :D
 
General chit-chat
Help Users
  • No one is chatting at the moment.
  • The Helper The Helper:
    got it
  • The Helper The Helper:
    Happy Thursday!
  • The Helper The Helper:
    Check out the new Featured Content feature we apparently got with the forum software upgrade! https://www.thehelper.net/featured/
  • The Helper The Helper:
    Also on the bottom right side bar we now have a Trending Content Box!
    +1
  • The Helper The Helper:
    Not on the Headline News page just on the Forums page can we get that Featured and Trending on the home page?
  • Ghan Ghan:
    Since the home page is technically a forum, it now shows on all forum views. Still in the sidebar.
    +1
  • The Helper The Helper:
    Happy Friday! Hope everyone has a fantastic day and an even better weekend!
  • The Helper The Helper:
    Happy Sunday!
  • The Helper The Helper:
    I lovc that I can post webp and X links now! :)
  • The Helper The Helper:
    Happy Thursday!
  • V-SNES V-SNES:
    Happy Friday!
    +1
  • The Helper The Helper:
    we were down for a minute - think a log file or something got too big
    +1
  • Ghan Ghan:
    The alerts say it was down for a while unfortunately.
  • Ghan Ghan:
    Didn't know what was going on while I was at work.
  • Ghan Ghan:
    Disk filled up with logs. Fixed now.
    +1
  • The Helper The Helper:
    not a problem at all thanks for getting us back up
  • The Helper The Helper:
    I think the bots are finding a way to get through the anubis
  • The Helper The Helper:
    Happy Wednesday Everyone! Hope everyone has a Fantastic Day!
    +1
  • The Helper The Helper:
    Yeah, stats are showing big bot influx like 12k page views.
  • Wizard Wizard:
    :wave:
    +1
  • Ghan Ghan:
    TH changed his avatar again. 6 more weeks of summer.
    +3
  • Wizard Wizard:
    lol
    +1
  • The Helper The Helper:
    Guys just a heads up I am going to be shutting the site down soon. I am just waiting on the NUON people to decide whether they want to transfer forum data and keep the discord. My email is [email protected] for anyone that wants to keep in touch and I have a facebook too. I will make an official post later. Love you guys and will miss everyone!
    +1
  • V-SNES V-SNES:
    Sent a pm @The Helper

The Helper Discord

Members online

No members online now.

Affiliates

Hive Workshop NUON Dome World Editor Tutorials
Back
Top