1. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  2. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  3. We have recently started the 16th edition of the Mini Mapping Contest. The theme is mini RPG. Do check it out and have fun.
    Dismiss Notice
  4. Choose your ride to damnation in the 5th Special Effect Contest Poll.
    Dismiss Notice
  5. The winners of the 13th Techtree Contest have been announced!
    Dismiss Notice
  6. The 13th Music Contest Poll is up! Vote for the best tracks in this symphony of frost and flame.
    Dismiss Notice
  7. Race against the odds and Reforge, Don't Refund. The 14th Techtree Contest has begun!
    Dismiss Notice
  8. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Delay Problems

Discussion in 'Triggers & Scripts' started by deathdoorway, Jul 19, 2012.

  1. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    What can exactly cause delay in a map
     
  2. KhaosMachine

    KhaosMachine

    Joined:
    Dec 30, 2011
    Messages:
    117
    Resources:
    6
    Spells:
    6
    Resources:
    6
    Much things causes it:

    Ð-Leaks
    Ð-Much units/doodas
    Ð-Some process
    Ð-Poor machine
    Ð-Etc.
     
  3. PurgeandFire

    PurgeandFire

    Code Moderator

    Joined:
    Nov 11, 2006
    Messages:
    7,426
    Resources:
    18
    Icons:
    1
    Spells:
    4
    Tutorials:
    9
    JASS:
    4
    Resources:
    18
    A multitude of things can cause delay.

    In particular:
    - Slow internet speeds/high latency.
    - Triggers with a lot of overhead. (usually ones with a lot of functions, or often periodic things.. they may cause short freezes)
    - Casting a spell, learning a spell, or creating an effect for the first time. (it is best to preload stuff on map init, otherwise there may be a short lag spike the first time those things are used)
    - Waits. (waits are usually inaccurate when people try to use them for really small periods like 0.03, and they sometimes try to loop it to mimic a timer. However, it will suffer delays from being inaccurate and general lag)

    And probably a bunch of other things. What problems are you experiencing?
     
  4. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Hmm i know my map has no leaks, it does have around 1000 custom unit or more, spells around 3000, 5k doodades. How do you preload stuff on map init?
     
  5. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,979
    Resources:
    17
    Spells:
    17
    Resources:
    17
    You know there is a difference between Lag and Delay.
    Lag which is mostly causes from leaks while Delay is mostly causes from your Internet Connection Speed somehow.

    I don't believe leaks are causing the Delay.
     
  6. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    I can play warlocks and not have delay or lag. That game takes serious internet. In this map for some reason more players more delay, or longer the game play more delay. It doesnt lag at all just delay
     
  7. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,979
    Resources:
    17
    Spells:
    17
    Resources:
    17
    Did you use GetLocalPlayer() in any of your trigger in that map ?
     
  8. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    I'm a GUI, most custom scripts are to get rid of leaks not start or set up a variable
     
  9. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,979
    Resources:
    17
    Spells:
    17
    Resources:
    17
    That function is mostly used in games nowadays to only affect one Player so that only that Player can see the actual effect.

    Oh well..
     
  10. KhaosMachine

    KhaosMachine

    Joined:
    Dec 30, 2011
    Messages:
    117
    Resources:
    6
    Spells:
    6
    Resources:
    6
    Maybe you want upload your map here and we can check it to give the solution
     
  11. Magtheridon96

    Magtheridon96

    Joined:
    Dec 12, 2008
    Messages:
    6,006
    Resources:
    26
    Maps:
    1
    Spells:
    8
    Tutorials:
    7
    JASS:
    10
    Resources:
    26
    If you upload your map, we might be able to directly tell you what's causing problems.

    edit
    He sent me his map, and I helped him solve the problem.

    It's mostly memory management and spell preloading. (Not nulling handles, some leaks here and there, etc..)

    @deathdoorway, if you still have problems, feel free to bump this thread and describe the problem.
     
    Last edited: Jul 22, 2012
  12. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    I'm now having delay problems when spawning a dungeon. I have a timed dungeon that every 30 seconds Spawns lets say 20 creeps max. Its delaying people about 2-3 seconds on each cycle. I'll post the triggers

    Hero Group
    • Kobold Hero Group
      • Events
        • Unit - A unit enters Kobold Entrence <gen>
      • Conditions
        • ((Triggering unit) is A Hero) Equal to True
        • (Owner of (Triggering unit)) Not equal to Player 11 (Dark Green)
      • Actions
        • Set LeakPoint[265] = ((Center of Kobold Attack Target <gen>) offset by (0.00, 0.00))
        • Unit - Move (Entering unit) instantly to LeakPoint[265], facing Default building facing degrees
        • Camera - Pan camera for (Owner of (Entering unit)) to LeakPoint[265] over 0.00 seconds
        • Custom script: call RemoveLocation(udg_LeakPoint[265])
        • Game - Display to (Player group((Owner of (Triggering unit)))) the text: |cff7777aaHelp Gary...
        • Sound - Play FootmanPissed <gen> at 100.00% volume, attached to (Triggering unit)
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Number of units in KoboldheroGroup) Greater than or equal to 1
          • Then - Actions
            • Unit Group - Add (Triggering unit) to KoboldheroGroup
          • Else - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Number of units in KoboldheroGroup) Equal to 0
          • Then - Actions
            • Unit Group - Add (Triggering unit) to KoboldheroGroup
            • Set LeakPoint[375] = (Center of Fontain Reg <gen>)
            • Unit - Create 1 Fountain of Life (Kobold) for Player 11 (Dark Green) at LeakPoint[375] facing 270.00 degrees
            • Custom script: call RemoveLocation(udg_LeakPoint[375])
            • Set LeakPoint[375] = (Center of Kobold Pala SPR <gen>)
            • Unit - Create 1 Gary Moore for Player 11 (Dark Green) at LeakPoint[375] facing Default building facing degrees
            • Custom script: call RemoveLocation(udg_LeakPoint[375])
            • Countdown Timer - Create a timer window for (Last started timer) with title Kobold Attack
            • Set Kobold_TimerWindow = (Last created timer window)
            • Countdown Timer - Change the color of the title for Kobold_TimerWindow to (100.00%, 0.00%, 0.00%) with 10.00% transparency
            • Countdown Timer - Change the color of the time for Kobold_TimerWindow to (0.00%, 100.00%, 0.00%) with 15.00% transparency
            • Set KoboldTimer = (Last started timer)
            • Countdown Timer - Start KoboldTimer as a One-shot timer that will expire in 400.00 seconds
            • Trigger - Turn on Kobolds Unit <gen>
          • Else - Actions


    Spawning units
    • Kobolds Unit
      • Events
        • Time - Every 1.00 seconds of game time
      • Conditions
        • (KoboldheroGroup is empty) Equal to False
      • Actions
        • Set KobaldAttackgroup = (Units in Kobold Weather <gen> owned by Player 12 (Brown))
        • Set LeakPoint[376] = (Center of Kobold Attack Target <gen>)
        • Unit Group - Pick every unit in KobaldAttackgroup and do (Actions)
          • Loop - Actions
            • Unit - Order (Picked unit) to Attack-Move To LeakPoint[376]
        • Custom script: call RemoveLocation(udg_LeakPoint[376])
        • Custom script: call DestroyGroup(udg_KobaldAttackgroup)
        • Set KobaldAttackgroup = (Units in Kobold Weather <gen> owned by Player 11 (Dark Green))
        • Set LeakPoint[374] = (Center of Kobold Attack Target <gen>)
        • Unit Group - Pick every unit in KobaldAttackgroup and do (Actions)
          • Loop - Actions
            • Unit - Order (Picked unit) to Attack-Move To LeakPoint[374]
        • Custom script: call RemoveLocation(udg_LeakPoint[374])
        • Custom script: call DestroyGroup(udg_KobaldAttackgroup)
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Integer((Remaining time for KoboldTimer))) Equal to 400
          • Then - Actions
            • Countdown Timer - Show Kobold_TimerWindow
            • Game - Display to (All players matching (((Triggering unit) is in KoboldheroGroup) Equal to True)) the text: |cff7777aaBe prepar...
            • Set LeakPoint[374] = (Center of Kobold Attack Target <gen>)
            • Sound - Play KnightWarcry1 <gen>
            • Floating Text - Create floating text that reads |cff7777aaBe prepar... at LeakPoint[374] with Z offset 2.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
            • Floating Text - Set the velocity of (Last created floating text) to 105.00 towards 90.00 degrees
            • Floating Text - Change (Last created floating text): Disable permanence
            • Floating Text - Change the lifespan of (Last created floating text) to 5.00 seconds
            • Custom script: call RemoveLocation(udg_LeakPoint[374])
          • Else - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • Or - Any (Conditions) are true
              • Conditions
                • (Integer((Remaining time for KoboldTimer))) Equal to 390
                • (Integer((Remaining time for KoboldTimer))) Equal to 360
                • (Integer((Remaining time for KoboldTimer))) Equal to 330
                • (Integer((Remaining time for KoboldTimer))) Equal to 300
                • (Integer((Remaining time for KoboldTimer))) Equal to 270
                • (Integer((Remaining time for KoboldTimer))) Equal to 240
                • (Integer((Remaining time for KoboldTimer))) Equal to 210
                • (Integer((Remaining time for KoboldTimer))) Equal to 180
                • (Integer((Remaining time for KoboldTimer))) Equal to 150
                • (Integer((Remaining time for KoboldTimer))) Equal to 120
                • (Integer((Remaining time for KoboldTimer))) Equal to 90
                • (Integer((Remaining time for KoboldTimer))) Equal to 60
                • (Integer((Remaining time for KoboldTimer))) Equal to 30
          • Then - Actions
            • For each (Integer A) from 1 to 8, do (Actions)
              • Loop - Actions
                • Set LeakPoint[376] = (Center of Kobold Attack Target <gen>)
                • Set LeakPoint[377] = (Center of Kobold Spawn 1 <gen>)
                • Unit - Create 1 Kobold Grunt for Player 12 (Brown) at LeakPoint[377] facing Default building facing degrees
                • Unit - Order (Last created unit) to Attack-Move To LeakPoint[376]
                • Custom script: call RemoveLocation(udg_LeakPoint[377])
                • Set LeakPoint[378] = (Center of Kobold Spawn 2 <gen>)
                • Unit - Create 1 Kobold Grunt for Player 12 (Brown) at LeakPoint[378] facing Default building facing degrees
                • Unit - Order (Last created unit) to Attack-Move To LeakPoint[376]
                • Custom script: call RemoveLocation(udg_LeakPoint[378])
                • Custom script: call RemoveLocation(udg_LeakPoint[376])
          • Else - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • Or - Any (Conditions) are true
              • Conditions
                • (Integer((Remaining time for KoboldTimer))) Equal to 360
                • (Integer((Remaining time for KoboldTimer))) Equal to 300
                • (Integer((Remaining time for KoboldTimer))) Equal to 240
                • (Integer((Remaining time for KoboldTimer))) Equal to 180
                • (Integer((Remaining time for KoboldTimer))) Equal to 120
                • (Integer((Remaining time for KoboldTimer))) Equal to 60
          • Then - Actions
            • For each (Integer A) from 1 to 3, do (Actions)
              • Loop - Actions
                • Set LeakPoint[376] = (Center of Kobold Attack Target <gen>)
                • Set LeakPoint[377] = (Center of Kobold Spawn 1 <gen>)
                • Unit - Create 1 Kobold Officer for Player 12 (Brown) at LeakPoint[377] facing Default building facing degrees
                • Unit - Add Vampire Mark (Vampire) to (Last created unit)
                • Unit - Add Devotion Aura (Kobold officer) to (Last created unit)
                • Unit - Add Endurance Aura (Kobold Officer) to (Last created unit)
                • Unit - Order (Last created unit) to Attack-Move To LeakPoint[376]
                • Custom script: call RemoveLocation(udg_LeakPoint[377])
                • Set LeakPoint[378] = (Center of Kobold Spawn 2 <gen>)
                • Unit - Create 1 Kobold Officer for Player 12 (Brown) at LeakPoint[378] facing Default building facing degrees
                • Unit - Add Thorns Aura (Kobold Officer) to (Last created unit)
                • Unit - Add Command Aura (Kobold Officer) to (Last created unit)
                • Unit - Order (Last created unit) to Attack-Move To LeakPoint[376]
                • Custom script: call RemoveLocation(udg_LeakPoint[378])
                • Custom script: call RemoveLocation(udg_LeakPoint[376])
          • Else - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • Or - Any (Conditions) are true
              • Conditions
                • (Integer((Remaining time for KoboldTimer))) Equal to 30
          • Then - Actions
            • Set LeakPoint[376] = (Center of Kobold Attack Target <gen>)
            • Set LeakPoint[377] = (Center of Kobold Spawn 1 <gen>)
            • Unit - Create 1 Mikey The Kobold King for Player 12 (Brown) at LeakPoint[377] facing Default building facing degrees
            • Sound - Play KnightWarcry1 <gen> at 100.00% volume, located at LeakPoint[376] with Z offset 0.00
            • Unit - Order (Last created unit) to Attack-Move To LeakPoint[376]
            • Custom script: call RemoveLocation(udg_LeakPoint[377])
            • Custom script: call RemoveLocation(udg_LeakPoint[376])
          • Else - Actions


    Boss spell
    • [JASS]//TESH.scrollpos=0
    • //TESH.alwaysfold=0
    • function Trig_Entangling_cast_Conditions takes nothing returns boolean
      • return GetSpellAbilityId() == 'A0PZ'
    • endfunction
    • function Trig_Entangling_cast_Actions takes nothing returns nothing
      • local unit U
      • set U = CreateUnit( Player(11), 'o00S', GetUnitX(GetSpellTargetUnit()), GetUnitY(GetSpellTargetUnit()), GetRandomReal(0,360) )
      • call UnitApplyTimedLife( U, 'BTLF' ,60)
      • call IssueTargetOrder(U, "magicleash", GetSpellTargetUnit() )
      • set U = null
    • endfunction
    • //===========================================================================
    • function InitTrig_Entangling_cast takes nothing returns nothing
      • set gg_trg_Entangling_cast = CreateTrigger( )
      • call TriggerRegisterAnyUnitEventBJ( gg_trg_Entangling_cast, EVENT_PLAYER_UNIT_SPELL_EFFECT )
      • call TriggerAddCondition( gg_trg_Entangling_cast, Condition( function Trig_Entangling_cast_Conditions ) )
      • call TriggerAddAction( gg_trg_Entangling_cast, function Trig_Entangling_cast_Actions )
    • endfunction
    • [/JASS]


    Dungeon Complete
    • Kobold Instance Complete
      • Events
        • Unit - A unit Dies
      • Conditions
        • Mikey The Kobold King Equal to (Unit-type of (Triggering unit))
      • Actions
        • Set LeakGroup[60] = (Units in Kobold Weather <gen> owned by Player 12 (Brown))
        • Unit Group - Pick every unit in LeakGroup[60] and do (Actions)
          • Loop - Actions
            • Unit - Remove (Picked unit) from the game
        • Custom script: call DestroyGroup(udg_LeakGroup[60])
        • Set LeakGroup[60] = (Units in Kobold Weather <gen> owned by Player 11 (Dark Green))
        • Unit Group - Pick every unit in LeakGroup[60] and do (Actions)
          • Loop - Actions
            • Unit - Remove (Picked unit) from the game
        • Custom script: call DestroyGroup(udg_LeakGroup[60])
        • Countdown Timer - Destroy Kobold_TimerWindow
        • Trigger - Turn off Kobolds Unit <gen>
        • Set LeakPoint[384] = (Center of DropZone block 1 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 2 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 3 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 4 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 5 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 6 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 7 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 8 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 9 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 10 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 11 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 12 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 13 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 14 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 15 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 16 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 17 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 18 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 19 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Wait 0.01 seconds
        • Set LeakPoint[384] = (Center of DropZone block 20 <gen>)
        • Destructible - Create a Drop Fence at LeakPoint[384] facing 0.00 with scale 1.00 and variation 0
        • Custom script: call RemoveLocation(udg_LeakPoint[384])
        • Set LeakPoint[760] = (Center of DropZone player 10 <gen>)
        • Set LeakPoint[759] = (Center of DropZone player 9 <gen>)
        • Set LeakPoint[758] = (Center of DropZone player 8 <gen>)
        • Set LeakPoint[757] = (Center of DropZone player 7 <gen>)
        • Set LeakPoint[756] = (Center of DropZone player 6 <gen>)
        • Set LeakPoint[755] = (Center of DropZone player 5 <gen>)
        • Set LeakPoint[754] = (Center of DropZone player 4 <gen>)
        • Set LeakPoint[753] = (Center of DropZone player 3 <gen>)
        • Set LeakPoint[752] = (Center of DropZone player 2 <gen>)
        • Set LeakPoint[751] = (Center of DropZone player 1 <gen>)
        • Unit Group - Pick every unit in KoboldheroGroup and do (Actions)
          • Loop - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 1 (Red)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[751], facing LeakPoint[760]
                • Camera - Pan camera for Player 1 (Red) to LeakPoint[751] over 0.00 seconds
                • Selection - Select (Picked unit)
                • Unit - Order (Picked unit) to Stop
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 2 (Blue)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[752], facing LeakPoint[759]
                • Camera - Pan camera for Player 2 (Blue) to LeakPoint[752] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 3 (Teal)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[753], facing LeakPoint[758]
                • Camera - Pan camera for Player 3 (Teal) to LeakPoint[753] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 4 (Purple)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[754], facing LeakPoint[757]
                • Camera - Pan camera for Player 4 (Purple) to LeakPoint[754] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 5 (Yellow)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[755], facing LeakPoint[756]
                • Camera - Pan camera for Player 5 (Yellow) to LeakPoint[755] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 6 (Orange)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[756], facing LeakPoint[755]
                • Camera - Pan camera for Player 6 (Orange) to LeakPoint[756] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 7 (Green)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[757], facing LeakPoint[754]
                • Camera - Pan camera for Player 7 (Green) to LeakPoint[757] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 8 (Pink)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[758], facing LeakPoint[753]
                • Camera - Pan camera for Player 8 (Pink) to LeakPoint[758] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 9 (Gray)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[759], facing LeakPoint[752]
                • Camera - Pan camera for Player 9 (Gray) to LeakPoint[759] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 10 (Light Blue)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[760], facing LeakPoint[751]
                • Camera - Pan camera for Player 10 (Light Blue) to LeakPoint[760] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
        • Custom script: call RemoveLocation(udg_LeakPoint[751])
        • Custom script: call RemoveLocation(udg_LeakPoint[755])
        • Custom script: call RemoveLocation(udg_LeakPoint[753])
        • Custom script: call RemoveLocation(udg_LeakPoint[754])
        • Custom script: call RemoveLocation(udg_LeakPoint[758])
        • Custom script: call RemoveLocation(udg_LeakPoint[760])
        • Custom script: call RemoveLocation(udg_LeakPoint[756])
        • Custom script: call RemoveLocation(udg_LeakPoint[757])
        • Custom script: call RemoveLocation(udg_LeakPoint[759])
        • Custom script: call RemoveLocation(udg_LeakPoint[752])
        • Unit Group - Remove all units from KoboldheroGroup
        • Wait 15.00 seconds
        • Destructible - Pick every destructible in DropZone Kill 1 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 10 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 2 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 3 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 4 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 5 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 6 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 7 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 8 <gen> and do (Destructible - Remove (Picked destructible))
        • Destructible - Pick every destructible in DropZone Kill 9 <gen> and do (Destructible - Remove (Picked destructible))


    Dungeon FAIL
    • Kobold Instance fail
      • Events
        • Unit - A unit Dies
      • Conditions
        • Gary Moore Equal to (Unit-type of (Triggering unit))
      • Actions
        • Wait 2.00 seconds
        • Set LeakGroup[60] = (Units in Kobold Weather <gen> owned by Player 12 (Brown))
        • Unit Group - Pick every unit in LeakGroup[60] and do (Actions)
          • Loop - Actions
            • Unit - Remove (Picked unit) from the game
        • Custom script: call DestroyGroup(udg_LeakGroup[60])
        • Set LeakGroup[60] = (Units in Kobold Weather <gen> owned by Player 11 (Dark Green))
        • Unit Group - Pick every unit in LeakGroup[60] and do (Actions)
          • Loop - Actions
            • Unit - Remove (Picked unit) from the game
        • Custom script: call DestroyGroup(udg_LeakGroup[60])
        • Countdown Timer - Destroy Kobold_TimerWindow
        • Set LeakPoint[265] = (Center of Hero Spawn <gen>)
        • Unit Group - Pick every unit in KoboldheroGroup and do (Actions)
          • Loop - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 1 (Red)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 1 (Red) to LeakPoint[265] over 0.00 seconds
                • Selection - Select (Picked unit)
                • Unit - Order (Picked unit) to Stop
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 2 (Blue)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 2 (Blue) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 3 (Teal)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 3 (Teal) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 4 (Purple)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 4 (Purple) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 5 (Yellow)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 5 (Yellow) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 6 (Orange)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 6 (Orange) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 7 (Green)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 7 (Green) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 8 (Pink)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 8 (Pink) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 9 (Gray)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 9 (Gray) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • (Owner of (Picked unit)) Equal to Player 10 (Light Blue)
              • Then - Actions
                • Unit - Move (Picked unit) instantly to LeakPoint[265], facing Default building facing degrees
                • Camera - Pan camera for Player 10 (Light Blue) to LeakPoint[265] over 0.00 seconds
                • Unit - Order (Picked unit) to Stop
                • Selection - Select (Picked unit)
                • Unit Group - Remove (Picked unit) from KoboldheroGroup
              • Else - Actions
        • Custom script: call RemoveLocation(udg_LeakPoint[265])
        • Unit Group - Remove all units from KoboldheroGroup
        • Trigger - Turn off Kobolds Unit <gen>
     
  13. defskull

    defskull

    Joined:
    Mar 27, 2008
    Messages:
    7,979
    Resources:
    17
    Spells:
    17
    Resources:
    17
    How do you count the duration ?
    Don't tell me using your finger or any other outside-of-the-trigger-editor-function method like Timer using your Phone or such.

    I want to know first, how do you count the duration and determine it has 2~3 seconds delay (exact time: 30 seconds) (spawn time: 32 ~ 33 seconds) ?

    The best way to count the duration is to spawn a unit and put expiration timer = timer duration
    When that unit dies = spawn duration time

    If that unit dies and still nothing happen, only then the trigger really had problems within itself.
     
  14. Magtheridon96

    Magtheridon96

    Joined:
    Dec 12, 2008
    Messages:
    6,006
    Resources:
    26
    Maps:
    1
    Spells:
    8
    Tutorials:
    7
    JASS:
    10
    Resources:
    26
    One other tip:
    Use low indices in the arrays because the higher the indices you use, the more memory an array will take up. (Arrays in wc3 are dynamic)
     
  15. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    We count delay just by a phone really. Exactly 2.32 seconds. Increases over time but only because of spawns. Once a unit exits the dungeon delay goes away for some reason. As if spawning is effecting the delay.

    In those triggers are their any leaks or something that would cause delay or spikes in game?

    *Edit btw the more player it seems, the more delay if that helps any?
     
    Last edited: Jul 25, 2012
  16. Dr Super Good

    Dr Super Good

    Spell Reviewer

    Joined:
    Jan 18, 2005
    Messages:
    25,830
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    Delay (latency) is caused by your network and its traffic and physical restrictions. If the game is generating too many/large packets through a connection it can result in increased latency. This is because a connection has a finite bandwidth giving data a time cost. Additionally connections are bound by the laws of physics meaning that the signal requires time to travel between nodes.

    Latency on a packet is...
    delay taken to send + delay in transit

    A good ping for a LAN is somewhere under 1ms. A good ping from UK to US is anywhere from 100 to 300 ms. Delay due to bandwidth is neglible unless the connection is suffering from congestion in which case it can skyrocket.

    An example is trying to use a file sharing serevice with highly active download on an ADSL connection while trying to play a online game. Ping anywhere from 1-3 seconds.
     
  17. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Thanks super i now understand fully what delay is but what if this delay isnt caused by LAN and really the map? Hosting the map with different host proved it. Not unless its not delay and really lag?
     
  18. Dr Super Good

    Dr Super Good

    Spell Reviewer

    Joined:
    Jan 18, 2005
    Messages:
    25,830
    Resources:
    3
    Maps:
    1
    Spells:
    2
    Resources:
    3
    In that case you are generating too much net traffic. Things like TriggerSleepAction, the native that damages a point, keyboard buttons (arrow keys) and synchronization natives all create net traffic.

    Spam a hundred damage point calls at once and the game will become unresponsive for many seconds.
     
  19. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    can u look over the triggers i posted on page 1 to see if it has anything wrong?
     
  20. deathdoorway

    deathdoorway

    Joined:
    Apr 13, 2005
    Messages:
    621
    Resources:
    1
    Maps:
    1
    Resources:
    1
    Can anyone look at the triggers i posted and see if thats causing?