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

[Solved] Map Desync at Start of Game #Reforged

Status
Not open for further replies.
Level 6
Joined
Mar 27, 2019
Messages
51
Hi there,

I'm currently working on my Stronghold Remastered Project for Reforged.
I implemented a Menu that allows to choose multiple Maps.
Later I hosted the Map, only to find out that multiple players desync right at the start. Since I added that System my Map has an desync issue. Usually 1-3 players desync or even more. I dont know what the cause of the desync is. Can somebody help me out here? Here are the Triggers.

  • Map Initialize Begin
    • Events
      • Time - Elapsed game time is 0.50 seconds
    • Conditions
    • Actions
      • -------- Support Start Tolerance --------
      • Set VariableSet Tolerance_Limit = 0
      • -------- Support Start Tolerance --------
      • -------- Set Headquarter Lifepoints --------
      • Set VariableSet Headquarter_Life[1] = 400
      • Set VariableSet Headquarter_Life[2] = 800
      • Set VariableSet Headquarter_Life[3] = 1600
      • Set VariableSet Headquarter_Life[4] = 3200
      • Set VariableSet Headquarter_Life[5] = 6400
      • Set VariableSet Headquarter_Life[6] = 12800
      • Set VariableSet Headquarter_Life[7] = 25600
      • Set VariableSet Headquarter_Life[8] = 51200
      • Set VariableSet Headquarter_Life[9] = 51200
      • Set VariableSet Headquarter_Life[10] = 100000
      • Set VariableSet Headquarter_Life[11] = 200000
      • Set VariableSet Headquarter_Life[12] = 300000
      • Set VariableSet Headquarter_Life[13] = 400000
      • Set VariableSet Headquarter_Life[14] = 500000
      • Set VariableSet Headquarter_Life[15] = 500000
      • -------- Set Headquarter Lifepoints --------
      • -------- Set Host --------
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • Set VariableSet Tolerance[(Integer A)] = 0
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Name of (Player((Integer A)))) Equal to Daemon#22905
            • Then - Actions
              • Player - Set name of (Player((Integer A))) to Bloodheaven
              • Custom script: exitwhen true
            • Else - Actions
      • -------- Set Host --------
      • -------- Randomize Trees --------
      • Destructible - Pick every destructible in (Playable map area) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • (Destructible-type of (Picked destructible)) Equal to Sommerbaumwand (Edited)
              • ((Picked destructible) is alive) Equal to Wahr
            • Then - Actions
              • Set VariableSet Temp_Point = (Position of (Picked destructible))
              • Destructible - Hide (Picked destructible)
              • Destructible - Create a Sommerbaumwand at Temp_Point facing (Random angle) with scale (Random real number between 1.00 and 1.40) and variation (Random integer number between 0 and 9)
              • Destructible - Remove (Picked destructible)
              • Custom script: call RemoveLocation(udg_Temp_Point)
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Destructible-type of (Picked destructible)) Equal to Sommerbaumwand (Edited)
                  • ((Picked destructible) is alive) Equal to Falsch
                • Then - Actions
                  • Set VariableSet Temp_Point = (Position of (Picked destructible))
                  • Destructible - Hide (Picked destructible)
                  • Destructible - Create a dead Sommerbaumwand at Temp_Point facing (Random angle) with scale (Random real number between 1.00 and 1.40) and variation (Random integer number between 0 and 9)
                  • Destructible - Remove (Picked destructible)
                  • Custom script: call RemoveLocation(udg_Temp_Point)
                • Else - Actions
      • -------- Randomize Trees --------
      • -------- Set Tower Types --------
      • Set VariableSet Tower_Type[1] = [|cffFFCC00Level 1|r] |cffD6D6D6Arrow Tower
      • Set VariableSet Tower_Type[2] = [|cffFFCC00Level 2|r] |cff9C9C9CArrow Tower
      • Set VariableSet Tower_Type[3] = [|cffFFCC00Level 3|r] |cff7B7B7BArrow Tower
      • Set VariableSet Tower_Type[4] = [|cffFFCC00Level 1|r] |cffFF943AFire Arrow Tower
      • Set VariableSet Tower_Type[5] = [|cffFFCC00Level 2|r] |cffFF733AFire Arrow Tower
      • Set VariableSet Tower_Type[6] = [|cffFFCC00Level 3|r] |cffFF5A31Fire Arrow Tower
      • Set VariableSet Tower_Type[7] = [|cffFFCC00Level 1|r] |cffFFFFB5Magic Tower
      • Set VariableSet Tower_Type[8] = [|cffFFCC00Level 2|r] |cffFFFF31Magic Tower
      • Set VariableSet Tower_Type[9] = [|cffFFCC00Level 3|r] |cffDECE08Magic Tower
      • Set VariableSet Tower_Type[10] = [|cffFFCC00Level 1|r] |cff08DEFFWater Tower
      • Set VariableSet Tower_Type[11] = [|cffFFCC00Level 2|r] |cff08ADF7Water Tower
      • Set VariableSet Tower_Type[12] = [|cffFFCC00Level 3|r] |cff087BC5Water Tower
      • Set VariableSet Tower_Type[13] = [|cffFFCC00Level 1|r] |cffBD8408Bombard Tower
      • Set VariableSet Tower_Type[14] = [|cffFFCC00Level 2|r] |cffA57308Bombard Tower
      • Set VariableSet Tower_Type[15] = [|cffFFCC00Level 3|r] |cff7B5208Bombard Tower
      • Set VariableSet Tower_Type[16] = [|cffFFCC00Level 1|r] |cff3AC55ABeam Tower
      • Set VariableSet Tower_Type[17] = [|cffFFCC00Level 2|r] |cff29943ABeam Tower
      • Set VariableSet Tower_Type[18] = [|cffFFCC00Level 3|r] |cff086B21Beam Tower
      • Set VariableSet Tower_Type[19] = [|cffFFCC00Level 1|r] |cff5A73CEWizard Tower
      • Set VariableSet Tower_Type[20] = [|cffFFCC00Level 2|r] |cff294AB5Wizard Tower
      • Set VariableSet Tower_Type[21] = [|cffFFCC00Level 3|r] |cff213A94Wizard Tower
      • Set VariableSet Tower_Type[22] = [|cffFFCC00Level 1|r] |cffFFDEBDTauren Tower
      • Set VariableSet Tower_Type[23] = [|cffFFCC00Level 2|r] |cffFFC58CTauren Tower
      • Set VariableSet Tower_Type[24] = [|cffFFCC00Level 3|r] |cffFFAD4ATauren Tower
      • Set VariableSet Tower_Type[25] = [|cffFFCC00Level 1|r] |cff42C552Rapid Cannon Tower
      • Set VariableSet Tower_Type[26] = [|cffFFCC00Level 2|r] |cff299442Rapid Cannon Tower
      • Set VariableSet Tower_Type[27] = [|cffFFCC00Level 3|r] |cff086B21Rapid Cannon Tower
      • Set VariableSet Tower_Type[28] = [|cffFFCC00Level 1|r] |cffFF4263Archer Tower
      • Set VariableSet Tower_Type[29] = [|cffFFCC00Level 2|r] |cffCE0831Archer Tower
      • Set VariableSet Tower_Type[30] = [|cffFFCC00Level 3|r] |cff9C0821Archer Tower
      • Set VariableSet Tower_Type[31] = [|cffFFCC00Level X|r] |cffE55AAFUltimate Tower
      • Set VariableSet Tower_Type[32] = [|cffFFCC00Level X|r] |cff422184Bloodheaven's Tower
      • Set VariableSet Tower_Type[33] = [|cffFFCC00Level 1|r] |cffD6D6D6Arrow Tower (Mode)
      • Set VariableSet Tower_Type[34] = [|cffFFCC00Level 1|r] |cffD6D6D6Arrow Tower (Edited)
      • Set VariableSet Tower_Type[35] = [|cffFFCC00Level 1|r] |cff08DEFFWater Tower (Special)
      • Set VariableSet Tower_Type[36] = [|cffFFCC00Level 1|r] |cff5A73CEWizard Tower (Special)
      • Set VariableSet Tower_Type[37] = [|cffFFCC00Level 1|r] |cffFF4263Archer Tower (Special)
      • -------- Set Tower Types --------
      • -------- Set Unit Types --------
      • Set VariableSet Unit_Type[0] = |cffFFFFDELevel 0 Unit
      • Set VariableSet Unit_Type[1] = |cffFFFFDELevel 1 Unit
      • Set VariableSet Unit_Type[2] = |cffFFFFB5Level 2 Unit
      • Set VariableSet Unit_Type[3] = |cffFFFF8CLevel 3 Unit
      • Set VariableSet Unit_Type[4] = |cffFFE608Level 4 Unit
      • Set VariableSet Unit_Type[5] = |cffE6C508Level 5 Unit
      • Set VariableSet Unit_Type[6] = |cffE6A519Level 6 Unit
      • Set VariableSet Unit_Type[7] = |cffD68C10Level 7 Unit
      • Set VariableSet Unit_Type[8] = |cffC57308Level 8 Unit
      • Set VariableSet Unit_Type[9] = |cffB56308Level 9 Unit Y
      • Set VariableSet Unit_Type[10] = |cffA55208Level 10 Unit
      • Set VariableSet Unit_Type[11] = |cff944208Level 11 Unit
      • Set VariableSet Unit_Type[12] = |cff943108Level 12 Unit
      • Set VariableSet Unit_Type[13] = |cff841908Level 13 Unit
      • Set VariableSet Unit_Type[14] = |cff841008Level 14 Unit
      • Set VariableSet Unit_Type[15] = |cff6B0808Level 15 Unit
      • Set VariableSet Unit_Type[16] = |cff520808Bloodheaven
      • Set VariableSet Unit_Type[64] = |cffB56308Level 9 Unit Z
      • -------- Set Unit Types --------
      • -------- Set Boss Types --------
      • Set VariableSet Boss_Type[1] = |cffFFFFDELevel 1 Boss
      • Set VariableSet Boss_Type[2] = |cffFFFFDELevel 2 Boss
      • Set VariableSet Boss_Type[3] = |cffFFFFDELevel 3 Boss
      • Set VariableSet Boss_Type[4] = |cffFFFFDELevel 4 Boss
      • Set VariableSet Boss_Type[5] = |cffFFFFDELevel 5 Boss
      • Set VariableSet Boss_Type[6] = |cffFFFFDELevel 6 Boss
      • Set VariableSet Boss_Type[7] = |cffFFFFDELevel 7 Boss
      • Set VariableSet Boss_Type[8] = |cffFFFFDELevel 8 Boss
      • Set VariableSet Boss_Type[9] = |cffFFFFDELevel 9 Boss
      • Set VariableSet Boss_Type[10] = |cffFFFFDELevel 10 Boss
      • Set VariableSet Boss_Type[11] = |cffFFFFDELevel 11 Boss
      • Set VariableSet Boss_Type[12] = |cffFFFFDELevel 12 Boss
      • Set VariableSet Boss_Type[13] = |cffFFFFDELevel 13 Boss
      • Set VariableSet Boss_Type[14] = |cffFFFFDELevel 14 Boss
      • Set VariableSet Boss_Type[15] = |cffFFFFDELevel 15 Boss
      • -------- Set Boss Types --------
      • -------- Fix Freeze --------
      • Set VariableSet Temp_Point = (Center of (Playable map area))
      • Unit - Create 1.|cffFF0202Offensive Builder for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|cffFFCC00Support Builder for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|r[|cffFFCC00Level 15|r] |cff7777AAHead Quarters for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.[|cffFFCC00Level 1|r] |cffD6D6D6Arrow Tower for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.[|cffFFCC00Level 1|r] |cffDE5221Damage-Aura for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.[|cffFFCC00Level 1|r] |cff7DBEF1Frost-Aura for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.[|cffFFCC00Level 1|r] |cff7777AALethality-Aura for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.[|cffFFCC00Level 1|r] |cffFFFFC5Speed-Aura for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|r[|cffFFCC00Level 4|r] |cff7777AAHead Quarters for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|r[|cffFFCC00Level 7|r] |cff7777AAHead Quarters for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|r[|cffFFCC00Level 10|r] |cff7777AAHead Quarters for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|r[|cffFFCC00Level 11|r] |cff7777AAHead Quarters for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|cff7DBEF1Advanced Unit Builder for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|cfff05e19Doom Portal|r for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|cff520808Increase HP for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.|cffFFFFDELevel 0 Unit for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • -------- Fix Freeze --------
      • For each (Integer A) from 1 to 37, do (Actions)
        • Loop - Actions
          • Unit - Create 1.Tower_Type[(Integer A)] for Neutral Passive at Temp_Point facing Default building facing degrees
          • Unit - Remove (Last created unit) from the game
      • For each (Integer A) from 1 to 16, do (Actions)
        • Loop - Actions
          • Unit - Create 1.Unit_Type[(Integer A)] for Neutral Passive at Temp_Point facing Default building facing degrees
          • Unit - Remove (Last created unit) from the game
      • For each (Integer A) from 1 to 15, do (Actions)
        • Loop - Actions
          • Unit - Create 1.Boss_Type[(Integer A)] for Neutral Passive at Temp_Point facing Default building facing degrees
          • Unit - Remove (Last created unit) from the game
      • Unit - Create 1.Unit_Type[64] for Neutral Passive at Temp_Point facing Default building facing degrees
      • Unit - Remove (Last created unit) from the game
      • Custom script: call RemoveLocation(udg_Temp_Point)
      • -------- Fix Freeze --------
      • Custom script: call DestroyTrigger(GetTriggeringTrigger())
  • Map Initialize Setup
    • Events
      • Time - Elapsed game time is 1.00 seconds
    • Conditions
    • Actions
      • Trigger - Turn on Map Camera <gen>
      • Set VariableSet Player_String[1] = |cffFF0202
      • Set VariableSet Player_String[2] = |cff006DFF
      • Set VariableSet Player_String[3] = |cff1BE6B8
      • Set VariableSet Player_String[4] = |cff900099
      • Set VariableSet Player_String[5] = |cffFFCC00
      • Set VariableSet Player_String[6] = |cffFE890D
      • Set VariableSet Player_String[7] = |cff1FBF00
      • Set VariableSet Player_String[8] = |cffE55AAF
      • Set VariableSet Player_String[9] = |cff949596
      • Set VariableSet Player_String[10] = |cff7DBEF1
      • Set VariableSet Player_String[11] = |cff1C884F
      • Set VariableSet Player_String[12] = |cffA0522D
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
          • Set VariableSet Player_Colors[(Integer A)] = (Player_String[(Integer A)] + ((Name of (Player((Integer A)))) + |r))
          • Set VariableSet Camera_Field[(Integer A)] = 1850
          • Camera - .Apply. Map Selection <gen> for (Player((Integer A))) over 0.00 seconds
          • Player - Make [|cffFFCC00Level 1|r] |cffD6D6D6Arrow Tower (Mode) Unavailable for training/construction by (Player((Integer A)))
          • Player - Disable Verwurzeln (Urtume) for (Player((Integer A)))
          • Player - Disable Show Range Disabled for (Player((Integer A)))
          • Trigger - Add to Map Click Settings <gen> the event (Player - (Player((Integer A))) issues Mouse Down event)
          • Trigger - Add to Map Leave Start <gen> the event (Player - (Player((Integer A))) leaves the game)
          • Visibility - Create an initially Enabled visibility modifier for (Player((Integer A))) emitting Visibility across Options <gen>
      • -------- - --------
      • Set VariableSet Map_Selector[1] = Map Selection 0319 <gen>
      • Unit - Set Name of Map_Selector[1] to |cffFE890DStronghold Classic|r
      • Set VariableSet Map_Text[1] = (Name of Map_Selector[1])
      • Set VariableSet Map_Text[5] = Defend as 4 players in a Team.
      • Set VariableSet Map_Selector[2] = Map Selection 0318 <gen>
      • Unit - Set Name of Map_Selector[2] to |cff80ff80Stronghold Nation|r
      • Set VariableSet Map_Text[2] = (Name of Map_Selector[2])
      • Set VariableSet Map_Text[6] = Battle between 2 Teams.
      • Set VariableSet Map_Selector[3] = Map Selection 0317 <gen>
      • Unit - Set Name of Map_Selector[3] to |cffff0000Stronghold Wars|r
      • Set VariableSet Map_Text[3] = (Name of Map_Selector[3])
      • Set VariableSet Map_Text[7] = A brutal battle among everyone.
      • Set VariableSet Map_Selector[4] = Map Selection 0320 <gen>
      • Unit - Set Name of Map_Selector[4] to |cffffff00Stronghold Duo|r
      • Set VariableSet Map_Text[4] = (Name of Map_Selector[4])
      • Set VariableSet Map_Text[8] = Kill every enemy with your partner.
      • Set VariableSet Map_Selector[5] = Map Login 0321 <gen>
      • Unit - Change ownership of Map_Selector[5] to Host and Change color
      • Unit - Set Name of Map_Selector[5] to |cffff0000Choose Map|r
      • Selection - Select Map_Selector[5] for Host
      • -------- - --------
  • Map Initialize Delay
    • Events
      • Time - Elapsed game time is 2.00 seconds
    • Conditions
    • Actions
      • Trigger - Turn on Map Click Settings <gen>
      • Countdown Timer - Start Countdown as a Repeating timer that will expire in 8.00 seconds
      • Countdown Timer - Create a timer window for Countdown with title Time Left
      • Countdown Timer - Show (Last created timer window)
      • Set VariableSet Countdown = (Last started timer)
      • Set VariableSet Temp_Group = (Units in Stronghold Remastered <gen>)
      • Unit Group - Pick every unit in Temp_Group and do (Actions)
        • Loop - Actions
          • Unit - Hide (Picked unit)
      • Custom script: call DestroyGroup(udg_Temp_Group)
      • Custom script: call BlzChangeMinimapTerrainTex("Custom\\Images\\Stronghold_Black.blp")
      • Game - Set the time of day to 0.00
      • For each (Integer A) from 1 to 4, do (Actions)
        • Loop - Actions
          • Animation - Change Map_Selector[(Integer A)]'s vertex coloring to (0.00%, 0.00%, 0.00%) with 0.00% transparency
          • Animation - Play Map_Selector[(Integer A)]'s death alternate animation
      • -------- - --------
      • -------- REMOVE THIS --------
      • -------- - --------
      • For each (Integer A) from 2 to 4, do (Actions)
        • Loop - Actions
          • Unit - Set Name of Map_Selector[(Integer A)] to |cffff0000Currently Unavailable|r
          • Set VariableSet Map_Text[(Integer A)] = (Name of Map_Selector[(Integer A)])
          • Set VariableSet Map_Text[((Integer A) + 4)] = This Map will be available in the 4.0 Version.
          • Set VariableSet Temp_Point = (Position of Map_Selector[(Integer A)])
          • Unit - Create 1.Black Piece (Edited) for Neutral Passive at Temp_Point facing Default building facing degrees
          • Animation - Change (Last created unit)'s size to (30.00%, 30.00%, 30.00%) of its original size
          • Animation - Change (Last created unit)'s vertex coloring to (0.00%, 0.00%, 0.00%) with 5.00% transparency
          • Custom script: call RemoveLocation(udg_Temp_Point)
      • -------- - --------
      • -------- REMOVE THIS --------
      • -------- - --------
      • Game - Display to (All players) for 120.00 seconds the text: (Player_Colors[(Player number of Host)] + chooses the Settings.)
      • Cinematic - Clear the screen of text messages for (Player group(Host)).
      • Game - Display to (Player group(Host)) for 120.00 seconds the text: |cffff0000Choose a ...
      • Game - Display to (Player group(Host)) for 120.00 seconds the text: |cffff0000Press 'Q'...
      • Image - Create an image using Custom\Images\Game_Remastered.BLP of size 512.00 at (Center of Map Selection 01 <gen>) with Z offset 0.00 using image type Indicator
      • Image - Change (Last created image): Enable render always state
      • Image - Show (Last created image)
      • Image - Create an image using Custom\Images\Game_Nation.BLP of size 512.00 at (Center of Map Selection 02 <gen>) with Z offset 0.00 using image type Indicator
      • Image - Change (Last created image): Enable render always state
      • Image - Show (Last created image)
      • Image - Create an image using Custom\Images\Game_Wars.BLP of size 512.00 at (Center of Map Selection 03 <gen>) with Z offset 0.00 using image type Indicator
      • Image - Change (Last created image): Enable render always state
      • Image - Show (Last created image)
      • Image - Create an image using Custom\Images\Game_Duo.BLP of size 512.00 at (Center of Map Selection 04 <gen>) with Z offset 0.00 using image type Indicator
      • Image - Change (Last created image): Enable render always state
      • Image - Show (Last created image)
      • Image - Create an image using Custom\Images\Team_Default.BLP of size 512.00 at (Center of Team Selection 01 <gen>) with Z offset 0.00 using image type Indicator
      • Image - Change (Last created image): Enable render always state
      • Image - Show (Last created image)
      • Image - Create an image using Custom\Images\Team_Pick.BLP of size 512.00 at (Center of Team Selection 02 <gen>) with Z offset 0.00 using image type Indicator
      • Image - Change (Last created image): Enable render always state
      • Image - Show (Last created image)
      • For each (Integer A) from 1 to 12, do (Actions)
        • Loop - Actions
  • Map Click Settings
    • Events
    • Conditions
    • Actions
      • Set VariableSet Temp_Point = (Point((Mouse Position X for Triggered Mouse Event), (Mouse Position Y for Triggered Mouse Event)))
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Triggering player) Equal to Host
        • Then - Actions
          • For each (Integer A) from 1 to 4, do (Actions)
            • Loop - Actions
              • Set VariableSet Temp_Point_2 = (Position of Map_Selector[(Integer A)])
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Distance between Temp_Point and Temp_Point_2) Less than 144.00
                • Then - Actions
                  • For each (Integer B) from 1 to 4, do (Actions)
                    • Loop - Actions
                      • Animation - Change Map_Selector[(Integer B)]'s vertex coloring to (0.00%, 0.00%, 0.00%) with 0.00% transparency
                  • Unit - Remove Choose Map from Map_Selector[5]
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (Integer A) Equal to 1
                    • Then - Actions
                      • Unit - Add Choose Map to Map_Selector[5]
                    • Else - Actions
                  • Unit - Set level of Choose Map for Map_Selector[5] to (Integer A)
                  • Unit - Change ownership of Map_Selector[5] to Host and Change color
                  • Unit - Set Name of Map_Selector[5] to (Name of Map_Selector[(Integer A)])
                  • Selection - Select Map_Selector[5] for Host
                  • Animation - Play Map_Selector[(Integer A)]'s death alternate animation
                  • Animation - Change Map_Selector[(Integer A)]'s vertex coloring to (0.00%, 100.00%, 0.00%) with 0.00% transparency
                  • Cinematic - Clear the screen of text messages for (All players).
                  • Game - Display to (All players) for 120.00 seconds the text: Map_Text[(Integer A)]
                  • Game - Display to (All players) for 120.00 seconds the text: -------------------...
                  • Game - Display to (All players) for 120.00 seconds the text: Map_Text[((Integer A) + 4)]
                  • Game - Display to (All players) for 120.00 seconds the text:
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (Integer A) Equal to 1
                    • Then - Actions
                      • Game - Display to (Player group(Host)) for 120.00 seconds the text: |cff469696Press 'Q'...
                    • Else - Actions
                      • Game - Display to (Player group(Host)) for 120.00 seconds the text:
                  • Custom script: exitwhen true
                • Else - Actions
              • Custom script: call RemoveLocation(udg_Temp_Point_2)
          • For each (Integer A) from 6 to 7, do (Actions)
            • Loop - Actions
              • Set VariableSet Temp_Point_2 = (Position of Map_Selector[(Integer A)])
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • (Distance between Temp_Point and Temp_Point_2) Less than 144.00
                • Then - Actions
                  • For each (Integer B) from 6 to 7, do (Actions)
                    • Loop - Actions
                      • Animation - Change Map_Selector[(Integer B)]'s vertex coloring to (0.00%, 0.00%, 0.00%) with 0.00% transparency
                  • Unit - Remove Choose Team from Map_Selector[8]
                  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                    • If - Conditions
                      • (Integer A) Equal to 6
                    • Then - Actions
                      • Unit - Add Choose Team to Map_Selector[8]
                    • Else - Actions
                  • Unit - Set level of Choose Team for Map_Selector[8] to ((Integer A) - 5)
                  • Unit - Change ownership of Map_Selector[8] to Host and Change color
                  • Unit - Set Name of Map_Selector[8] to (Name of Map_Selector[(Integer A)])
                  • Selection - Select Map_Selector[8] for Host
                  • Animation - Play Map_Selector[(Integer A)]'s death alternate animation
                  • Animation - Change Map_Selector[(Integer A)]'s vertex coloring to (0.00%, 100.00%, 0.00%) with 0.00% transparency
                  • Cinematic - Clear the screen of text messages for (All players).
                  • Game - Display to (All players) for 120.00 seconds the text: (Name of Map_Selector[(Integer A)])
                  • Game - Display to (All players) for 120.00 seconds the text: -------------------...
                  • Game - Display to (All players) for 120.00 seconds the text: Map_Text[((Integer A) + 3)]
                  • Custom script: exitwhen true
                • Else - Actions
              • Custom script: call RemoveLocation(udg_Temp_Point_2)
        • Else - Actions
      • Custom script: call RemoveLocation(udg_Temp_Point)
  • Map Game Start
    • Events
    • Conditions
    • Actions
      • Trigger - Turn off Map Leave Start <gen>
      • Trigger - Turn off Map Camera <gen>
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Map_Type Equal to 1
        • Then - Actions
          • Trigger - Run Initialize Stronghold Remastered <gen> (checking conditions)
          • For each (Integer A) from 1 to 28, do (Actions)
            • Loop - Actions
              • Set VariableSet Temp_Group = (Units owned by (Player((Integer A))).)
              • Unit Group - Pick every unit in (Units owned by (Player((Integer A))).) and do (Actions)
                • Loop - Actions
                  • Unit - Unhide (Picked unit)
              • Custom script: call DestroyGroup(udg_Temp_Group)
          • Wait 1.00 seconds
          • Trigger - Turn off Map Camera <gen>
          • Set VariableSet Temp_Group = (Units in Options <gen>)
          • Unit Group - Pick every unit in Temp_Group and do (Actions)
            • Loop - Actions
              • Unit - Remove (Picked unit) from the game
          • Custom script: call DestroyGroup(udg_Temp_Group)
          • For each (Integer A) from 1 to 4, do (Actions)
            • Loop - Actions
              • Hashtable - Save Team_South as 511 of (Key (Player((Integer A))).) in Hashtable.
          • For each (Integer A) from 5 to 8, do (Actions)
            • Loop - Actions
              • Hashtable - Save Team_West as 511 of (Key (Player((Integer A))).) in Hashtable.
          • For each (Integer A) from 9 to 12, do (Actions)
            • Loop - Actions
              • Hashtable - Save Team_East as 511 of (Key (Player((Integer A))).) in Hashtable.
          • For each (Integer A) from 1 to 12, do (Actions)
            • Loop - Actions
              • Set VariableSet Camera_Field[(Integer A)] = 1850
              • Camera - Set the camera bounds for (Player((Integer A))) to Stronghold Remastered <gen>
          • Custom script: call BlzChangeMinimapTerrainTex("Custom\\Images\\Stronghold_Remastered.blp")
        • Else - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • Map_Type Equal to 2
            • Then - Actions
              • For each (Integer A) from 1 to 12, do (Actions)
                • Loop - Actions
                  • Camera - Set the camera bounds for (Player((Integer A))) to Stronghold Nation <gen>
              • Custom script: call BlzChangeMinimapTerrainTex("Custom\\Images\\Stronghold_Nation.blp")
            • Else - Actions
              • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                • If - Conditions
                  • Map_Type Equal to 3
                • Then - Actions
                  • For each (Integer A) from 1 to 12, do (Actions)
                    • Loop - Actions
                      • Camera - Set the camera bounds for (Player((Integer A))) to Stronghold Wars <gen>
                  • Custom script: call BlzChangeMinimapTerrainTex("Custom\\Images\\Stronghold_Wars.blp")
                • Else - Actions
                  • For each (Integer A) from 1 to 12, do (Actions)
                    • Loop - Actions
                      • Camera - Set the camera bounds for (Player((Integer A))) to Stronghold Duo <gen>
                  • Custom script: call BlzChangeMinimapTerrainTex("Custom\\Images\\Stronghold_Duo.blp")
      • Custom script: call DestroyTrigger(GetTriggeringTrigger())

So alot of Text.

Any help is highly appreciated!
 
Level 6
Joined
Mar 27, 2019
Messages
51
Probably the images. I remember them being funky and crash-prone.

I'm already using Images before I added Menu's at the Start and there were no desyncs.
Could this function cause a desync right at map initizializing?
  • Visibility - Show Terrain: True
Or this
  • Set VariableSet Temp_Point = (Point((Mouse Position X for Triggered Mouse Event), (Mouse Position Y for Triggered Mouse Event)))
This desync drives me crazy, there is no actual way to test it without officially hosting it, or having alot of friends to test.
 
Level 20
Joined
May 16, 2012
Messages
635
I'm already using Images before I added Menu's at the Start and there were no desyncs.
Could this function cause a desync right at map initizializing?
  • Visibility - Show Terrain: True
Or this
  • Set VariableSet Temp_Point = (Point((Mouse Position X for Triggered Mouse Event), (Mouse Position Y for Triggered Mouse Event)))
This desync drives me crazy, there is no actual way to test it without officially hosting it, or having alot of friends to test.

You can open multiple instances of warcraft, create a lan game in one of them and join with the others and test it as if there were multiple players
 
Level 38
Joined
Feb 27, 2007
Messages
4,951
Why on earth did you want a periodic trigger firing as fast as possible? I’d say it probably desynced because whatever it did hit the op limit at different numbers of executions/different times for each computer the game was being run on, thus causing some difference in the game state between them. That’s just a guess though.
 
Level 6
Joined
Mar 27, 2019
Messages
51
Why on earth did you want a periodic trigger firing as fast as possible? I’d say it probably desynced because whatever it did hit the op limit at different numbers of executions/different times for each computer the game was being run on, thus causing some difference in the game state between them. That’s just a guess though.

I just wanted to lock the Camera at the Settings Menu I made

  • Map Camera
    • Events
      • Time - Every 0.00 seconds of game time
    • 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
              • Camera_Field[(Integer A)] Equal to 1850
            • Then - Actions
              • Camera - .Apply. Map Selection <gen> for (Player((Integer A))) over 0.00 seconds
            • Else - Actions
              • Camera - .Apply. Team Selection <gen> for (Player((Integer A))) over 0.00 seconds

Didn't know any better solution and I also did not know that 0.00 periodics can desync, my bad^^.
 
Level 9
Joined
Jul 30, 2018
Messages
445
How would that even work? To make something every 0 seconds? That’s like making something an infinite times per second. For camera settings, every .05 seconds usually quite enough to make it smooth. Even every 0.1 seconds is fine, if you update the camera over 0.1 second instead of applying the effect instantly (over 0.00 seconds).

Also, you can lock the camera with just one action, without periodic actions, by locking the camera to a unit. There might even be action for locking the camera to a location iirc, but can’t confirm now, since I am not at my PC. But even if there is not, you could just make an invisible dummy unit and then lock the camera to that.
 
Last edited:
Level 18
Joined
Jan 1, 2018
Messages
728
How would that even work? To make something every 0 seconds? That’s like making something an infinite times per second.
There should be a lower limit for the interval of a periodic timer, I think it was 0.0001 (10000x per second).
 
Level 9
Joined
Jul 30, 2018
Messages
445
There should be a lower limit for the interval of a periodic timer, I think it was 0.0001 (10000x per second).

Yeah, I guess there must be some sort of limit hard-coded. Otherwise it would indeed just crash any client, since it would be like an infinite loop. Nevertheless, not very practical to use that every 0.0001 second period for anything.
 
Level 18
Joined
Jan 1, 2018
Messages
728
Yeah, I guess there must be some sort of limit hard-coded. Otherwise it would indeed just crash any client, since it would be like an infinite loop. Nevertheless, not very practical to use that every 0.0001 second period for anything.
Only time I've seen a 0.0001 second periodic timer used was to restart a function if it had stopped due to reaching the op limit.

0 timeout timers are a thing that have a use: running something in a new thread or directly after an event should fire.
True, but I thought we were talking about periodic 0 timeout timers.
 

Wrda

Spell Reviewer
Level 25
Joined
Nov 18, 2012
Messages
1,864
Who ever uses periodic 0 timeout timers must be insanely blindfolded and should get some pushpins up in his ass. One doesn't need to know if it desyncs or crash or whatever happens, one does need to know that it doesn't make any sense to run something infinit times per endlessly seconds, that is just asking for trouble.
When I tested that a long time ago out of curiosity, it froze, now in reforged it desyncs? That's...interesting.
 

Dr Super Good

Spell Reviewer
Level 63
Joined
Jan 18, 2005
Messages
27,180
When I tested that a long time ago out of curiosity, it froze, now in reforged it desyncs? That's...interesting.
There appears to be some limit to it added recently. For example in 1.31 (current live) it also runs a finite number of times per second, like 100 or so.

I agree it is totally nonsense. WC3 works in ticks anyway and if the timer interval is too low it should just fire multiple times in the same tick.
 
Status
Not open for further replies.
Top