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)
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