REND.Soul.42
New Member
- Reaction score
- 0
Hi! This is my very first thread. I'm currently loving this forum
I have a question: can you use MultiboardSetTitleText() and GetLocalPlayer() like this?
What I want to happen is like in DOTA's multiboard title (different title for each player).
The string is added to everyone's string table and then the multiboard title is set locally.
Will this cause a desync? I'm starting to become more paranoid about desyncs...
If it is indeed fine to do, I just don't have to use MultiboardGetTitleText() ?
EDIT: I think the code above desyncs players.. How about this?
Will this work? :/
I have a question: can you use MultiboardSetTitleText() and GetLocalPlayer() like this?
What I want to happen is like in DOTA's multiboard title (different title for each player).
JASS:
function MyFunction takes nothing returns nothing
local string s
local integer i = 0
loop
exitwhen i > 11
set s = "You are Player " + I2S(i+1) + "!"
if ( GetLocalPlayer() == Player(i) ) then
call MultiboardSetTitleText(udg_My_Multiboard, s)
endif
set i = i + 1
endloop
endfunction
The string is added to everyone's string table and then the multiboard title is set locally.
Will this cause a desync? I'm starting to become more paranoid about desyncs...
If it is indeed fine to do, I just don't have to use MultiboardGetTitleText() ?
EDIT: I think the code above desyncs players.. How about this?
JASS:
function MyFunction takes nothing returns nothing
local string array s
local integer i = 0
loop
exitwhen i > 11
set s<i> = "You are Player " + I2S(i+1) + "!"
set i = i + 1
endloop
call MultiboardSetTitleText(udg_My_Multiboard, s[GetPlayerId(GetLocalPlayer())])
endfunction
</i>
Will this work? :/