There is an OS called SkyOS (http://www.skyos.org). It's a one-man show, but have been around for years. Unfortunately, the foundation is not complete as of yet, so it's no good for any kind of server development. And it has some basic client side development possibilities. But all in all, it may work well for 2D game clients ... who knows. From what I have seen so far, it whip's Linux's butt for basic use ....
With the database back-end and the DAL complete, I turned my eyes towards networking. As you know from previous entries, Socket Tools is used due to ease of use, SSL, and the fact that purebasic have no plans for a basic server network library.
There are a few servers (software) that must be created to get this game (Unformed) off the ground. One Login server, 2 Shell Servers, 1 Core server, 1 AI server, and 1 instance server.
The login server is where everybody connects, manage their characters (add/delete, etc), and then gets forwarded to a shell server. A shell server is pretty much an enhanced relay server. They are created to run on the least amount of resources possible, with massive amount of connections.
What they do is accept a connection transfer, and forward commands to and from the core server and player. If a core server has a message/packet to send to everybody on a map, it sends one packet to each shell server. And the shell server will relay that message to everybody on that map on it's shell.
This keeps the bandwidth cost of the core server down to a minimum, while the shell servers can handle the huge traffic. Now this brings us to the core server. This is responsible for the movement validations, economy, and various other things. It accepts input from shell servers, and AI server.
Instance server(s), are available for the sole purpose of instances. Each server can hold an instance of a pre-determined amount. When a player/group enters an instance, they are transferred to an instance server that has free slots available. That server will load up the instance, and take the player's connection. Since these servers are mostly self contained, the Instance server fills the roll of the Core, and AI server in one package.
The AI server controls the MOBs, NPCs, Companions, Pets, and Minions in the game. That is the sole purpose of the AI server. With the database backend, this allows for multiple AI servers, each controlling their own portions of the AI ... Scalability at it's best :P
Since my goal is to have each server use less resources, and able to do more in a short time period .. Contention is something to watch out for, especially in threads. With that said, the only thing the login server needs to worry about is a shared (in memory) ban/suspension list. And, since the server is one of the least bandwidth/time resource hog, it can be threaded nicely.
Shell servers are a little bit trickier, they need to maintain one connection to login server, one to core server, and all the player connections. It really only need one thread for sending, and one for receiving per socket class.
The core server isn't rocket science. Environmental controls, zone controls, movement validations, economy, items, effects and the like. Really simple stuff. It has connections to AI, Login, Shell, and instance servers.
That's about it, server wise. Original graphics and music, or at least CC licensed products are a bit tough to find on the net, with permission of course. One of the mistakes with Mirage, is that it uses copyrighted graphics without permission, also known as stealing and is against the law :( Unfortunately, almost the entire Mirage based games, such as Legend of the Zodiac (Ex), Secrets of Mirage, etc follows in Mirage's footsteps, using stolen graphics, and in some cases, stolen music.
With Unformed, I want to get away from that. The way I see it, if I used stolen stuff in my game, then it's not really my game. This is for released versions. Testing is a bit of a difference as it's not really released, its for testing algorithms, etc.
Cost is another issue. Each server/hardware dedicated server costs between $20 to $300 a month to rent. For starting, this is a good deal. But once you start scaling out the servers, it gets expensive. There's the option to buy or build a server and co-locate it. But every single collocation cost I have found is extremely over priced. Head over to http://www.webhostingtalk.com. It is one of the best places to find Dedicated servers. The problem is, the top leaders in the collocation industries who are giving out false information there, even admitted to be scammers when it comes to collocating expenses, ouch!
So it's time to look for small shops ... :P Any how, back to prices. I figured $2 a month per account is adequate. At least with 100 folks, I should be able to pay about one dedicated server, after IRS takes away the taxes.
From there, as the user base grows, I can start placing the individual servers on their own hardware, then eventually add more shell and instance servers. I forgot to mention, having shells in different datacenters around the country is a must to service people in the US with decent speeds. The only catch is that the shell server would need a fat pipe for player connections, and a fast connection to the rest of the gaming network servers.
With all written above, most of the network infrastructure is complete. All except for the update server. I remember reading the Guild Wars developer interviews concerning the updating the game on the fly, claiming to be the first? I laughed since the first mmo that did that came out in 2001 ... years before guild wars.
So, since Mirage pioneered on-the-fly updating, I was looking at doing the exact same for Unformed. It's not hard, create a hash for a version, as well as files, and do a comparison. Same for all updates done.
Now, the workload could be on it's own server, instead of integrated into the game server, but why do it at all? If much of the server side logic are compiled scripts such as CScript (aka C#). Then they could be modified with out modifying the client. Bug fixes and AI changes could be done on the fly. Object data (sans id, name and image) can be modified on the fly.
The only updates truly needed are for additional/modified media (graphics, sound/music), and the media's identifiers (name & id). With that as the case, client updates are rarely (say monthly or so) needed. And even in that case, just have the Patcher run before the client runs, each time to check for updates that way.
As mentioned before, Unformed uses byte based networking. It first came into the MS community by Verrigan, then when Spodi came onto the scene, he created a nice tutorial on his site http://www.vbgore.com, you may even seen him on Gamedev.net :) However, since (it seems), I'm one of the few people who believe security is needed between a client and a server, Unformed will be using SSL for encryption. This does make the packets bigger, but not as big as string packets, since I use bytes instead.... :)
That's all I can think about for this entry. The next one should contain some actual content related info!