ensingm2/saliengame_idler

Stuck getting empty JSON responses on start_round

Harest opened this issue · 2 comments

Not sure why yet. I kept receiving empty JSON responses while trying to start_round, x-eresult = 11.
Edit : Okay the error message with it is x-error_message | Already in zone game 2159. I've the feeling an error occured on the server-side here. Ideal treatment would be to detect this error number and leave the zone.
A part of the console log :

02:37:11,570 Waiting 5s and re-sending join attempt(Attempt #4).
Scratchpad/1:85:4
02:37:19,379
Array(25) [ <10 empty slots>, … ]
Scratchpad/4:64:2
02:37:19,380 Getting best zone
Scratchpad/1:85:4
02:37:19,380 #TerritoryControl_PlanetScience! - Zone 37 Progress: 0.4325965344905853 Difficulty: 1
Scratchpad/1:546:3
02:37:19,381 Found new best zone: 37
Scratchpad/1:643:4
02:37:19,681 Updating grid
Scratchpad/1:85:4
02:37:19,701 Successfully updated map data on planet: 24
Scratchpad/1:487:4
02:37:19,702 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:19,703 Waiting 5s and re-sending join attempt(Attempt #0).
Scratchpad/1:85:4
02:37:24,989 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:24,991 Waiting 5s and re-sending join attempt(Attempt #1).
Scratchpad/1:85:4
02:37:30,245 Updating grid
Scratchpad/1:85:4
02:37:30,479 Successfully updated map data on planet: 24
Scratchpad/1:487:4
02:37:30,480 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:30,481 Waiting 5s and re-sending join attempt(Attempt #2).
Scratchpad/1:85:4
02:37:35,728 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:35,729 Waiting 5s and re-sending join attempt(Attempt #3).
Scratchpad/1:85:4
02:37:38,045 Detected the game script is locked. Trying to unlock it.
Scratchpad/1:85:4
02:37:39,057
Array(25) [ <10 empty slots>, … ]
Scratchpad/4:64:2
02:37:39,058 Updating grid
Scratchpad/1:85:4
02:37:39,079 Successfully updated map data on planet: 24
Scratchpad/1:487:4
02:37:39,080 Getting best zone
Scratchpad/1:85:4
02:37:39,080 #TerritoryControl_PlanetScience! - Zone 37 Progress: 0.4329208731651306 Difficulty: 1
Scratchpad/1:546:3
02:37:39,081 Found new best zone: 37
Scratchpad/1:643:4
02:37:39,320 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:39,321 Waiting 5s and re-sending join attempt(Attempt #0).
Scratchpad/1:85:4
02:37:44,531 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:44,532 Waiting 5s and re-sending join attempt(Attempt #1).
Scratchpad/1:85:4
02:37:49,802 Updating grid
Scratchpad/1:85:4
02:37:49,853 Successfully updated map data on planet: 24
Scratchpad/1:487:4
02:37:49,854 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:49,856 Waiting 5s and re-sending join attempt(Attempt #2).
Scratchpad/1:85:4
02:37:55,110 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:37:55,111 Waiting 5s and re-sending join attempt(Attempt #3).
Scratchpad/1:85:4
02:38:00,369 Updating grid
Scratchpad/1:85:4
02:38:00,596 Successfully updated map data on planet: 24
Scratchpad/1:487:4
02:38:00,597 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:38:00,598 Waiting 5s and re-sending join attempt(Attempt #4).
Scratchpad/1:85:4
02:38:08,070
Array(25) [ <10 empty slots>, … ]
Scratchpad/4:64:2
02:38:08,071 Getting best zone
Scratchpad/1:85:4
02:38:08,071 #TerritoryControl_PlanetScience! - Zone 37 Progress: 0.43308737874031067 Difficulty: 1
Scratchpad/1:546:3
02:38:08,072 Found new best zone: 37
Scratchpad/1:643:4
02:38:08,316 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:38:08,317 Waiting 5s and re-sending join attempt(Attempt #0).
Scratchpad/1:85:4
02:38:13,616 Updating grid
Scratchpad/1:85:4
02:38:13,759 Successfully updated map data on planet: 24
Scratchpad/1:487:4
02:38:13,761 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:38:13,762 Waiting 5s and re-sending join attempt(Attempt #1).
Scratchpad/1:85:4
02:38:19,018 Error getting zone response (on start): 
Object { response: {} }
Scratchpad/1:248:6
02:38:19,019 Waiting 5s and re-sending join attempt(Attempt #2).

I feel like it's these lines. Gets set to undefined right before start_round is called, so the round isn't ended. No idea why it's only periodic though.

I edited my message. When i look at the log again, there's nothing abnormal. The score was submitted succesfully, so the game should have registered the fact i left the zone automatically. Instead i was stuck inside forever ^^. We just need to add a check if the header x-eresult = 11 and if yes to get the gameid in the error message (x-error_message) to trigger a leave_round on it.