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

[Trigger] Multiboard messing up...

Status
Not open for further replies.
Level 5
Joined
Jul 25, 2008
Messages
126
The multiboard appears but for some reason it then hides again. I don't understand why since i set them to 2 different variables.



Code:
Morale Bar
    Events
        Time - Elapsed game time is 1.00 seconds
    Conditions
    Actions
        Multiboard - Create a multiboard with 1 columns and 1 rows, titled Morale
        Set Team_1_Multiboard = (Last created multiboard)
        Multiboard - Set the width for Team_1_Multiboard item in column 1, row 1 to 10.00% of the total screen width
        Multiboard - Set the display style for Team_1_Multiboard item in column 1, row 1 to Show text and Hide icons
        Multiboard - Hide Team_1_Multiboard
        Custom script:   if IsPlayerAlly(GetLocalPlayer(), Player(0)) then
        Multiboard - Show Team_1_Multiboard
        Custom script:   endif
        Wait 2.00 seconds
        Multiboard - Create a multiboard with 1 columns and 1 rows, titled Morale
        Set Team_2_Multiboard = (Last created multiboard)
        Multiboard - Set the width for Team_2_Multiboard item in column 1, row 1 to 10.00% of the total screen width
        Multiboard - Set the display style for Team_2_Multiboard item in column 1, row 1 to Show text and Hide icons
        Multiboard - Hide Team_2_Multiboard
        Custom script:   if IsPlayerAlly(GetLocalPlayer(), Player(3)) then
        Multiboard - Show Team_2_Multiboard
        Custom script:   endif
 
Level 4
Joined
Mar 19, 2008
Messages
89
Are you saying that you have two multiboards?
Because you can only have one multiboard shown at a time per player!
And if you are asking something else, please tell me.
 
Last edited:
Level 4
Joined
Nov 23, 2007
Messages
113
Looks like the 2nd mb will replace the first then do nothing. Create both and hide both. Then move your "if (GetLocalPlayer() == playerIndex)" code to the bottom of your code to select which one to display depending on who the local player is.

Edit: A better way might be to only create the mb depending on which player is the local player. Then you don't have a number of mb variables to mess with - just the one, which points to the mb designed for that specific player.
 
Status
Not open for further replies.
Top