Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (109)
games submitted by our members
Games in WIP (536)
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  
  communication in online games without servers  (Read 3297 times)
0 Members and 1 Guest are viewing this topic.
Offline monkeyget

Senior Newbie





« Posted 2004-05-23 14:32:27 »

Since MBrenaman has the problem (http://www.java-gaming.org/cgi-bin/JGNetForums/YaBB.cgi?board=OnLin;action=display;num=1085189774) and i have been thinking about it a bit, it's time to start a tell-me-what-you-think-about-that-little-idea-i-have.

Nowadays you have two kinds of online games:
-games without servers, if you want to play with an other player you have to enter his ip address.
The problem with that kind of games is that you could have lot of people willing to play at the same time but which wouldn't know someone else wants to play.
The advantage is that you don't have to have a dedicated server (server as game server not a machine of course) running.

-games with servers, you can see other people when you connect, talk with them before playing, see current "game session" and a lot of things like that.
The problem with that kind of game is that you have to "pay"(pay doesn't necessary means money,  it could be bandwidth for instance) for the server.
The advantage is that players can play together easily.


The idea is to have the advantages of the two world  without the inconvenient!
That mean no server but players still "see" all the other players and don't have to search on internet (forums, irc, messenger) for the other gamers.

Ok it would be nice, but how could it be done?
The idea is to have a file (or files) which would be read/write by the game that would inform what happen and who is the "game world". You can of course replace file with a lot of things like sql, irc,...

A file would contains the ip addresses of all the other players.

When someone launch the game, the client (i'm refering to the program run by each person) opens a file containing all the ip addresses of the other gamers, fetch all the ip an add it's own.

Were do we go from here?
Ok we know who is playing the game, but how should we organize the game and the transfer of information?

I have two possible answer to that question:

-peer2peer. After having fetch the ip addresses the client connect to one of the ip and start communicating with them via p2p system.
Advantage: faster than the file system (see below).
disadvantage: really complicate to do!

-use a set of file to communicate. clients would communicate with as set of file, the same kind of file as  the file containing all the ip. The nature of the file would differ depending of the game but there could be a file for each "chat" (general chat, european chat, american chat, game type 1 chat, game type 2 chat,...), a file for each "game session",...




Conclusion:

I'd like to know what you think about this way to communicate, it's feasibility,...

I could have gone further in explanation such as how handle "hard disconnection"(game crash, computer crash, disconnected,... )  but i created this topic to know resceive comments!
So, what do you think?


PS: Sorry for the loosy english!
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #1 - Posted 2004-05-23 14:44:56 »

This area has been very extensively researched over the past 20 years. You want to go and search for peer-to-peer systems (no, not the crappy modern jargon stuff, but the real stuff Wink) particularly "auto-discovery" or "self discovery" or "service location" or "locator services". (or, if you go back far enough, all the jargon changes and they use completely different names Sad ).

If you have a look at J2EE it has it's own locator services that come with it which are pretty good. There are many better examples though.

If you start reading through academic papers (especially of the early to mid nineties IIRC) you are likely to find lots of proposals similar to yours but with the advantage that people probably spent a couple of years trying to make them work Smiley so you can benefit from their experiences.

malloc will be first against the wall when the revolution comes...
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #2 - Posted 2004-05-23 14:51:37 »

Quote
Since MBrenaman has the problem


Apart from his *particular* problem (where he isn't allowed to run java apps etc on the server)...

Quote

-games with servers, you can see other people when you connect, talk with them before playing, see current "game session" and a lot of things like that.
The problem with that kind of game is that you have to "pay"(pay doesn't necessary means money,  it could be bandwidth for instance) for the server.
The advantage is that players can play together easily.


The idea is to have the advantages of the two world  without the inconvenient!


I don't understand how what you describe is any different at all from running a server. It appears to have no benefits (apart from the already mentioned one above...but you seem to be touting "not having to pay bandwidth" as a benefit) - it uses up exactly the same amount of bandwidth - and yet adds extra complication.

You might want to go and look for Crosbie Fitch, who is trying to persuade the world that it's feasible to build an entire multi-million-player MMOG using nothing more advanced than the techniques you are looking at. You might find it interesting, but I warn you in advance it's completely impossible and a pipe dream - just like I mentioned above, it does NOTHING to prevent you having to pay for the bandwidth, but people tend to think of their DSL bandwidth as "free" and forget that one person's DSL b/w can only handle a game with approx 30-50 players max (c.f. NWN which specifically is designed for people to host games from their own PC; their original guideline was "32 players on a DSL, up to 64 if you're really lucky").

Obviously, NWN (and Crosbie's Systeme Secundo) are trying to provide a much richer experience than just IP addresses, and so they need a lot more bandwidth. But the problem remains - if you are ONLY swapping IP Addresses then you could very easily write a java server that equally used up practically no bandwidth at all.

malloc will be first against the wall when the revolution comes...
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline MBrenaman

Junior Member




Javanaut


« Reply #3 - Posted 2004-05-23 15:02:51 »

Well for someone in my situation, I was going to do the same thing kinda with applets and php.

I know a server would be better but should I just wait for my paid time on my current host to run out and then get a Java enabled host or should I attempt a system like the one proposed (I know there's no gain except I could have it right now instead of in 8 months but I was just wondering if making a "no server" system like this was just an utter waste of time)?

-Mathew Brenaman
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #4 - Posted 2004-05-23 17:01:05 »

Quote
Well for someone in my situation, I was going to do the same thing kinda with applets and php.

I know a server would be better but should I just wait for my paid time on my current host to run out and then get a Java enabled host or should I attempt a system like the one proposed (I know there's no gain except I could have it right now instead of in 8 months but I was just wondering if making a "no server" system like this was just an utter waste of time)?


Depends mostly on whether you can actually GET a java-enabled host. For the majority of hosts, they either force you to get a dedicated server to run java, or else they give you a service so poor you don't want it (really, you DON'T want it!).

Given how difficult it is in your particular case, I'd probably go and learn a new programming language - one which most hosts would let you run! Or else lookup the prior art on this stuff that monkeyget has suggested and see if you can find something that fits your needs.

Although...there may be a third way...we're trying to get some java-enabled hosting for JGF, in which case we'd be able to run java game servers on that, free of charge. But it depends how much it's going to cost, and no-one's yet sat down and tried to work out exactly how we'd make sure people didn't run evil code (although one suggestion is to use a GrexEngine install, and that will automatically sandbox the different gameservers; ... but it would force the use of some (fairly generic) API's on the game authors).

malloc will be first against the wall when the revolution comes...
Offline MBrenaman

Junior Member




Javanaut


« Reply #5 - Posted 2004-05-23 17:43:20 »

Well, I know php and I was going to make sockets in this language to run on my server but my webhost won't run unless I get a dedicated server, and even then they don't offer full support.....

I can't believe this, why is it so hard to get a descent server to run server apps or servlets in Java? This basically sucks....

-Mathew Brenaman
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #6 - Posted 2004-05-23 17:55:01 »

Quote

I can't believe this, why is it so hard to get a descent server to run server apps or servlets in Java? This basically sucks....


My thoughts exactly.

The short answer is that many of the people running ISP's these days are either incompetent or just wholly ignorant on technical issues (I've used 5 or 6 major ISP's and countless middle-of-the-market ones, and the pattern repeats across the board - unless you pay thousands per month, entry-level). The standard pattern for successful ones appears to be:

- a group of smart / highly skilled technical people set it up
- the company grows big making lots of money
- the starters leave (I have no idea if they got bored, fired, or paid off)
- company is left with thousands of customers but a system no-one knows how to maintain
- the tech support staff of 30+ have no idea how the system works, and any moderately complex problem (usually because one of the idiots broke their own system) leaves them helpless (and your site down!) for days, or even (sadly far too often) a week or more

Which is part of why recently I've been trying to persuade some ISP's to allow java hosting. All they need is a couple of skilled java programmers and they could go a long way with sandboxing their JVM.

But, realistically, it's going to take a long time / something big for any noticeable change Sad.

malloc will be first against the wall when the revolution comes...
Offline p2pFreak

Junior Newbie




Java games rock!


« Reply #7 - Posted 2004-05-24 16:45:57 »

I want to come back to the p2p idea:

Has anybody ever thought of building a p2p based game? You may have heard of jxta. This platform is a good start. A game could be build upon it and would be able to access all jxta users as possible players (there are some games that already do that).

The power of p2p is, that servers are not needed necessarily. For simple games with a few players (maybe a chess game) this works pretty well. The interesting questions arise, when we try to build games like MMORPGs.

I for myself have some ideas I would like to try out in a game. I analysed some P2P Systems and build a generic simulator for them. This allows for the testing of protocols and algorithms even if there is not yet a great "real life" community available.

I wonder, if anyone might be interested in starting a project together with me. Although I have some experience in P2P networks and Java programming, I am new to Java game programming (I already did some smaller things in C++/OpenGL a while ago...and ofcourse there were this games in Pascal Wink ).
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #8 - Posted 2004-05-24 17:56:49 »

Quote
I want to come back to the p2p idea:

Has anybody ever thought of building a p2p based game?


What's the point?

Quote

The power of p2p is, that servers are not needed necessarily.


Why is that an advantage? Certainly, the lack of server is to me more obviously a DISadvantage (both from a programming point of view, and from a design POV - and even from the POV of thinking "how am I going to run this game?")

(these are partially rhetorical questions). I have spoken long and hard with p2p evangelists who generally had an "innate feeling" that p2p was "the answer" to mmog development. But absolutely no logical concept of how or why - just some vague hand-waving statements like "it doesn't matter if the server goes down".

Equally, I've had similar conversations with people who've not been able to see what problems and difficulties exist with server games for more than a few tens of people. But there seem to be fewer of these around (a dieing breed perhaps Wink).

malloc will be first against the wall when the revolution comes...
Offline darkgem

Senior Newbie




Java games rock!


« Reply #9 - Posted 2004-05-24 18:23:51 »

May I suggest the following host...

http://www.itanets.com

$60 (US) per year - that's only $5 per month
No setup
400MB space
10GB Transfer per month
JSP/Servlet
MySQL

Plus a bunch of other features which you may or may not care about...(like PERL, C++, TCL, Python, PHP4)

http://itanets.com/?a=hosting

I currently have 3 separate accounts with them for 3 different domains. In my experience, their tech support is top notch (very skilled in everything they do), their response time is measured in minutes (under 5 minutes).

I checked their terms of service and here is what they DO NOT allow...

#  Copyrighted material
# Material that is threatening or obscene
# Material that is 'adult only content' or also classified as pornographic *
# Material protected by trade secrets and other statue
# WAREZ Software or not licensed MP3 files
# Spamming software

I'd bet if you sent an email asking them about using your server space for a game, they'd be okay with it as long as you promised not to break anything too badly.

Highly recommend these people, really. Also, you have to explicitly ask them to turn on certain features of their hosting, such as JSP/Servlet support, because not a lot of their customers actually want to use it.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline darkgem

Senior Newbie




Java games rock!


« Reply #10 - Posted 2004-05-24 18:29:37 »

On the topic of p2p games, I would with MMOGs specifically this might be a Bad Thing (tm) because of cheating players.

If there is no authoritative central server, how do you stop players from giving themselves resources and possibly ruining someone else's gaming experience? (Especially if they are competing with each other, ie PvP)

It just brings to mind Kazaa Lite, where you could click a checkbox that said something to the effect "Make me a Kazaa God", basically faking your status so it looked like you were sharing a ton of files, because in making it look like you were sharing a ton of files - you could much more easily grab files from other people.
Offline p2pFreak

Junior Newbie




Java games rock!


« Reply #11 - Posted 2004-05-25 18:33:37 »

Quote
On the topic of p2p games, I would with MMOGs specifically this might be a Bad Thing (tm) because of cheating players.


Cheating is one interesting topic. It is not quiet solved in server based games either Wink There are some interesting theories in p2p research to handle "cheating" (or lets say: security). For example you can implement a byzantine protocol. The basic idea of this is, that you let a group of peers decide, wheather an action is considered cheating or not. You will always have players who try to cheat, but as long as there are a certain number of "honest" players, byzantine protocols work (and if there is no such number of honest players, maybe you should admit that cheating is the reason why people play your game...and then why the heck do you want to avoid it? Wink )

Quote
the lack of server is to me more obviously a DISadvantage (both from a programming point of view, and from a design POV - and even from the POV of thinking "how am I going to run this game?")


As you do not want to have an answer, I have another question: Do you really think spending a million dollar budget for server farms is a big advantage? Or this one: Why on earth is my ping time that high again?

Of course, things are not that easy, but that's what the fun is all about Grin
Offline blahblahblahh

JGO Coder


Medals: 1


http://t-machine.org


« Reply #12 - Posted 2004-05-25 19:21:22 »

Quote

Cheating is one interesting topic. It is not quiet solved in server based games either Wink


Actually it *is* "solved". To claim it isn't is to imply that no-one can use an ATM (cash) machine - because they have all the same problems as games Wink.

P2P systems can use almost exactly the same solution, assuming they can come up with a secure system that is considered authoritative (and your ref to the byzantine generals does exactly this). The interesting bits IMHO with p2p and cheating are that p2p often cannot afford to do proper cheat-prevention because bandwidth is far too expensive today, and latency far too high - and also that p2p can play around with the idea of "partial fairness" although many games - e.g. MMOG's - have proved there is no such thing for their particular genre.

Quote

You will always have players who try to cheat, but as long as there are a certain number of "honest" players, byzantine protocols work (and if there is no such number of honest players, maybe you should admit that cheating is the reason why people play your game...and then why the heck do you want to avoid it? Wink )


Doesn't work in MMOG's. The fundamental thing you need to realise is that *all the players actually benefit by cheating* and *the majority of players cheat sooner or later given the chance*. Your statement above relies upon the hypothesis that "games typically have a lot of honest players", which is known not to be true. It's things like this that break a lot of p2p systems designs - people not realising some of the implicit assumptions they are making which "sound sensible" but in reality don't hold Sad.

Quote

As you do not want to have an answer, I have another question: Do you really think spending a million dollar budget for server farms is a big advantage?


Sony rakes in 10 million dollars *per month* for just one MMOG. Um, at that cost, yes I think that a million-dollar budget for a server farm is a drop in the ocean (it's paid for itself in just ONE MONTH!) and would write the cheque without a second thought.

Anyone running smaller games - those with "only" 75,000 players or so - can usually build their server farm on $50k (20 times less than $1m), which in fact is less than the cost of a single man-year of development.

Which is why I posed the original questions: if you are going to do a sensible evaluation of C/S vs P2P you need to sit down and get the actual facts and figures first. Sadly, very few P2P advocates I meet have actually done this Sad

Quote

Or this one: Why on earth is my ping time that high again?


Um, because your ISP is crap? (affects all net apps no matter how they were written)
...or the game is crap? (uses stupid proprietary protocols)
...or the game-company has spent only a few hundred dollars on their server and hosting?
...or you're sitting in the US playing a game on a server located in Tibet?

Quote

Of course, things are not that easy, but that's what the fun is all about Grin


Yeah, doing p2p systems is certainly fun. But I wouldn't recommend it if you're trying to do a game - you've got enough difficulties to worry about already! Smiley Sad

malloc will be first against the wall when the revolution comes...
Offline p2pFreak

Junior Newbie




Java games rock!


« Reply #13 - Posted 2004-05-25 20:26:07 »

Quote

Actually it *is* "solved". To claim it isn't is to imply that no-one can use an ATM (cash) machine - because they have all the same problems as games Wink.


I got the feeling, that my english (or game experience) is to bad to get this... what is an ATM machine?

Quote
The fundamental thing you need to realise is that *all the players actually benefit by cheating* and *the majority of players cheat sooner or later given the chance*. Your statement above relies upon the hypothesis that "games typically have a lot of honest players", which is known not to be true.


You are right, there might be no "honest" players. But thats why I quoted that Wink . When you consider games, cheating may be an advantage for every SINGLE player, but on the other side players are not interested in other players cheating, are they? That means that there is an interest in controling other players. This control should be build into the protocol. For example: someone wants to relocate his character on the map in a way that is not allowed. Therefore he will have to transmit the new coordinates/the movement to the other peers (instead of a server). As the game has a certain ruleset, impossible movements can be detected by other peers. To prevent that a player is hindered in his legal movement by other players, players should only be allowed to take actions they allow for others (-> maybe thats a weak point that needs some more thinking)

Quote
Anyone running smaller games - those with "only" 75,000 players or so - can usually build their server farm on $50k (20 times less than $1m), which in fact is less than the cost of a single man-year of development.


As you mentioned SOE, they also have a 24 hour service team for maintaining their servers. These are additional costs and: if you don't have the ressources of Sony/Microsoft... you need to use your brain Roll Eyes
Offline OverKill

Junior Member




Java games rock!


« Reply #14 - Posted 2004-08-23 09:33:20 »

Dunno if this has been said yet but there are quite a few games out there that do not have centralized servers.

For IL2 Sturmovik f.i. there is the HyperLobby which is basicly a matchmaking server.
One person "hosts" a game and then waits for people to "join" (all virtual) and when enough people are in the tool tells the game on the hosts PC to start a server.
Offline aldacron

Senior Member


Medals: 9
Exp: 16 years


Java games rock!


« Reply #15 - Posted 2004-08-23 20:39:09 »

Quote
Dunno if this has been said yet but there are quite a few games out there that do not have centralized servers.

For IL2 Sturmovik f.i. there is the HyperLobby which is basicly a matchmaking server.
One person "hosts" a game and then waits for people to "join" (all virtual) and when enough people are in the tool tells the game on the hosts PC to start a server.



The lobby server is a central server for everyone who plays it. The host server is a central server for everyone in the host's game.
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.

CogWheelz (18 views)
2014-07-30 21:08:39

Riven (25 views)
2014-07-29 18:09:19

Riven (15 views)
2014-07-29 18:08:52

Dwinin (12 views)
2014-07-29 10:59:34

E.R. Fleming (33 views)
2014-07-29 03:07:13

E.R. Fleming (12 views)
2014-07-29 03:06:25

pw (43 views)
2014-07-24 01:59:36

Riven (43 views)
2014-07-23 21:16:32

Riven (30 views)
2014-07-23 21:07:15

Riven (31 views)
2014-07-23 20:56:16
List of Learning Resources
by SilverTiger
2014-07-31 18:29:50

List of Learning Resources
by SilverTiger
2014-07-31 18:26:06

List of Learning Resources
by SilverTiger
2014-07-31 13:54:12

HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54
java-gaming.org 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‑gaming.org
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!