I had a very good reason for deciding to go down the route of hammering out account and character select. I can’t remember what it was, but I know I had a very good reason this morning.
So what I did today was split the login activities out of the gameplay activities, and now I actually run two servers – one for login and one for gameplay.
When you start up the game, you type in a username and password, the login server pulls your account data, verifies you, and then gives you back your list of characters.
Then the client shows you the character select screen, you pick one of those characters, and then the server does a bunch of work to verify that you’re actually able to log in on that character.
Loading into the actual gameplay scene is a little more streamlined now because it’s not doing all the login procedures as part of the initial load, much of that data is already stored locally on your machine.
Oh, I just remembered why I wanted to do this… I couldn’t stop thinking about how I’d have the server handle multiple areas at the same time, and lots of characters across those multiple areas, and how the client would protect itself from getting updates about every character on the server at all times, even if it didn’t need to.
I came up with a plan, but that requires me to separate the gameplay server out from the actual gameplay elements just a tad. Separating the login stuff from the gameplay stuff was a prerequisite.
And just in case I didn’t make it clear enough, all the stuff in the video below is not hard-coded. The only thing that’s placeholder is the character sprite. Everything else is actually being checked, loaded, and returned by the actual server.
I’m running out of excuses to procrastinate making gameplay so I’m going to start working on porting that dialogue system.
Not tomorrow … now.