Data exchanges

If you find a bug please report it here

Data exchanges

Postby LichKing » Fri Mar 23, 2012 7:32 pm

This isn't really a bug, but it can be exploited to your advantage or put you in some mess..
It seems to me that the client exchanges data when units move and unfog an area that was fogged. If the area is unfogged already, units move without being synced, and the game is synced again if there's a battle. Sometimes it happens (because of bad connection) that I move my units, but for the server those units didn't move at all. So I often reload everything before pressing 'end turn' to be sure that all units actually moved. I also found a way how this can be exploited: if you have a hero and go to a ruin, you don't explore it, then disconnect, then search the ruin (while disconnected), it tells you what you find (enemies) so you can decide if it's safe to explore it or not.

Even if this would imply more exchanged data, it would be imo better if the client checks also movements inside the unfogged area, or at least when entering ruins (to avoid the exploitation)..
LichKing
 
Posts: 178
Joined: Tue Feb 15, 2011 7:53 pm

Re: Data exchanges

Postby SnotlinG » Fri Mar 23, 2012 8:31 pm

Hello,

An important goal from the beginning of the project has been that it should not be possible to cheat. This means we do not store anything in the client that the player is not allowed to know already, like enemy troop location/numbers/ruin guardians etc...

Ill try to clarify how it works for your question :-)
When moving into FOW area, you unit wont uncover the FOW until you get response from the server (as the client doesnt know what is in the FOW - to make it impossible to cheat). So this means you will sometimes see your unit move part of its move, and then halt and wait for the server reply before finishing the move.

When moving in your own unfogged land, you dont need to wait for server response. This is to speed up the gameplay, and also it is very rare that moves are lost by the server. (but could happen - see "end turn" below)
The client keeps track of every move you make during your turn and checks of the server response to know the move has been successful.

Ruin works the same way, the client doesnt hold the data (only the ruin status explored/unexplored). If you have no internet connection, you can not search the ruin. So no way to cheat :-)

End turn:
When you press endturn, the client checks its log of all the moves you have made, and re-sends the moves that has not been acknowledged by the server. This is normally very seldom moves are lost this way, but if you have a bad connection it could happen, but it means at end turn your client will then re-send them so the can be executed properly as you have expected.

With this said, it is possible to "lose" moves if you have a bad connection, and make half of your turn, and then just exit the browser, your lost moves would be lost - but hopefully you would see this next time you load the turn. There is actually a save game option in the "TURN" dropdown, that will perform this same move check as end turn does, just for this purpose when you want to make half a turn and then exit. Though I doubt anyone is using that functionality :-)
SnotlinG
 
Posts: 2148
Joined: Sat Feb 13, 2010 12:42 am

Re: Data exchanges

Postby LichKing » Fri Mar 23, 2012 8:56 pm

But.. I could see which enemies were in a ruin with this trick. I explain what I happened to me: my hero wasn't on the ruin, he was 1 tile away. I moved him on the ruin (this didn't unfog new tiles, so no data was exchanged), but I didn't receive the automatic popup ('do you want to search the ruin?'). So I pressed the ruin button, it asked me if I wanted to search the ruin, I said yes, and it said there was 1 ghoul, the battle screen appeared, but empty. Now I realized that connection was lost. So I reloaded, the hero *wasn't* on the ruin, he was 1 tile away(he didn't move at all). I moved him on the ruin, this time I got the automatic popup, I said yes, and what did I have to fight? 1 ghoul as before.
LichKing
 
Posts: 178
Joined: Tue Feb 15, 2011 7:53 pm

Re: Data exchanges

Postby LichKing » Fri Mar 23, 2012 9:00 pm

When I say that I knew what I would have faced, I mean I didn't see it in the battle screen, but in a second popup that says 'your hero enters the ruin and has to fight 1 ghoul' or something similar, before the actual battle screen. Maybe it would be enough that this popup doesn't reveal what you'll face inside.
LichKing
 
Posts: 178
Joined: Tue Feb 15, 2011 7:53 pm

Re: Data exchanges

Postby SnotlinG » Fri Mar 23, 2012 9:26 pm

then it is definitely a bug. I will investigate :-)

Thanks for reporting!
SnotlinG
 
Posts: 2148
Joined: Sat Feb 13, 2010 12:42 am

Re: Data exchanges

Postby Draxus » Sun Mar 25, 2012 10:31 am

This has happened to me before when the hero goes to search the ruin and dies. Some times he will appear where he started or alive on the ruin. Looks like you might have gotten away with something. But once you try to move the hero or refresh, it goes to how it should be, with hero dead, not alive and a tile away. Might be a different bug than what LK is describing since his hero lives, but seems similar. If you can do it again, try refreshing after stepping onto the ruin for the first time, but I suppose this would initiate a data exchange, I don't know why I posted...
Draxus
 
Posts: 104
Joined: Mon Nov 07, 2011 11:19 pm

Re: Data exchanges

Postby SnotlinG » Mon Mar 26, 2012 8:12 am

Draxus; the bug with the Hero remaining on the ruin after he dies in ruinsearch is fixed in the next version.

LichKing, I found the bug in the code and it has been fixed now. Since it was possible to exploit this I have fixed it in beta5 also.

Thanks for reporting! :-)
SnotlinG
 
Posts: 2148
Joined: Sat Feb 13, 2010 12:42 am


Return to Bug reports

Who is online

Users browsing this forum: No registered users and 4 guests

Not able to open ./cache/data_global.php