Featured games (91)
games approved by the League of Dukes
Games in Showcase (581)
games submitted by our members
Games in WIP (500)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Generic game server  (Read 4431 times)
0 Members and 1 Guest are viewing this topic.
Offline generateui

Junior Newbie

« Posted 2011-04-05 21:54:32 »

Hi all,

I have a personal game project I'd like to dev on. It's a multiplayer game playable in the browser, written in Java. Currently, I'm writing a gameserver. This is going well, but I wonder if there are already gameservers available? I found some projects, such as Red dwarf, Vassal, Arianne and there are more. I'm looking for a generic gameserver, which has most stuff abstracted away. For instance, I'd like to support multiple transport implementations such as binary sockets, websockets, et cetera. The projects I found tie themself to binary sockets, and as such is unusable for my webbased client.

Surely there must be some kind of generic game server project, aimed on handling comomn tasks like accounts, chatrooms, gamerooms, logging, class API?

Thanks in advance!
Offline ddyer

Junior Member

Medals: 2

« Reply #1 - Posted 2011-04-06 18:14:14 »

If you're set on developing your own site, there's a framework called "Jogre" on source forge
that might be your best bet.

The other likely path is to shop your game to whatever site seems most compatible.   There are a
bunch of indie game sites that use Java as their primary engine, and some no doubt would welcome
volunteer developers. is in that group.
Offline ra4king

JGO Kernel

Medals: 322
Projects: 2
Exp: 4 years

I'm the King!

« Reply #2 - Posted 2011-04-07 04:34:18 »

I believe he wants a server for a game, not a site.

Other than that, sorry I can't help :/
I think you'll have to go solo on this one; I wrote my own game server with similar functionality and it's not that hard to do Tongue

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Eli Delventhal

JGO Kernel

Medals: 42
Projects: 12

Game Engineer

« Reply #3 - Posted 2011-04-07 19:39:20 »

I think Project Darkstar does a lot of this stuff?

You can check out for a lobby API as well as some magic to automatically send state changes across the network.

And you can get a VPS like as a starting point for your multiplayer projects. It's a good place to get things going, and later you can get a more dedicated server if you have enough people playing your game.

See my work:
OTC Software
Offline generateui

Junior Newbie

« Reply #4 - Posted 2011-04-08 02:25:35 »

Jogre relies on binary sockets, like Arianne, Darkstar, Red dwarf, Vassal. Gamegardens looks interesting but has some weird dependencies which I want to avoid. Also, it seems to do xml parsing by hand.

Writing a gameserver indeed is not that hard. Writing a full-featured gameserver is very hard though, since it involves a lot of stuff. Think flooding, banning, rough talk detection, player admin, game admin, logging, UI elements, data definitions, et cetera. As a matter of fact, I already have a good working gameserver which can be used locally. The remote gameserver also somewhat works, but as I develop on it, most stuff I want/do just seems the 345670976542345679th wheel invented. I want to avoid that, to keep code quality high and quantity low.

Looking to most gameserver java implementations, it seems accepted to tightly couple the code to binary sockets. Which is logical, since the assumption that only java applets will consume the server was since a few years back normal. It sucks though, because it instantly rules out the possibilty to use it for my project Sad
Offline Gudradain
« Reply #5 - Posted 2011-04-08 04:06:21 »

Hmmm you would be better to forget about banning (will you ban every single person that does something ''incorrect'' yourself?) and rough talk detection (too complicated or too simple...). For player admin and game admin, I guess that most of it should be in your game code and not in the server code right? (I understand admin as in managing the game option). UI elements!? Does it means the user interface in your game? (how is that related to the network code).

Logging and user account could be an interesting feature. As well as lobby for joining games.

What do you mean about binary socket, does it means you need to send your data in binary form? Personally I use a server where you send object over the network, it's so much easier. The process of serialization is not really a problem for performance either.
Offline generateui

Junior Newbie

« Reply #6 - Posted 2011-04-08 06:31:04 »

Basically I mean a server which is not tied to any of the underlying mechanisms of transporting objects. Whether that be pigeons, strings, binary data, I just want to throw objects to the server and let the server receive them. Gameserver projects which are tightly coupled to TCP sockets therefore are not suitable for my project.

The features I named are just a small amount of examples I can come up with thinking about it for 10 seconds. I can think of hundreds more which can all be useful for any type of gameserver. The UI elements I mean are the abstracted definitions (interfaces) of the various managing UI widgets. Think server status, add servers, manage users, traffic, load, et cetera, complete with reference implementations using some kind of UI toolkit.
Offline ddyer

Junior Member

Medals: 2

« Reply #7 - Posted 2011-04-08 08:15:27 »

Loosely speaking, some server-client architectures have a very tight relationship, where the server is an integral part of the game.  Others have a looser relationship where the server expects certain things, but otherwise acts as a neutral facilitator.   It sounds like you're looking for the latter, but even there, there are many things which are pretty nailed down and might not suit you.
Offline Mr_Light

Senior Member


« Reply #8 - Posted 2011-04-10 18:05:57 »

just sending objects is the RMI way which is well.... silly.

you probably don't care about mantaining object identity and related consistency across sites.

Given you just want to send dataobjects/struct like stuff just check out protocol buffers et al.
add some plumming (mina reddwarf or any other library that adds connectivity)
add some identity server or write your own for banning
move langague, voting and admin stuff to your game specific bit..
stir and add salt to taste.

after that you can wonder about HA and scaling, though I hope your plumming supplier already though a little bit about that one.

It's harder to read code than to write it. - it's even harder to write readable code.

The gospel of brother Riven: "The guarantee that all bugs are in *your* code is worth gold." Amen brother a-m-e-n.
Offline generateui

Junior Newbie

« Reply #9 - Posted 2011-04-26 20:21:22 »


I'm looking for some generic implementation of a gameserver. I can think of lots of functionality needed for most java games, flooding, banning, rough talk detection, player admin, game admin, logging, UI elements, data definitions et cetera. I know I can write a server myself, but for me it really seems to be the 345671092387625th +1 attempt at it.

I never mentioned RMI or any other implementation detail. The only need I have is that the gameserver should be compatible with any tranportation method (WebSockets, binary et cetera).
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline ra4king

JGO Kernel

Medals: 322
Projects: 2
Exp: 4 years

I'm the King!

« Reply #10 - Posted 2011-04-26 22:35:31 »

I still suggest you write your own server and not worry about how many times it's been done before because although each implementation is similar in function, they are all different in architecture and you will waste less time debugging when you know your own code and how it works, rather than use someone else's library that may or may not do exactly what you want it do in a certain way that you like. And etc...

Offline DzzD
« Reply #11 - Posted 2011-04-26 22:41:21 »

I still suggest you write your own server and not worry about how many times it's been done before because each implementation is similar ...
and with a good idea of how you server have to work and the requiered arrchitecture it may be even shorter to restart one from scratch than reusing one

Pages: [1]
  ignore  |  Print  
You cannot reply to this message, because it is very, very old.


Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

xsi3rr4x (64 views)
2014-04-15 18:08:23

BurntPizza (62 views)
2014-04-15 03:46:01

UprightPath (75 views)
2014-04-14 17:39:50

UprightPath (58 views)
2014-04-14 17:35:47

Porlus (76 views)
2014-04-14 15:48:38

tom_mai78101 (101 views)
2014-04-10 04:04:31

BurntPizza (161 views)
2014-04-08 23:06:04

tom_mai78101 (256 views)
2014-04-05 13:34:39

trollwarrior1 (209 views)
2014-04-04 12:06:45

CJLetsGame (216 views)
2014-04-01 02:16:10
List of Learning Resources
by SHC
2014-04-18 03:17:39

List of Learning Resources
by Longarmx
2014-04-08 03:14:44

Good Examples
by matheus23
2014-04-05 13:51:37

Good Examples
by Grunnt
2014-04-03 15:48:46

Good Examples
by Grunnt
2014-04-03 15:48:37

Good Examples
by matheus23
2014-04-01 18:40:51

Good Examples
by matheus23
2014-04-01 18:40:34

Anonymous/Local/Inner class gotchas
by Roquen
2014-03-11 15:22:30 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!