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

Showing multiboard to one player

Status
Not open for further replies.
Level 7
Joined
Dec 9, 2014
Messages
89
Hi, I have referred to older threads to figure out how to show a multiboard to only one player (in gui customscript). It works when I hide one multiboard and then show it to a specific player or player(s). However when I create a second multiboard and hide it and then show it to different specific player or player(s), it hides the other multiboard instead.

I'm not sure how to paste my trigger here, but I am using


Multiboard - Hide (Multiboard Variable 1)

if GetLocalPlayer() == Player(0) then

Multiboard - Show (Multiboard Variable 1)

endif

Multiboard - Hide (Multiboard Variable 2)

if GetLocalPlayer() == Player(3) then

Multiboard - Show (Multiboard Variable 2)

endif

Any clue what I am doing wrong? I am positive I created/set the variables correctly.
 
Level 14
Joined
Jan 16, 2009
Messages
716
Use [trigger][/trigger] to display GUI triggers. It easier for us to help you that way :)
I think you should also show the whole trigger (meaning the variable declaration too).

Also you should hide for all first and then show locally. Try what Chaosy is suggesting.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,198
GUI multiboard creation automatically shows the multiboard for all players. As such there are 3 solutions.
  • JASS: Use JASS directly and skip showing the multiboard during creation. Instead show the multiboards locally for the desired player.
  • Initialization: Create all multiboards first, then hide all multiboards, then show them locally for the desired players.
  • Refresh: Every time a new multiboard is created hide all multiboards and then show all multiboards locally for the desired players.
 
Level 7
Joined
Dec 9, 2014
Messages
89
I got it working. The problem was I was creating one board, hiding it for all players and then showing it to one in localplayer, then creating another, hiding it for all players then showing it to another in localplayer. Creating them together then hiding all boards before showing to each specific player fixed it. Thank you all for your help : )
 
Status
Not open for further replies.
Top