Jump to content

Consistency across sessions


pintee

Recommended Posts

Hello everyone,


 


I am making a text based browser rpg and I've stumbled into a bit of a problem and am not sure how to proceed. How do you keep consistency across multiple instances of the game running at the same time?? For example....


 


Say a user is playing the game in one window. He/She is presented with the hyperlink "Open Blue Door" which will load a new screen of the game. Say the user opens that link in a new window. There will now be two instances of the game running, and it would be possible to play the game along one storyline in one window and play the game along another completely seperate storyline in the other window. In other words, there would be two instances of the game running at the same time and they would be inconsistent.


 


Or another example is if a user is in the middle of a game, opens a new window, goes to the website and hits play, it should go directly to where the user is in the other window and not start a new game.


 


I apologise if this is a noob question and thank you for your time in advance.

Link to comment
https://forums.phpfreaks.com/topic/277665-consistency-across-sessions/
Share on other sites

Store the player's progress in a session that way when he would take separate routes (between tabs/windows) you can detect he did and act upon it. The same goes for when he would open a new window. You can also store his progress in the database.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.