Disconnecting problems.

alexho

New Member
Reaction score
0
Hi I have a few problems with my map my triggers seem to work when I host it for myself but when i test with friends they get disconnected.. I don't know what triggers do it and I've tried disabling some it worked at first with some triggers that use complicated arrays but now it comes back again when ever I work on the map. Its a really weird problem, I don't know what causes it but I think it could be somehow a trigger leak or some sort but the rest of the inital triggers that are after the game in functions their fine. A few of my triggers that I just seem to think have something wrong w/ them ill put them here, the other ones I'm 100% sure they cant cause people to disconnect please help with any input into what could be causing these problems, here are my codes (i use alot of arrays and those seem to cause most troubles and if then statements):

that one is kind of retarded but I don't think its really causing the problem. Basically the function is to create a level 1 type pistole marine IF the player is actually playing (human player)
Code:
create
    Events
        Time - Elapsed game time is 1.00 seconds
    Conditions
    Actions
        Wait until (startgame Equal to 1), checking every 1.00 seconds
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                startgame Equal to 1
            Then - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        (Player 1 (Red) slot status) Equal to Is playing
                    Then - Actions
                        Unit - Create 1 weaponsupr[1] for playersdelta[1] at (Center of top team <gen>) facing Default building facing degrees
                        Set PLAYER_UNITS[1] = (Last created unit)
                        Sound - Play TheHornOfCenarius <gen>
                        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                            If - Conditions
                                (Player 2 (Blue) slot status) Equal to Is playing
                            Then - Actions
                                Unit - Create 1 weaponsupr[1] for playersdelta[2] at (Center of top team <gen>) facing Default building facing degrees
                                Set PLAYER_UNITS[2] = (Last created unit)
                                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                    If - Conditions
                                        (Player 3 (Teal) slot status) Equal to Is playing
                                    Then - Actions
                                        Unit - Create 1 weaponsupr[1] for playersdelta[3] at (Center of top team <gen>) facing Default building facing degrees
                                        Set PLAYER_UNITS[3] = (Last created unit)
                                        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                            If - Conditions
                                                (Player 4 (Purple) slot status) Equal to Is playing
                                            Then - Actions
                                                Unit - Create 1 weaponsupr[1] for playersdelta[4] at (Center of top team <gen>) facing Default building facing degrees
                                                Set PLAYER_UNITS[4] = (Last created unit)
                                                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                    If - Conditions
                                                        (Player 5 (Yellow) slot status) Equal to Is playing
                                                    Then - Actions
                                                        Unit - Create 1 weaponsupr[1] for playersdelta[5] at (Center of top team <gen>) facing Default building facing degrees
                                                        Set PLAYER_UNITS[5] = (Last created unit)
                                                        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                            If - Conditions
                                                                (Player 6 (Orange) slot status) Equal to Is playing
                                                            Then - Actions
                                                                Unit - Create 1 weaponsupr[1] for playersdelta[6] at (Center of top team <gen>) facing Default building facing degrees
                                                                Set PLAYER_UNITS[6] = (Last created unit)
                                                                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                                    If - Conditions
                                                                        (Player 7 (Green) slot status) Equal to Is playing
                                                                    Then - Actions
                                                                        Unit - Create 1 weaponsupr[1] for playersgamma[7] at (Center of bottom team <gen>) facing Default building facing degrees
                                                                        Set PLAYER_UNITS[7] = (Last created unit)
                                                                        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                                            If - Conditions
                                                                                (Player 8 (Pink) slot status) Equal to Is playing
                                                                            Then - Actions
                                                                                Unit - Create 1 weaponsupr[1] for playersgamma[8] at (Center of bottom team <gen>) facing Default building facing degrees
                                                                                Set PLAYER_UNITS[8] = (Last created unit)
                                                                                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                                                    If - Conditions
                                                                                        (Player 9 (Gray) slot status) Equal to Is playing
                                                                                    Then - Actions
                                                                                        Unit - Create 1 weaponsupr[1] for playersgamma[9] at (Center of bottom team <gen>) facing Default building facing degrees
                                                                                        Set PLAYER_UNITS[9] = (Last created unit)
                                                                                        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                                                            If - Conditions
                                                                                                (Player 10 (Light Blue) slot status) Equal to Is playing
                                                                                            Then - Actions
                                                                                                Unit - Create 1 weaponsupr[1] for playersgamma[10] at (Center of bottom team <gen>) facing Default building facing degrees
                                                                                                Set PLAYER_UNITS[10] = (Last created unit)
                                                                                                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                                                                    If - Conditions
                                                                                                        (Player 11 (Dark Green) slot status) Equal to Is playing
                                                                                                    Then - Actions
                                                                                                        Unit - Create 1 weaponsupr[1] for playersgamma[11] at (Center of bottom team <gen>) facing Default building facing degrees
                                                                                                        Set PLAYER_UNITS[11] = (Last created unit)
                                                                                                        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                                                                                                            If - Conditions
                                                                                                                (Player 12 (Brown) slot status) Equal to Is playing
                                                                                                            Then - Actions
                                                                                                                Unit - Create 1 weaponsupr[1] for playersgamma[12] at (Center of bottom team <gen>) facing Default building facing degrees
                                                                                                                Set PLAYER_UNITS[12] = (Last created unit)
                                                                                                            Else - Actions
                                                                                                    Else - Actions
                                                                                            Else - Actions
                                                                                    Else - Actions
                                                                            Else - Actions
                                                                    Else - Actions
                                                            Else - Actions
                                                    Else - Actions
                                            Else - Actions
                                    Else - Actions
                            Else - Actions
                    Else - Actions
            Else - Actions

Code:
add upgrade plus
    Events
        Unit - A unit Dies
    Conditions
    Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                ((Killing unit) is Mechanical) Equal to False
                ((Dying unit) is Mechanical) Equal to False
                ((Owner of (Dying unit)) is an ally of (Owner of (Killing unit))) Equal to False
                (Owner of (Killing unit)) Not equal to (Owner of (Dying unit))
            Then - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Killing unit) is Mechanical) Equal to False
                        upgrades111[(Player number of (Owner of (Killing unit)))] Greater than or equal to 6
                    Then - Actions
                        Set PLAYER_UNITS[(Player number of (Owner of (Killing unit)))] = (Killing unit)
                        Hero - Drop the item from slot 1 of (Killing unit)
                        Set setitem_slot1n6_giveback[1] = (Item-type of (Last dropped item))
                        Item - Remove (Last dropped item)
                        Hero - Drop the item from slot 2 of (Killing unit)
                        Set setitem_slot1n6_giveback[2] = (Item-type of (Last dropped item))
                        Item - Remove (Last dropped item)
                        Hero - Drop the item from slot 3 of (Killing unit)
                        Set setitem_slot1n6_giveback[3] = (Item-type of (Last dropped item))
                        Item - Remove (Last dropped item)
                        Hero - Drop the item from slot 4 of (Killing unit)
                        Set setitem_slot1n6_giveback[4] = (Item-type of (Last dropped item))
                        Item - Remove (Last dropped item)
                        Hero - Drop the item from slot 5 of (Killing unit)
                        Set setitem_slot1n6_giveback[5] = (Item-type of (Last dropped item))
                        Item - Remove (Last dropped item)
                        Hero - Drop the item from slot 6 of (Killing unit)
                        Set setitem_slot1n6_giveback[6] = (Item-type of (Last dropped item))
                        Item - Remove (Last dropped item)
                        Unit - Remove PLAYER_UNITS[(Player number of (Owner of (Killing unit)))] from the game
                        Unit - Create 1 weaponsupr[6] for (Owner of (Killing unit)) at (Position of (Killing unit)) facing Default building facing degrees
                        Hero - Create setitem_slot1n6_giveback[1] and give it to (Last created unit)
                        Hero - Create setitem_slot1n6_giveback[2] and give it to (Last created unit)
                        Hero - Create setitem_slot1n6_giveback[3] and give it to (Last created unit)
                        Hero - Create setitem_slot1n6_giveback[4] and give it to (Last created unit)
                        Hero - Create setitem_slot1n6_giveback[5] and give it to (Last created unit)
                        Hero - Create setitem_slot1n6_giveback[6] and give it to (Last created unit)
                        Set PLAYER_UNITS[(Player number of (Owner of (Killing unit)))] = (Killing unit)
                        Unit Group - Pick every unit in (Units owned by (Owner of (Killing unit))) and do (Selection - Select (Picked unit))
                        Special Effect - Create a special effect at (Position of (Last created unit)) using Abilities\Spells\Human\MarkOfChaos\MarkOfChaosTarget.mdl
                        Special Effect - Create a special effect attached to the hand,left of (Last created unit) using Doodads\Cinematic\TownBurningFireEmitter\TownBurningFireEmitter.mdl
                        Special Effect - Create a special effect attached to the hand,right of (Last created unit) using Doodads\Cinematic\TownBurningFireEmitter\TownBurningFireEmitter.mdl
                        Sound - Play unstoppable <gen>
                        Wait 2.00 seconds
                        Sound - Play reload <gen>
                    Else - Actions
                Set upgrades111[(Player number of (Owner of (Killing unit)))] = (upgrades111[(Player number of (Owner of (Killing unit)))] + 1)
                Hero - Drop the item from slot 1 of (Killing unit)
                Hero - Drop the item from slot 2 of (Killing unit)
                Hero - Drop the item from slot 3 of (Killing unit)
                Hero - Drop the item from slot 4 of (Killing unit)
                Hero - Drop the item from slot 5 of (Killing unit)
                Hero - Drop the item from slot 6 of (Killing unit)
                Unit - Remove PLAYER_UNITS[(Player number of (Owner of (Killing unit)))] from the game
                Unit - Create 1 weaponsupr[upgrades111[(Player number of (Owner of (Killing unit)))]] for (Owner of (Killing unit)) at (Position of (Killing unit)) facing Default building facing degrees
                Set PLAYER_UNITS[(Player number of (Owner of (Last created unit)))] = (Last created unit)
                Unit Group - Pick every unit in (Units owned by (Owner of (Killing unit))) and do (Selection - Select (Picked unit))
                Special Effect - Create a special effect at (Position of (Last created unit)) using Abilities\Spells\Items\AIre\AIreTarget.mdl
                Sound - Play reload <gen>
            Else - Actions
 

Sooda

Diversity enchants
Reaction score
318
> Wait until (startgame Equal to 1), checking every 1.00 seconds

Can' t you just run that initialization trigger from trigger what sets startgame 1 instead of checking each second ?
Desyncs isn' t my speciality. It makes it so hard to spot them because it could be one thing in your map but you got 200 triggers like this one.

EDIT: Your first trigger can be just done like this:
Code:
Easy Init
    Events
    Conditions
    Actions
        For each (Integer A) from 1 to 12, do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Player((Integer A))) slot status) Equal to Is playing
                        (Integer A) Less than or equal to 6
                    Then - Actions
                        Unit - Create 1 weaponsupr[1] for playersdelta[(Integer A)] at (Center of Center of top team <gen>) facing Default building facing degrees
                        Set PLAYER_UNITS[(Integer A)] = (Last created unit)
                    Else - Actions
                        Unit - Create 1 weaponsupr[1] for playersgamma[(Integer A)] at (Center of Center of bottom team <gen>) facing Default building facing degrees
                        Set PLAYER_UNITS[(Integer A)] = (Last created unit)
I recommend you to learn loops because they help alot. Anyway in your first trigger isn' t nothing what could desync (Even in yourd wierd one.). But I don' t know about other though right now.
As a side not always destroy your special effects because otherwise your game would go slow/ laggy soon.
 

Ghan

Administrator - Servers are fun
Staff member
Reaction score
889
I believe that camera movements can cause de-synchs on battlenet, so, do you have any cinematic triggers where the camera moves?
 

alexho

New Member
Reaction score
0
Thanks ya I know the for loops like integer A are really useful make it easier :p but I didn't really use them that much in this thanks for the idea

ya I don't have any camera movements in this map, its probably a leak or something that just lags other players out to the point of disconnection or not even lag them out or it doesn't read it it jsut OVERLOADs and this causes disconnection.. Otherwise I have absolutely have no idea what is causing it :( I don't see any of my triggers can cause this strange disconnection problem..

thanks sooda and ghan for your help I appreciate it
 
M

Mythic Fr0st

Guest
Often disconnection is memory leaks, I can not explain right now, but ask for a memory leak tutorial,

g2g
 

alexho

New Member
Reaction score
0
actually when i tried it it doesn't work what I have in my map is to have the integer start at 0 but you have to choose the game team kills which is 30,60,90 then when you type 1 it enables the create trigger and changes the integer = 1

I dont know where to go from here..

thats the create
Code:
create
    Events
    Conditions
    Actions
        For each (Integer A) from 1 to 12, do (Actions)
            Loop - Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                ((Player((Integer A))) slot status) Equal to Is playing
                (Integer A) Less than or equal to 6
            Then - Actions
                Unit - Create 1 weaponsupr[1] for playersdelta[(Integer A)] at (Center of top team <gen>) facing Default building facing degrees
                Set PLAYER_UNITS[(Integer A)] = (Last created unit)
            Else - Actions
                Unit - Create 1 weaponsupr[1] for playersgamma[(Integer A)] at (Center of bottom team <gen>) facing Default building facing degrees
                Set PLAYER_UNITS[(Integer A)] = (Last created unit)

here is one of the typing things:
Code:
pick 1
    Events
        Player - Player 1 (Red) types a chat message containing 30 as An exact match
    Conditions
    Actions
        Set picked_lives = 30
        Set startgame = 1
        Trigger - Run create <gen> (checking conditions)
        Trigger - Turn off pick 2 <gen>
        Trigger - Turn off pick 3 <gen>
        Trigger - Turn off (This trigger)
 
M

Mythic Fr0st

Guest
I see the crash problem try fixing this:

Below is what it should be
Code:
create
    Events
    Conditions
    Actions
        For each (Integer A) from 1 to 12, do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        ((Player((Integer A))) slot status) Equal to Is playing
                        (Integer A) Less than or equal to 6
                    Then - Actions
                        Unit - Create 1 weaponsupr[1] for playersdelta[(Integer A)] at (Center of top team <gen>) facing Default building facing degrees
                        Set PLAYER_UNITS[(Integer A)] = (Last created unit)
                    Else - Actions
                        Unit - Create 1 weaponsupr[1] for playersgamma[(Integer A)] at (Center of bottom team <gen>) facing Default building facing degrees
                        Set PLAYER_UNITS[(Integer A)] = (Last created unit)

Your If statement was not in the Integer A loop, using Integer A when it's not in the loop will crash the game...

Try fixing that, do you understand what I mean?
 

alexho

New Member
Reaction score
0
O.k. when I tested it it seems as the loop doesn't work when I type 30 it doesn't do anything for the create loop trigger.

I am making the rest of the variables into loops:

this sets the players into the variable player and delta or gamma
Code:
team delta
    Events
        Map initialization
    Conditions
    Actions
        For each (Integer A) from 1 to 12, do (Actions)
            Loop - Actions
                If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    If - Conditions
                        (Integer A) Less than or equal to 6
                    Then - Actions
                        Set playersdelta[(Integer A)] = (Player((Integer A)))
                    Else - Actions
                        Set playersgamma[(Integer A)] = (Player((Integer A)))

then theres another code i put it above that uses the variable of PLAYERS_UNITS to store main units 4 players

I kinda understand but here is my triggers if somebody could look at them someway lol
http://h1.ripway.com/ajizizoc/triggersproblem.zip

eh i dont get what you mean ;\
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top