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

Need Pro Help

Status
Not open for further replies.
Level 7
Joined
Feb 22, 2009
Messages
158
So listen up, and please help. When i tested it in battle.net with players. Everybody get Disconnect from the map. I tested with my best friend, he said. I don't know but i got dc from your map.

It cannot be. Triggers are leakless.
Please help somebody.

Multiplayer: Disconnects all players, but not host
Singleplayer: Works Perfectly
 

Attachments

  • Nightmare Arena 0.02.w3x
    31.1 KB · Views: 70
Level 19
Joined
Feb 4, 2009
Messages
1,313
  • Custom script: call DestroyTrigger(GetTriggeringTrigger())
destroying triggers might cause bugs somehow
if that's not the mistake disable 50% of the triggers and try again
if nothing happens disable the other 50% instead
next do with 25%....until you have found the evil trigger

you also should not call "DoNothing" since it does nothing but bring down your performance by a little

  • Special Effect - Create a special effect at tempPoint using Abilities\Spells\Human\MassTeleport\MassTeleportTarget.mdl
  • Wait 3.00 seconds
  • Special Effect - Destroy (Last created special effect)
if there is another special effect created within these 3 seconds it will overwrite the last created special effect and be destroyed instead
to fix this you will have to save the effect in for example a local variable

additionally you should prefer wait 3.00 game time seconds since the other wait can be different for each player and cause bugs this way
 
Level 12
Joined
Apr 15, 2008
Messages
1,063
  • Camera - Pan camera as necessary for (Owner of (Buying unit)) to tempPoint over 0.00 seconds
Everyone disconnecting is called "game desynchronization", basically the problem is that the script (triggers) runs for all users on their computers. Normally they all run in the same way, return same results and affect the game in same way for all users. Once they somehow desynchronize, the game is in different state for each player and it disconnects all players with "wrong" data.
You can get desynchronization for example by using GetLocationZ() on terrain deformations, (Target of current camera view), GetLocalPlayer() or, previously mentioned, "Pan camera as necessary", it's bugged somehow.

Solution: replace with regular "pan camera"
 
Level 12
Joined
Apr 15, 2008
Messages
1,063
In GUI, it's, so far I know, only "Target of current camera view" and "Pan camera as necessary". The other ones are in JASS, GetLocalPlayer() is used quite often (desynchronizing some things won't cause a problem, for example displaying text for only only player). If want to know more, do a google search for "GetLocalPlayer()", there are many of tutorials on that.
What you need is to get rid of "Pan camera as necessary" and replace it with "Pan camera"
 
Level 22
Joined
Nov 14, 2008
Messages
3,256
GetLocalPlayer desyncs whenever it is about to create a handle (most of them, as they now are called agents which extends handles). All types which are referencecounted in wc3, thus if something is created locally, it would never work because the packets between the computers and the server would have mismatches. But for instance, a string or integer or real or something like that can have their local value, as long as it doesnt involve creating something which results in differences. Eg, you can not hide a unit, because that would make a unit available on the map for one player while it wouldnt be for someone else. So basically, one would be allowed to attack while the other believes it doesnt can move at all and is gone. Thats an example of a desync.
Multiboards and leaderboards are things which doesnt desync. Or well rather, setting a value on a board locally would, as it is in multiboard, actually setting a 'multiboarditem' value. But nothing will never happend if you only show the leaderboards locally. That is pretty much what happends when a team player leaves a ladder game: A multiboard is created but only showed for the team.

JASS:
call DestroyTrigger(GetTriggeringTrigger())
Can slightly improve map performance, BUT it can also fuck up the handle indexing and other stuff. It rarely happens, but it can happen. Many would advise you not to use it while others say it's completely safe. I have never experienced any problems, but others have.

Some handle id's (the values you get from H2I() or GetHandleId()) might get fucked up.
And many spells and systems use these, but the chance of it happening is slim at best.

This should explain the most
 
Status
Not open for further replies.
Top