Advertisement Jump to content
Sign in to follow this  
faraa

Start game networking.How ?

This topic is 1866 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi everybody

I am a beginner and I have some knowledge of programming with java(specially applet) ,python,c++.

I want to start game networking.

But I really don't know how and what shoud I do.

I  read the post with title "Get Instant Answers To Your Questions!" and other topics but I really didn't understand what should I do.

I don't know which language is better.

I don't know how I start ? with learning game programming or with learning network ... or together ? 

If theare is any related topics can you give  me a link address?

Or can anyone introduce to me a good ebook ? 

.

.

.

I just to know how should I start...

Thank you so much...

 

 

Share this post


Link to post
Share on other sites
Advertisement

Don't start with network, u will be doomed to not finish anything. First try make simple games. Tried to make some 2d games? Maybe try to do game for 2 players on one PC? 

All languages is good, because you just need to make game, not marry one of language and live with it. Try all, and look what is best to you ;) I tried networing with C++, and that was hard. Now made simple 2d movement over network with C# + xna + Lidgren.

And for end: game programming is hard. Don't try to make best mmorpg with alot fun stuff and so on. Make simple games, which you can finish easy. By taking big project, you doomed to fail. I know, i have gone this path... ;)

Share this post


Link to post
Share on other sites

Pick the language you like the most. Out of the languages you listened:

- Java: no ideas, never used.

- C++: if you have a good understanding of struct and how the memory is organized (bytes information), stick with C++.

- Python: sending binary data (which you should, string protocols are not efficient) with python is not intuitive at all - considering the average python program. This can be a bit hard if you don't have a good understanding of how the data is packed in the memory.

 

My advice is start creating a simple local game that you can only move the character around.

Then change it to move it in a client-server

If you are using python, start by sending/receiving strings, then move to a string protocol (Client sends: "MOVE UP", server process position and answers the coords "10.15, 5.45", for instance) and finally use the struct module. I have a simple class that simplifies the use of the struct module (I have used it in some games experiments I have made), I can share it if you want.

Edited by KnolanCross

Share this post


Link to post
Share on other sites

From a different angle, this is how I figured out networking in its most basic form when I was 10 years old (so it must have been simple):

 

I used C++. What I did was tinker with previously created codes and reviewed APIs until I was able to create a simple Instant Message program between two people. Once I finished that, I created a multiple-user chat server. This is the same concept as how you ought to begin networking for games. Think of every chat message as a command from the server to the client, or vice-versa. When the command is sent from the server to your computer, the client, such as a command called say "damage20", then your client should be able to take this command and interperet it, removing 20 health from your user, and then send a command back to the server to let it know that the command has been executed.

 

This is a VERY basic understanding of networking in games. If I were you, I'd look up C++ Networking, or C++ Sockets, or C++ Chat. You could use Java as well for this, depending on what your are trying to accomplish, and you can also program the server in a different language than the game is programmed in. The important part is that you send and receive commands and can connect/disconnect to and from the server and client.

 

I hope this helps.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!