Hi guys!, im new here and im trying to develop my first game.
I need some help with a minor doubt. The user actions in my game is spllited in two. First one he select a token, the server response with the avaiable movements for this token. Second the user select one of this movements. The flow works if you dont refresh the page, but in that case if you refresh in the second part, the client doesnt have which tokens was selected to show the possible movements. My question is, should I store this data in the db, is just a coord (x,y) or there s a way to store in memory ? What are best practices to manage these kind of temp data?
Thanks !
edit: What are the best way to console log the server ? i tried with var dump or notify, but sometimes it fails
I need some help with a minor doubt. The user actions in my game is spllited in two. First one he select a token, the server response with the avaiable movements for this token. Second the user select one of this movements. The flow works if you dont refresh the page, but in that case if you refresh in the second part, the client doesnt have which tokens was selected to show the possible movements. My question is, should I store this data in the db, is just a coord (x,y) or there s a way to store in memory ? What are best practices to manage these kind of temp data?
Thanks !
edit: What are the best way to console log the server ? i tried with var dump or notify, but sometimes it fails