Eugen Jung
Member
- Messages
- 31
- Reaction score
- 0
- Points
- 6
.
Last edited:
Any control that the server cedes to the client opens the door to cheating. You can reduce this by encrypting communications using public-key cryptography, embedding credentials in your clients and only distributing them as binaries, but if you'd ever consider releasing this (and not keeping it as a research project), someone will crack the credentials if it gets popular enough and write their own client.This is my proposed method (not sure if it's already in use or will even work):
- ...
- The client processes the physics for itself ONLY, and transmits it's new location & orientation to the server.
- ...
On any host, you'll likely need a VPS since you want to run a custom server.Firstly, what kind of hosting would I need for this? Would I need a dedicated VPS?
Note there are two different concerns here: data storage, and data access/interchange.Secondly, how would the uploading/downloading of player info work? Remote SQL? What is most efficient? An actual program running on the server which stores the info in the memory, or something more like a simple database (SQL?) that the client programs can access?
The clients connect to the server the way any client does: TCP/IP sockets. The exact details vary from platform to platform. Some platforms (such as Java) offer abstractions, so you can treat network connections as an I/O stream, just like files and consoles. If you have to work at the socket level, there are books and webpages that can show you how. It doesn't have to be a terribly large topic, though if you want to really get into it get Stevens et al.'s Unix Network Programming, Volume 1. For Windows, see the Windows Sockets 2 section on MSDN. Back in college we used the slim Pocket Guide to TCP/IP Socket Programming in C (the authors have also published a slideshow on the book's site that ties in to the first to chapters).And thirdly, how would the above be implemented? Are there third-party libraries for this kind of thing? How does my program connect to the server? Do I need to worry about ports? Is there a cross-platform way to do this?
Any help at all - even if it's just a link to something I might find useful - is greatly appreciated.
I'm working on a program for a research project (let's just call it a game, for the sake of simplicity).
The "game" is a standard stand-alone program, not an online browser-based game. It is a simple 3D world (think Second Life). So far so good.
Now the problem is that it also needs to be able to allow people to interact with each other within the game (think World of Warcraft). I don't know much about these kinds of game, as all my previous work has been single-player. Unfortunately, I am the only game developer on the research team, so it falls to me to create this "game".
I believe that a common method is:
The disadvantage of this is that the server can't handle many players.
- The client connects to the server and adds itself to the list of players.
- The server creates the required elements.
- The server processes the physics for each player, and transmits the current location & orientation of every player to the various logged-in clients.
- The client renders the scene.
- Repeat from #3.
This is my proposed method (not sure if it's already in use or will even work):
This means that the server will be able to handle many more players because all it needs to do is supply the client with the location/orientation of each player, and the client program will do the rest.
- The client connects to the server and adds itself to the list of players.
- The server creates the required elements.
- The client requests a list of players along with their current location/orientation.
- The client renders the scene.
- The client processes the physics for itself ONLY, and transmits it's new location & orientation to the server.
- Repeat from #3.
However - as I've said - I have no experience with this sort of thing. (I should mention that I'm developing on Fedora Linux, using C++ and the Bullet physics engine.)
Firstly, what kind of hosting would I need for this? Would I need a dedicated VPS?
Secondly, how would the uploading/downloading of player info work? Remote SQL? What is most efficient? An actual program running on the server which stores the info in the memory, or something more like a simple database (SQL?) that the client programs can access?
And thirdly, how would the above be implemented? Are there third-party libraries for this kind of thing? How does my program connect to the server? Do I need to worry about ports? Is there a cross-platform way to do this?
Any help at all - even if it's just a link to something I might find useful - is greatly appreciated.
Thank-you for your time.