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

(desyncs)

Status
Not open for further replies.
Level 6
Joined
Jul 21, 2011
Messages
139
please take a quick look at this thread
http://www.wc3c.net/showthread.php?t=109953&highlight=desync

are they implying that for example simple triggers like:
  • Actions
    • Player - Add 1000 to Player 1 (red) gold actual
    • Player - Set Player 11 (dark green) gold actual to 750
makes the map desync? if yes can someone please name more examples

im also interesed in learning more about this "local" thing people keep talking about, thx
 
Level 26
Joined
Aug 18, 2009
Messages
4,097
No. They are saying those actions (actions that affect the gameplay) only potentially make the game desync if they are within local blocks. Local blocks in the meaning of parts of code that do not get run for every player but only a part of them. You can produce this state by using functions that inherently return async (player-different) values and evaluate a condition with it. The selection will then fire different branches for the different players, thereby you can apply player-specific directives.

The most simple async function would be GetLocalPlayer(), which just returns the player the code runs for. Common uses of local blocks are altering graphics and acustics for a single player. Since this is not of relevance to other players in the game, it does not pose a problem while matching network traffic. Adding gold on a single client could however change the outcome of the game of this player in comparison to the others and this inconsistency may therefore be detected by the engine.
 
Level 6
Joined
Jul 21, 2011
Messages
139
didnt understand everything you said but

i been suffering desyncs, most of the time at the start of the map, i just removed the 2 triggers that added gold to 2 players in map init, do you think the desync problem should be fixed now? ill try my map again when im free in a while
 
Level 26
Joined
Aug 18, 2009
Messages
4,097
There are more reasons for desyncs or at least it's not always as obvious. Even without triggers I remember one problem. If it's at the start of the map and appears most of the time, it should be relatively easy to spot by consecutively deactivating content of your map and testing. But no, we cannot guess it.
 
Level 6
Joined
Jul 21, 2011
Messages
139
cant do testing at the moment, but ill keep trying until theres no more desyncs, check this thread tomorrow maybe i post something new
 
Status
Not open for further replies.
Top