Making a multiplayer game

I was wondering If someone could tell me how to make a game available to not only me but also my friends. More specifically I made a fps game and It is where the player shoots and kills zombies. I was going to try to make it so that a second player could join (my friend) on a different computer. We then can battle the zombies together. I have tried to find tutorials and I did but they are outdated. I am not experienced with python and if it involves an overwhelming amount of python I would not be able to wright the code myself (im only 11) If anyone could tell me how to do this that would be great
(If it involves alot of python please tell me what i would need to accomplish with it and I will search up tutorials on that)
Thanks in advance!

Also if anyone knows an open discord of inexperienced game designers please tell me it would be great to have multiple resources to answer my questions

If i was not specific enough in the first post this is more bold of what I want.
-I have one player and zombie spawners.
-I would want a second player to appear when he joins, but if he has not joined there would be no second player.
-Everything about the game stays the same except the fact that there are two players trying to kill the zombies.

Tell me if you need more information
or the blend file so you can test stuff out.

If you know a tutorial please also post the link to that! It would help me very much!

network multiplayer is a complex thing. dont expect a drop in solution. im an experienced python coder and im even intimidated.

much simpler would be a split screen with 2 game controllers, but still a significant amount of python is still required.

ok thank you very much, just to be sure do you mean two people at the same computer?
Also I made the game with logic bricks so i have keyboard sensors, would I have to redo the keyboard
sensors with something else because it would be using controller?

sharing a keyboard isnt that ideal, been there done that.

you need to use the joystick sensor, id is the gamepad to use. 0 for pad one, 1 for two, etc.

there are split screen scripts out there that should be relatively easy to use and drop in

1 Like

Thank you so much, I’m very inexperienced and you have been very helpful

Is there a way to make the game downloadable not multiplayer, so my friends can play the game singleplayer through there own computers

just the way game engines are, the default is to run as an isolated instance. read: single player.

all you need to do is enable the addon “export game engine runtime” (not the publisher). then once you have a working game, go to File, Export, Game engine runtime. Tip: be sure you export into an empty folder, otherwise it will be a mess.

be sure that copy python and copy dll is ON the first time you export. any time after, you dont need those if you just want to update an existing game.

i should mention @wkk 's attempt at making an online fps zombie shooter. this guy makes me look like nOOb. :sweat_smile:

1 Like

i think that should invite to the blender discord where there is a bge and help-bge sections. there is also an upbge channel which @BluePrintRandom can get you an invite.

upbge is a variant of bge with more modern features and advancements. even if you dont want to use upbge yet, im sure they would welcome you.

thank you so much, I have already used the game engine runtime method, but I didnt know how to use it efficiently! Thanks!

last night I exported it yet all my textures turned pink?? Is there a solution for that?

Is it possible for a template of an online server and then I can append my game into it?

It is possible to do, but truth is there might be no such resource at all.

I was able to find the following projects:

But I don’t know if any of these links will actually help.

In theory, it would be possible to create some generic Python Component or some “Master Logic Controller” on the client side, and have some kind of server somehow tracking entities.

Why is it not done? Because it is painfully hard. By hard I mean that it requires a lot of trial and errors in order to have something working correctly, but it is doable! (I wouldn’t do it though)

So I see some options from there:

  1. Forget about multiplayer in Blender (easiest).
  2. Learn how to program, and work all your way up to writing a multiplayer system (very long, years?)
  3. Keep waiting for someone to make such an add-on (really unlikely, people with that skill-set are doing other things).
  4. Find another way to make games, that would better integrate multiplayer (I don’t know of any engines doing that, I cannot help here sorry).

If you want to laugh, I started on the Blender Game Engine something like 8~ish years ago, a bit on-and-off depending on the years… But it is only now that I can try writing everything required to have a multiplayer game. I guess I must be patient, although I would rather say stupid.

So, I don’t know what you’ll set your mind up to now, but I hope it is clearer for you now :slight_smile:

Either make sure that everything is packed inside the blend file, or that the file paths pointing to the textures are still correct relative to the published executable.

thank you very much, Now i know I wont be doing that anytime soon

thanks! If someone on this wants to look over my file how to I give it to them? do i just drag and drop it in the text box?

Yes, but this isn’t Discord, you can take your time and try things on your side before posting, lol

Look at the buttons in the UI or whatnot, there’s an Upload button.

I’ll leave that to someone else :stuck_out_tongue:

make sure all your textures are in the folder with your blend. the exe is like the blend.

file, external data, make all paths relative. that will make bge look in a similar place for resources.

I just watched this video and It looked too convincing to be true…
He did it all with logic bricks in like five minutes with modules
At the end I saw he had this other thing which was the server so if you guys know what he did at the end with the server tab and who was in the server (if its not outdated) then please tell me cause I have no clue