• 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.
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!
  • ✅ The POLL for Hive's Texturing Contest #34 is OPEN! Vote for the TOP 3 SKINS! 🔗Click here to cast your vote!
  • ✅ The POLL for Hive's Techtree Contest #20 is OPEN! Vote for the TOP 3 FACTIONS! 🔗Click here to cast your vote!

Multiboard issues

Status
Not open for further replies.
Level 11
Joined
Feb 22, 2006
Messages
752
I'm making an rpg and I need multiboards for each player showing combat stats, etc. So basically, I use the following function to create separate multiboards for each player:

JASS:
function CreateMB takes player p, integer row, integer column returns multiboard
    local multiboard mb = CreateMultiboard()
    call MultiboardSetRowCount(mb, row)
    call MultiboardSetColumnCount(mb, column)
    call MultiboardDisplay(mb, p == GetLocalPlayer())
    return mb
endfunction

Basically, it works fine when I only call this function once (e.g. create one multiboard for one player), but when i call it multiple times to create multiboards for all players, the multiboards don't show up. Can somebody PLEASE tell me what's wrong?
 
maybe just copy+paste and change it individually for each player? that looks like JASS to me and i've never even tried JASS before. i doubt i would understand it for a while too :?
 
Ok, I've found more information on this bug, and I'm hoping it might help some of you figure out what's wrong. In my map, I have six human player slots, so therefore I create 6 different multiboards, one for each player. Apparently, when I do so, for players 1-5, the multiboards do not show up, but for player 6, ALL of the multiboards show up. The following is the custom script I use to create and display the multiboards.

JASS:
function CreateMB takes player p, integer row, integer column returns multiboard
    local multiboard mb = CreateMultiboard()
    call MultiboardSetRowCount(mb, row)
    call MultiboardSetColumnCount(mb, column)
    call MultiboardDisplay(mb, p == GetLocalPlayer())
    return mb
endfunction

function Trig_Create_Actions takes nothing returns nothing
    set udg_Multiboard[0] = CreateMB(Player(0), 2, 3)
    set udg_Multiboard[1] = CreateMB(Player(1), 2, 3)
    set udg_Multiboard[2] = CreateMB(Player(2), 2, 3)
    set udg_Multiboard[3] = CreateMB(Player(3), 2, 3)
    set udg_Multiboard[4] = CreateMB(Player(4), 2, 3)
    set udg_Multiboard[5] = CreateMB(Player(5), 2, 3)
    call TriggerExecute( gg_trg_Text )
    call TriggerExecute( gg_trg_Variables )
endfunction

//===========================================================================
function InitTrig_Create takes nothing returns nothing
    set gg_trg_Create = CreateTrigger(  )
    call TriggerRegisterTimerEventSingle( gg_trg_Create, 0.5 )
    call TriggerAddAction( gg_trg_Create, function Trig_Create_Actions )
endfunction
 
Status
Not open for further replies.
Back
Top