Time seems to fly by faster than ever before. I don't know about you but last time I checked it was still 2013. Perhaps it is just mere proof of progress, at least that's what I'm thinking. Time tends to go by faster when you're busy doing stuff, right?
Every time I start up Terra Militia there's a decision I have to make, practical progress or writing a blog post. By today I have four
topics queued that I really want to share with you in the future. This past month I've been making so much exciting progress though, that I was afraid I would stop the momentum if I paused to write a blog post. I finally caught up with myself, and here goes.
is it that has kept me so busy this month? Global chat
, retrieving and hosting lobbies, implementing the first aircraft
, making a launcher and updater for the game from scratch, silent updates on the website are some that come to mind. Aside from such practical matters I've spent some time thinking about the game's design and I have some thoughts which I'll want to share with you at a later time. I've also been in contact with a nice fellow whose music
you might hear in Terra Militia in the future.
Oh and of course, I've been trying to have fun playing some other games, can't deny that. I can't wait for the time when I can spend my fun time over multiplayer in Terra Militia
instead, and have players own me?Aircraft, although a static screenshot really does not do them justice..
The future of Terra Militia is on my mind every single
day and at this stage it truly feels like a life project. Never have I spent so much time and learned so much from a single project. From pathfinding, advanced user input and multiplayer to optimization, and well basically every component that a real-time strategy game consists of. It is the greatest project I've ever undertook.
The Global Chat
Global Chat is exactly what it sounds like. A chat available to all people signed into the game. It's something that many titles employed in their early years, but as the net evolved most dropped it - something that has spurred minor uproar in many strategy communities. Other than giving a sense of interaction and community, the global chat provided players with a easy way to talk, discuss and plan matches.
It is something that I personally see essential in a game to build a community in which all action happen in instanced matches, unlike MMOs with vast open worlds with territorial chat and interaction.
Of course, depending on number of users and should the chat be too flooded it must always be possible to split it up into smaller, more useful sections.
In the screenshot above, you can see what it looks like in the main menu. As I got really satisfied with the design I'm currently planning to have the same chat window used ingame, expanding it to allow several different chat "rooms". Never having done something like this before, it was surprisingly easy.
How it works
With a authorized key that the user gains upon logging in, it talks with the chat database via PHP code on a server to send and receive messages. Surely not the most common way of doing it, but as I have no dedicated server as of yet it will have to do.
Every second the client sends its unique session key to the chat handler script over on the server.
As the server receives a key, it checks if it's a legitimate authorized key and if so it responds with all chat messages entered the previous four seconds apart from the clients own messages which the call came from.
The client will then filter out messages by ID's which have been already received not to spam up the chat window with several repeating messages.
So the bad things about this system? For one, players joining the chat could receive messages sent before they joined, not too big of a problem, but something we're not used to encounter in most chat interfaces.
Other than that, if the client disconnects for more than four seconds it will potentially miss some messages.
If I modify the server to send all messages sent for the past thirty seconds, enough for the client to disconnect from the server it wouldn't miss any messages. It would however put little, but more pressure on the server to send and for the client to filter the messages, so its essentially a decision of cost versus value
Telling the player that he/she is disconnected and not receiving messages is one way to handle it. A extreme solution would be to make the client disconnect from the game should it lose connection for four seconds.
A perfected solution would be to have a specialized script the client can call on the server which will send all messages for the period of time the user was disconnected, even if this could be potentially abused to put pressure on the server. So, should one decide to do it this way, counters should also be implemented to limit on how much information the server can send to any given client.
Now when we put all this into consideration, perhaps telling the client that it is disconnected (and thus not receiving messages) is enough...
Now that there is a functioning game updater (which even can update itself, isn't that incredible!?
) and as this multi-front progression stabilizes I'll start inviting the very first people into pre
-alpha testing the game.
be interested, send me a mail at email@example.com
and don't forget to register an account on this website.
Leave a Comment:
august January 19th, 2038
Impressed with where this is going, are you making all by yourself or do you have a team? Best of luck :)
Trigger01 January 19th, 2038
[#37] Hi thanks, everything apart from a few art assets is done by me.
taichedan January 19th, 2038
I've been reading a few posts and really and enjoy your writing. I'm just setting up my own blog and only hope that I can write as well and give the reader so significantly insight.