- Joined
- Jul 14, 2011
- Messages
- 3,213
Hi!
I was testing a map with a friend, and found that an event was doing a desync. I changed three triggers, and the desync was gone, but my friend had to leave, and I don't know which one was messing up the game.
Check for the 'GetLocalPlayer' I disabled all of them in order to remove the desync.
Also (a bit offtopic) I was testing with version 1.26a and the other players (with same version) were kicked, but works with 1.24e :S. What could be the cause?
I was testing a map with a friend, and found that an event was doing a desync. I changed three triggers, and the desync was gone, but my friend had to leave, and I don't know which one was messing up the game.
Check for the 'GetLocalPlayer' I disabled all of them in order to remove the desync.
-
Combat Music ON
-
Events
- Unit - A unit enters Musiquita <gen>
- Conditions
-
Actions
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetTriggerUnit()) then
- Sound - Play Doom
- Custom script: endif
-
Events
-
Combat Music OFF
-
Events
- Unit - A unit leaves Musiquita <gen>
- Conditions
-
Actions
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetTriggerUnit()) then
- Sound - Stop the currently playing music theme
- Custom script: endif
-
Events
-
Combat System 2
-
Events
- Time - SpawnTimer expires
- Conditions
-
Actions
- -------- Global --------
- Set UONH = (Units owned by Neutral Hostile)
- -------- WOOD --------
- Set CCP[0] = (Center of WoodCombat <gen>)
- Set Wood[1] = (Units in WoodCombat <gen> matching ((((Matching unit) is alive) Equal to True) and (((Matching unit) is in UONH) Equal to True)))
- Set Wood[2] = (Units in WoodCombat <gen> matching (((Matching unit) is A Hero) Equal to True))
- Set Wood[3] = (Units in WoodEscape <gen> matching (((Matching unit) is A Hero) Equal to True))
- Set Wood[4] = (Units in WoodCombat <gen> owned by Neutral Hostile)
- Floating Text - Create floating text that reads (Creeps Left: + (|cfffff700 + ((String((Number of units in Wood[1]))) + |r))) at CCP[0] with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
- Floating Text - Change (Last created floating text): Disable permanence
- Floating Text - Change the lifespan of (Last created floating text) to 1.20 seconds
- Custom script: call RemoveLocation(udg_CCP[0])
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Random integer number between 1 and 100) Less than or equal to (Random integer number between 5 and 15)
- (Number of units in Wood[2]) Equal to 0
-
Then - Actions
-
Unit Group - Pick every unit in Wood[0] and do (Actions)
-
Loop - Actions
- Set TempUnit = (Picked unit)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (TempUnit has buff Safety ) Equal to False
-
Then - Actions
- Set Temp_Int = (Player number of (Owner of TempUnit))
- Set Temp_HeroPos[Temp_Int] = (Position of TempUnit)
- Set Temp_RandomHeroSpawn[Temp_Int] = (Random point in WoodSpawn <gen>)
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade out over 0.00 seconds using texture White Mask and color (0.00%, 0.00%, 0.00%) with 0.00% transparency
- Custom script: endif
- Unit - Move TempUnit instantly to Temp_RandomHeroSpawn[(Player number of (Owner of (Picked unit)))]
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade in over 1.00 seconds using texture White Mask and color ((Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%) with 0.00% transparency
- Custom script: endif
- Custom script: call RemoveLocation(udg_Temp_RandomHeroSpawn[udg_Temp_Int])
- Unit Group - Add TempUnit to Wood[2]
- Unit Group - Remove TempUnit from Wood[0]
- Else - Actions
-
If - Conditions
-
Loop - Actions
- -------- Spawning the Creeps --------
- Set Int_WC = ((Number of units in Wood[4]) x 2)
- Set Int_RWC = (Random integer number between 1 and Int_WC)
-
For each (Integer A) from 1 to Int_RWC, do (Actions)
-
Loop - Actions
- Set Temp_PointArray[1] = (Random point in WoodSpawn <gen>)
- Unit - Create 1 WoodCreeps[(Random integer number between 1 and 9)] for Neutral Hostile at Temp_PointArray[1] facing Default building facing degrees
- Custom script: call RemoveLocation(udg_Temp_PointArray[1])
-
Loop - Actions
-
Unit Group - Pick every unit in Wood[0] and do (Actions)
- Else - Actions
-
If - Conditions
- -------- WOOD CLEANING --------
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Or - Any (Conditions) are true
-
Conditions
- (Number of units in Wood[2]) Equal to (Number of units in Wood[3])
- (Number of units in Wood[2]) Equal to 0
-
Conditions
-
Or - Any (Conditions) are true
-
Then - Actions
-
Unit Group - Pick every unit in Wood[2] and do (Actions)
-
Loop - Actions
- Set TempUnit = (Picked unit)
- Set Temp_Int = (Player number of (Owner of (Picked unit)))
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade out over 0.00 seconds using texture White Mask and color (0.00%, 0.00%, 0.00%) with 0.00% transparency
- Custom script: endif
- Unit - Move TempUnit instantly to Temp_HeroPos[Temp_Int]
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade in over 1.00 seconds using texture White Mask and color ((Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%) with 0.00% transparency
- Custom script: endif
- Unit - Create 1 DummySafetyCaster for Neutral Passive at Temp_HeroPos[Temp_Int] facing Default building facing degrees
- Unit - Order (Last created unit) to Human Priest - Inner Fire TempUnit
- Unit - Remove (Last created unit) from the game
- Custom script: call RemoveLocation(udg_Temp_HeroPos[udg_Temp_Int])
- Unit Group - Remove TempUnit from Wood[2]
- Unit Group - Add TempUnit to Wood[0]
-
Loop - Actions
-
Unit Group - Pick every unit in Wood[4] and do (Actions)
-
Loop - Actions
- Unit - Remove (Picked unit) from the game
-
Loop - Actions
-
Item - Pick every item in WoodCombat <gen> and do (Actions)
-
Loop - Actions
- Item - Remove (Picked item)
-
Loop - Actions
- Destructible - Pick every destructible in WoodCombat <gen> and do (Destructible - Resurrect (Picked destructible) with (Max life of (Picked destructible)) life and Hide birth animation)
-
Unit Group - Pick every unit in Wood[2] and do (Actions)
- Else - Actions
-
If - Conditions
- -------- WOOD LEAKS --------
- Custom script: call DestroyGroup(udg_Wood[1])
- Custom script: call DestroyGroup(udg_Wood[2])
- Custom script: call DestroyGroup(udg_Wood[3])
- Custom script: call DestroyGroup(udg_Wood[4])
- -------- BEACH --------
- Set CCP[1] = (Center of BeachCombat <gen>)
- Set Beach[1] = (Units in BeachCombat <gen> matching ((((Matching unit) is alive) Equal to True) and (((Matching unit) is in UONH) Equal to True)))
- Set Beach[2] = (Units in BeachCombat <gen> matching (((Matching unit) is A Hero) Equal to True))
- Set Beach[3] = (Units in BeachEscape <gen> matching (((Matching unit) is A Hero) Equal to True))
- Set Beach[4] = (Units in BeachCombat <gen> owned by Neutral Hostile)
- Floating Text - Create floating text that reads (Creeps Left: + (|cfffff700 + ((String((Number of units in Beach[1]))) + |r))) at CCP[1] with Z offset 0.00, using font size 10.00, color (100.00%, 100.00%, 100.00%), and 0.00% transparency
- Floating Text - Change (Last created floating text): Disable permanence
- Floating Text - Change the lifespan of (Last created floating text) to 1.20 seconds
- Custom script: call RemoveLocation(udg_CCP[1])
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Random integer number between 1 and 100) Less than or equal to (Random integer number between 4 and 16)
- (Number of units in Beach[2]) Equal to 0
-
Then - Actions
-
Unit Group - Pick every unit in Beach[0] and do (Actions)
-
Loop - Actions
- Set TempUnit = (Picked unit)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (TempUnit has buff Safety ) Equal to False
-
Then - Actions
- Set Temp_Int = (Player number of (Owner of TempUnit))
- Set Temp_HeroPos[Temp_Int] = (Position of TempUnit)
- Set Temp_RandomHeroSpawn[Temp_Int] = (Random point in BeachSpawn <gen>)
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade out over 0.00 seconds using texture White Mask and color (0.00%, 0.00%, 0.00%) with 0.00% transparency
- Custom script: endif
- Unit - Move TempUnit instantly to Temp_RandomHeroSpawn[Temp_Int]
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade in over 1.00 seconds using texture White Mask and color ((Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%) with 0.00% transparency
- Custom script: endif
- Custom script: call RemoveLocation(udg_Temp_RandomHeroSpawn[udg_Temp_Int])
- Unit Group - Add TempUnit to Beach[2]
- Unit Group - Remove TempUnit from Beach[0]
- Else - Actions
-
If - Conditions
-
Loop - Actions
- -------- Spawning the Creeps --------
- Set Int_BC = ((Number of units in Beach[4]) x 2)
- Set Int_RBC = (Random integer number between 1 and Int_BC)
-
For each (Integer A) from 1 to Int_RBC, do (Actions)
-
Loop - Actions
- Set Temp_PointArray[2] = (Random point in BeachSpawn <gen>)
- Unit - Create 1 BeachCreeps[(Random integer number between 1 and 7)] for Neutral Hostile at Temp_PointArray[2] facing Default building facing degrees
- Custom script: call RemoveLocation(udg_Temp_PointArray[2])
-
Loop - Actions
-
Unit Group - Pick every unit in Beach[0] and do (Actions)
- Else - Actions
-
If - Conditions
- -------- BEACH CLEANING --------
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Or - Any (Conditions) are true
-
Conditions
- (Number of units in Beach[2]) Equal to (Number of units in Beach[3])
- (Number of units in Beach[2]) Equal to 0
-
Conditions
-
Or - Any (Conditions) are true
-
Then - Actions
-
Unit Group - Pick every unit in Beach[2] and do (Actions)
-
Loop - Actions
- Set TempUnit = (Picked unit)
- Set Temp_Int = (Player number of (Owner of (Picked unit)))
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade out over 0.00 seconds using texture White Mask and color (0.00%, 0.00%, 0.00%) with 0.00% transparency
- Custom script: endif
- Unit - Move TempUnit instantly to Temp_HeroPos[Temp_Int]
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetEnumUnit()) then
- Cinematic - Fade in over 1.00 seconds using texture White Mask and color ((Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%, (Random real number between 0.00 and 100.00)%) with 0.00% transparency
- Custom script: endif
- Unit - Create 1 DummySafetyCaster for Neutral Passive at Temp_HeroPos[Temp_Int] facing Default building facing degrees
- Unit - Order (Last created unit) to Human Priest - Inner Fire TempUnit
- Unit - Remove (Last created unit) from the game
- Custom script: call RemoveLocation(udg_Temp_HeroPos[udg_Temp_Int])
- Unit Group - Remove TempUnit from Beach[2]
- Unit Group - Add TempUnit to Beach[0]
-
Loop - Actions
-
Unit Group - Pick every unit in Beach[4] and do (Actions)
-
Loop - Actions
- Unit - Remove (Picked unit) from the game
-
Loop - Actions
-
Item - Pick every item in BeachCombat <gen> and do (Actions)
-
Loop - Actions
- Item - Remove (Picked item)
-
Loop - Actions
- Destructible - Pick every destructible in BeachCombat <gen> and do (Destructible - Resurrect (Picked destructible) with (Max life of (Picked destructible)) life and Hide birth animation)
-
Unit Group - Pick every unit in Beach[2] and do (Actions)
- Else - Actions
-
If - Conditions
- -------- BEACH LEAKS --------
- Custom script: call DestroyGroup(udg_Beach[1])
- Custom script: call DestroyGroup(udg_Beach[2])
- Custom script: call DestroyGroup(udg_Beach[3])
- Custom script: call DestroyGroup(udg_Beach[4])
- -------- Global --------
- Custom script: call DestroyGroup(udg_UONH)
-
Events
Also (a bit offtopic) I was testing with version 1.26a and the other players (with same version) were kicked, but works with 1.24e :S. What could be the cause?