Photon or UNET?

I was a bit unsure where to put this however it seems more at home here, under game design.
(TL,DR what should i use if I decide to create a multiplayer game, Photon or UNET?)

Here is my dilemma,

So I, a minimal experience coder (1/2 - 1 year in coding classes at OSU and my own scripting/Unity game tutorials), and my partner, a medium experience modeler/animator (3-3 1/2 year experience with Blender & Maya in personal projects and jobs) are looking to make a game (we have never created a complete ā€˜game’ before this point outside of simple tutorials).

His side of things are fairly open however mine are not due to my lack of experience. Under these conditions, which is the better/more user friendly networking system to get started with, Photon (https://www.assetstore.unity3d.com/en/#!/content/1786), or UNET (http://blogs.unity3d.com/2014/05/12/announcing-unet-new-unity-multiplayer-technology/)?

Again, I have a low amount of experience however I do have free time and want to learn.

Also side question, should we avoid multiplayer altogether or is it simply more work for new developers?

Thanks,
S&R

I can’t answer your primary question, but to the side question, yes, as newbies you should certainly avoid multiplayer altogether if you can. It increases the complexity and difficulty of your project substantially, and your project is already at high risk of never being completed, just because it’s your first one.

So, list all your excellent game ideas, and then pick the reasonably exciting one which is the simplest, easiest, fastest to develop. Stay away from Call of Duty or World of Warcraft, and instead think Flappy Bird or Cut The Rope. One player, simple mechanics, simple art… that’s the idea you’re looking for. Go do that first, and save your more complex ideas for later!

1 Like

Well if im being honest that answer is about what I expected when I began typing my primary question. However, (to anyone else reading this) I still would like an answer to my first question for future reference.

Thanks

I can’t answer your question, but I think when UNET is complete, it will probably be easier to use and implement. That said, it is complex. You have a lot of things you can do and learn before you need to worry about multiplayer, UNET or Photon. By then, it will be out, you will be more experienced and a lot wiser.

Then make your game multiplayer. :slight_smile: Honestly, if I had to make a Flappy Birds game, I would toss Unity out the window. If you are going to spend the next two years making a game, it better be something you really want to make. Especially if you are not doing this as professionally but as a hobby. Enjoy the journey. :slight_smile:

1 Like

For people who have experience with Unity I think UNET is pretty simple once they get into it (it’s always takes time to get used to new API’s).
I think if you put some time in learning it you should be able to make for example a simple multiplayer fps.
I haven’t tried photon, so I can’t talk about that.
I personally use my own networking implementation, simply because I like to have control over it.

As for avoiding multiplayer games altogether, well it depends. If you are bad at programming at all then you shouldn’t even try. But if you’re a decent coder it wont hurt you to spend few hours making for example a game with 2 character controllers in it, simply to see if you can implement some basic multiplayer functionality. If it works then go for it, if not well try again once you improve your skills.

Oklahoma State or Ohio State or Oregon State… IN ANYCASE.

It really comes down to your choice I think, the new UNet looks very promising, but is new.
Photon has been around for quite some time now, but may not offer quite the unity integration that UNet might?

As for difficulty, one of the first things I did when learning how to use unity and program in unity was create a simple matchmaking system. It was with the old basic unity networking api, but I learned a good bit about how to code in unity through doing it. The new system looks to be much much much much less complicated and more efficient. SO I guess what I’m saying is however you choose to make your game, go with your gut feeling. If multiplayer will be the basis of the game, be sure to do your research and learn how to do it right, no one likes half done games!

lol… I was wondering the same thing…

I would tend to agree with some of the others are saying. Coming into Unity, there is a TON of stuff to learn. Unless you already have a good understanding on how the games work on the inside, I’d recommend doing a first game as single player in order to get familiar with how everything works. Kind of a crawl before you walk and walk before you run philosophy.

Plus, to be honest… I think there are a lot of changes going on right now in the networking arena for Unity to really make a well informed decision. uNet is still young. Will Unity truly develop it to the potential we hope, or will they drop the ball? Forge is a new networking platform that was introduced in the past few months that shows potential, but will the developer continue or will they fade out as the case was with MassiveNet? Bolt is showing some renewed potential now that Fholm has partnered with Photon but a lot of questions still remain there. Even Photon and … crap… brain fart… the name of the other network option slipped my mind… Think it is another U name… Or maybe not… lol At any rate, even both of those have their question marks.

So taking the time to make a single player game and maybe at least tinker with some of the options to get a feel for how they work and the basics of the networking setup might be good. They are all very similar in the guts. So tinker with uNet (since it is free)… But doing single player as your first game will really help you dig in and learn the core stuff before throwing networking in on top of it too.

And back to the quote… If your OSU = Ohio State, we are practically neighbors… :slight_smile:

Thanks for all of your advise. Its kind of what I already knew but as someone relatively new to this I wanted a 2nd (more experienced) opinion. I think I will take the advice more of you gave and go for a single player game of some description first as I am not confident enough in my coding skills or my knowledge of Unity as of this moment. My partner will be less than thrilled to hear this as he was hyped to start working on a multiplayer game but it is probably for the best. Going to need to skype him and brainstorm a new game-plan (literally >D).

Thanks again for your advise guys,
S&R

(Oh ya, and its Oregon State, lol I always forget that there are 3 "OSU"s)

2 Likes

Definitely UNet. I’ve used both Photon and UNet. UNet is much better intergrated with Unity, and requires much less specialist knowledge to get working.

1 Like

Don’t you have to pay out the eyes for Photon? I’d go with UNET for that reason alone.

Does UNET require the Unity Multiplayer service?

Not that I am aware of. I have a dedicated server running on my work computer. Games create all of their content locally but inputs are sent through the server to dummies in other people’s games. That’s how I’m doing networking :smile: It’s beautiful.

I plan to learn how to host a dedicated server system that can spawn new servers as more players connect. Not sure how that works with IP addresses though. Do I need 1 master game that sends people to other IPs? I almost went to UE4 just because the networking there is a lot easier to manage… but I felt like I’d run into the same issues when it came to running servers.

1 Like

Currently this is just a matchmaking service. The actual server runs on one of the clients. Once the game is made there is no need to use Unity Multiplayer. And as @Tomnnn points out, there is no actual need to use the matchmaking service if you wish to manage this on your own.

Unity Multiplayer is listed as ā€œfree while in betaā€ which strongly suggests you may need to pay for it at some point. I would imagine it will follow the same payment model as most other services. Free until you hit a certian CCU.

2 Likes

I also think this is very likely. I wish dedicated servers were more obvious. We shouldn’t have to rely on things like photon and spend $3500 per game (for the license, server costs not included) just to have dedicated servers.

That’s exactly how UNet’s matchmaking service works.

And I’ve already researched the topic of spawning more servers. I found that the simplest way would be to have a c# app on your machines that you would tell to start another instance of your server.
Why have multiple servers on your machine? Because of the single-threaded nature of unity.
Why not have max number of servers to start with? Because some of them might not have any players and are running idle, which causes lower performance on the highly populated server.

Correct me if I’m wrong.

1 Like

How does this work with IP addresses though? If players in the first server connect to, say, 192.168.1.3 then what ip to players in the next server connect to? I don’t know anything about networking besides how RPC and Command functions work.

Each server for the majority of games I plan to make in my lifetime will probably have less than 20 people with the max being 4 :smile:

@Tomnnn I’m unsure if this is possible with UNet. I use raw sockets for everything.
My idea is that game servers send to master server the port that they are using (port is assigned by OS), you don’t have to send the IP because all messages include IP anyway. So the master server can just give that ip and port number to clients, so they know what they should connect to.

I don’t have enough knowledge of UNet to tell you how to implement this with it, but if your game servers can connect to your master servers as clients you should be able to send a RPC to master server telling it how to redirect clients to that game server. You should probably consult the scripting reference to see how this is done.
The principle is basically the same either way.

So the servers can run on the same IP but each have a different port? I don’t think there would be an issue in sending clients there or setting up games to use different ports, just clueless about basic networking :slight_smile: