Advertisement

I want to make a simple multiplayer game

Started by August 13, 2015 03:07 PM
22 comments, last by timothyjlaird 9 years, 5 months ago

What other games have you made ? Have you made pong .. a simple multiplayer game !

You should try making pong, and I don't mean a quick and dirty ... hey look i did it in 100 lines of code. ez. I mean do it real well, with proper physics, and networked play. Such a simple game, but you will get a feel then for how to do something more complex and yet still tackle many problems.

I can make these characters fight each other on the same keyboard... that's not the issue.. pong wouldn't help me

Advertisement

So you're saying that when I play a match of Halo that all the player's positions are simulated? I'm sorry but I don't believe that.

Easy way to find out, bud. Do it yourself.

The positions are extrapolated because the software on your computer updates every loop. On your local machine the graphics, physics, etc are updated 30 frames per second (or whatever your framerate is). However, the data from the internet is not. Maybe you get new data from the internet 3x per second. The number of updates per second depends on the connection speed. If you are only positioning your enemy data 3x a second, they will appear to jump around.

If you're really serious about learning multiplayer, start with the basics. Make a peer-to-peer chat program. It's the most basic way to understand sending and retrieving data. After that, try putting a server in the middle. Maybe put a cuss-word filter on the server to test out trust/verification methods. Then try some simple turn-based style of game. After that, try moving into real-time game styles.

If your serious about doing multiplayer, you'll find people willing to help out IF you show you're willing to do the work yourself, but it's really not the easiest place to start.

I don't agree with anyone who says my plan is any more complex or simple than a game of pong etc. I think my idea is very simple in fact and I don't see any reason why I should drop what I know to learn something else.

I can make these characters move and shoot... I just wish I had a script that would give players control of specific game objects when they connect to the server. Maybe I could buy a script for $100.


I don't agree with anyone who says my plan is any more complex or simple than a game of pong etc

Then you are wrong.

Multiplayer is a lot more difficult than you think it is. You came here asking for advice, so I suggest you take the advice you've been given. People here know a lot about making all kinds of different games, and I can tell you without a doubt that if your game has multiplayer in it, it is thousands of times more complex than a simple Pong game.

But if you still think it's so easy, and that we all don't know what we're talking about, feel free to ignore us all.

Hello to all my stalkers.

Here's a script I have so far it is for a character that moves/jumps/shoots/gets hit and takes damage/dies/respawns. I don't have the translate set to any specific vectors because I'm not sure what x/y/z are in the series nor am I sure how big the integers have to be. Its also not for any specific engine.

http://pastebin.com/CiqVK9Z4

I want a script that will connect the clients to the server and give the players control of certain game objects.

Advertisement
Hi. You will need to use some network library. I can't see a script running a whole system.
You will need a server to do nat punch through or no one can connect to you.

And simple networking don't go together. Simple 2 ports connected no error handling. Some things going to go wrong there.
Your going to have to spend some time in looking up networking. It's not all glory and gold.

I mean like how much could I pay someone 1. to take my script 2. revise it for an engine 3. make a script to connect the clients to the server and give the players control of characters with this script attached to it 4. revise my same script again to work with the multiplayer script

I mean like how much could I pay someone 1. to take my script 2. revise it for an engine 3. make a script to connect the clients to the server and give the players control of characters with this script attached to it 4. revise my same script again to work with the multiplayer script

The likelihood of someone laying down a dollar figure for you is highly unlikely. Even in your 'step 1'; you don't acknowledge what really needs to be done, which communicates to anyone reading your post that you don't understand the full scope of what you're asking for.

I don't have the programming knowledge most people here have, however I will say that you should take a step back and realize that most of your post you've asked for advice and then promptly disregarded almost all the advice everyone has provided. What you need to do is understand the full scope of what needs to get done, and then ask for help on the specific pieces of what you need.

Simply asking for someone to 'turn my game into a multiplayer game' will not cut it.

I apologize if anything comes across as harsh, I honestly just want to help you find the Root Cause of the problem you are trying to solve.

Good luck.

You still have not explained what platform/engine/language you want to work on. Im assuming you are using either Unity or UE4 because you also copypasted this same question on their forums.

What is your goal, both short and long term? Do you just want to have a worminator clone and then your done with gamedev? Or do you actually want to learn gamedev (which includes programming, understanding how things like multiplayer work, and reading lots of documentation and tutorials to figure out how stuff can be done)? Im going to assume the latter.

If you are using an engine to do the game, you can implement multiplayer in three ways:

A) Use the programming API to do it. This means being a decent programmer, knowing how networking/multiplayer works, and being willing to implement all the details to make it work.

B) Figure out if there is a built-in feature or some downloadable addon/plugin in the engine to set up simple multiplayer. Maybe there is, maybe there is not. It depends on the engine. This requires some googling and research.

C) Get someone else to do the work for you. This means either paying someone, or maybe finding another game and looking how they did it.

Note that figuring out how to do it is difficult if you dont know the specifics of what you are even trying to do. This is why learning how networking/multiplayer works is a good idea. And learning how to program from the ground up (text based games etc) is good, it helps you understand faster.

My suggestion is dont use an engine. Pick your programming language, and make a text based (or 2D if you already did that) game. Add multiplayer when you are ready to research into it.

When you want to transition into an engine, read the documentation for that engine, watch tutorials for it. Figure out how the engine works, how to best make use of it. Many things require programming to do. Then you use programming. If you dont know how to program a thing, research it. Lots of googling, lots of reading API documentation, lots of trial and error.

This will take time, but is the best path if you want to program your own games. If you dont want to program (you only want to lets say make 3D models or design levels), you need to find a team to work with, but even then, knowing how to program is useful.

As to your original question:


... but I don't think I can figure out the multiplayer. I was wonering if someone could just show me a simple way to make a game where the players can connect the host and be given their character.

This is impossible to answer well without knowing what platform you are working on. This is a very specific question, since multiplayer works differently for every engine, language, API, and game. We are going to assume you want to use programming to implement multiplayer. The way it works in programming is that you use a networking library or API of some kind to send information between machines. If you know programming, that (and google) is all you need to know.

Next time you ask a question, tell what tools you are working with (engine, programming language, whatever) and what have you tried so far (research first! google, tutorials, documentation...) and what obstacles you couldnt overcome.

o3o

This topic is closed to new replies.

Advertisement