• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

GetLocalPlayer() Desyncs.

Status
Not open for further replies.
Just wondering..
JASS:
function Trig_Untitled_Trigger_002_Actions takes nothing returns nothing
    local string s = "units\\human\\Rifleman\\Rifleman.mdl"

    if GetLocalPlayer() != Player(1) then
        set s = ""
    endif
    call AddSpecialEffect(s, -11133.8, -12299.7)
endfunction

//===========================================================================
function InitTrig_Untitled_Trigger_002 takes nothing returns nothing
    set gg_trg_Untitled_Trigger_002 = CreateTrigger(  )
    call TriggerAddAction( gg_trg_Untitled_Trigger_002, function Trig_Untitled_Trigger_002_Actions )
endfunction

Why does this desync? There is technically no hanles inside of the "If" so it should not desync, but it does, any ideas?

PS: This is a test trigger, dont bother inlining it.
 
Oh, wait.

  • DefaultTrigger001
    • Events
      • Time - Elapsed game time is 0.00 seconds
    • Conditions
    • Actions
      • Custom script: if GetLocalPlayer() == Player(0) then
      • Multiboard - Create a multiboard with 1 columns and 1 rows, titled TESTING
      • Multiboard - Show (Last created multiboard)
      • Custom script: endif
      • Custom script: if GetLocalPlayer() == Player(1) then
      • Multiboard - Create a multiboard with 1 columns and 1 rows, titled TESTING1
      • Multiboard - Show (Last created multiboard)
      • Custom script: endif
This desyncs, right? -.- i think thats my problem
 
Level 8
Joined
Aug 6, 2008
Messages
451
Creating stuff for one player only desyncs. You should create that multiboard for everyone, and then hide/show it locally.
 

Dr Super Good

Spell Reviewer
Level 64
Joined
Jan 18, 2005
Messages
27,202
Technically, if you map the multiboards to arrays, you should be able to edit them locally as the handles would be constant and just the updating of then local. This however will up memory usage of the map and only can be done in JASS.

For GUI, local display is the only way.

I think floating text are the only ones you can create out of sync as they are graphical (no syncing) and use a special handle range which does not conflict with normal handles.
 
Status
Not open for further replies.
Top