Search Unity

Unity, MMO's, Middleware, Servers/Clients

Discussion in 'General Discussion' started by Trackpants, Mar 11, 2012.

  1. Trackpants

    Trackpants

    Joined:
    Jan 5, 2012
    Posts:
    217
    Oh look, another one of "those" threads ;)

    Been doing some quick reading about Unity and MMO's. The consensus was that Unity can not scale to an MMO form without a middleware or custom server back end. So this is a discussion, that I'd like to start off with a few questions, which I'm sure are going to be highly opinionated.

    First topic: MMO's and randomly generated dungeons.
    I know that it is possible, due to realm of the mad gods, but it seem's that all of their dungeons are generated by the server. I was wondering if it would be possible to do some sort of half server half client approach to it. Such as, having a city/town (basically a lobby) hosted by the server, then having each client generate and host the dungeons. But as well as that, having each dungeon being authorised still (movement damage controlled by the server).

    Second topic: Servers and Clients.
    Now at the beginning I thought that both the server and clients would have to all have the same assets, which by now, I've figured out is wrong (hopefully? atleast when it comes to unity client/server with middleware). At first I thought it wouldn't be too hard to have a client and server using just unity, having the clients log into the server through a small personalised part of an SQL databse. So client > server > SQL > server > client. But, I couldn't really figure out a reasonable way to use unity as the actual server, keep in mind that this solution would be for a much smaller scale, with server's distributed to consumers (perhaps alike to the Minecraft server setup).

    Third topic: Middleware
    So I finally started looking to middleware, read a few stories about peoples experience etc. uLink, is apparently the most easily implemented into unity middleware. But what are the pros and cons of all different middleware. Do they all offer the same functions with different API's. I've heard that photon doesn't have knowledge of Unity's collision and physics, are SmartFox Server and others the same? How easy to use are these in comparison to Unity's built in Networking (Which I believe if RakNet?)

    So yeah, a lot of questions/things to discuss, keep in mind, I myself am not going to try and create an MMO anytime soon, hopefully what I'm going to achieve, over the next 2-5 years, is a small co-op/online RPG experience. Which to be honest, I'm going to be developing more for me and my friends, rather than consumers as well as a learning experience.
     
  2. npsf3000

    npsf3000

    Joined:
    Sep 19, 2010
    Posts:
    3,830
    1) Yes you can have randomly generated dungeons.

    Whether you do it on client and server depends on your judgement of the tradef-offs. I personally like to keep everything as secure as possible by default and therefor would generate them server-side.

    2) You can share assets, or export assets in a format the server understands depending on your architecture.

    3) There a re a lot of different middle-wears and the range of features/paradigms they present is quite diverse.

    To be honest, the topic is so huge and generic you need to do some reading up on it as a whole, then research options regarding how to achieve your particular goals.
     
  3. keithsoulasa

    keithsoulasa

    Joined:
    Feb 15, 2012
    Posts:
    2,126
    Here's a very very dumb question , can you do a MMO without any host, kinda like a web of connected clients .
    IF this is possible( I don't think it is) then this year when more powerful phones come out we could get some nice driod MMO's
     
  4. keithsoulasa

    keithsoulasa

    Joined:
    Feb 15, 2012
    Posts:
    2,126
    Without massive serverside cost!
     
  5. TylerPerry

    TylerPerry

    Joined:
    May 29, 2011
    Posts:
    5,577
    If you made it do that, but if every one turned ther phones off, a black hole is going to open up and engulf the game?
     
  6. Morning

    Morning

    Joined:
    Feb 4, 2012
    Posts:
    1,141
    Well you can do a peer to peer MMO but you'd need to write the managing systems yourself as there is no such thing on the market. Neither do I see any reason to use such a system. Cheaters will be running all over the place, people will lag terribly, chaos will ensure. IMO not worth the hassle of making such system.
     
  7. npsf3000

    npsf3000

    Joined:
    Sep 19, 2010
    Posts:
    3,830
    Then you fundamentally misunderstand the cost aspect of MMO's.

    At a guess I'd say 10~30% of a random MMO's cost is network related, with 10~30% of that being hardware licenses.

    Hardware is cheap - it's the dev time, server admin, testing etc. that's expensive from a network POV. By going with P2P architecture you're reducing the usage of the cheap item and drastically increasing the usage of the expensive one.

    Not Smart Business.
     
  8. sybixsus2

    sybixsus2

    Joined:
    Feb 16, 2009
    Posts:
    943
    I'll admit I have zero interest in MMO games, and hence little knowledge, so this may be a stupid question. How are you increasing the cost of server admin by not having any servers?
     
  9. Dreamora

    Dreamora

    Joined:
    Apr 5, 2008
    Posts:
    26,601
    You still need servers, even if you go with something like Badumna that (mis)users clients as intermediate servers, you need central servers. Even for games like BF where no central server exists at all for playing there is one needed for persistence over the different realtime endservers.

    And those need to be maintained, the less such points you have, the more mainteinance and optimization will be needed as the same amount of load will hit less nodes (-> does not balance out as there is nothing to balance to)

    Also the cost estimate is omiting the most expensive part: if people pay you, you are expected to offer support, hence need a support team and that will be what costs a lot of money, its normally the 3rd largest block of costs after 1. ongoing development (MMO development is developing to service, its not game development as such. You will have the majority of effort post launch, not up to the launch, as you need to keep and grow your userbase - don't do anything there and your game will be out of the picture within months at max as dozens of multimillion USD MMO projects have shown in the last years, just look at SOE and NCSoft titles which widely failed to failed misserably) 2. server maintenance, hw and traffic costs
     
  10. sybixsus2

    sybixsus2

    Joined:
    Feb 16, 2009
    Posts:
    943
    Sure, if you corrupt the question into a completely different question, you can find a way of covering yourself but that wasn't the question.
     
  11. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,822
    Well firstly, that would be one MMO ripe for cheating, so would probably never happen.

    Secondly, there would be no persistence. What happens when a player disconnects? Where would his stats and inventory be stored? Locally? The issue would be more with world persistence, for example killing a boss, or picking up a piece of gold. Or spawning NPCs.. none of this could really happen in peer to peer. Unless the peers themselves spawned NPCS.. but that just sounds like fail architecture.

    You 'could' do a peer to peer MMO without a server but it would extremely limited. Offering only PVP as a viable option.
     
  12. Morning

    Morning

    Joined:
    Feb 4, 2012
    Posts:
    1,141
    Why couldn't you spawn your own npcs? Sure it's easy to cheat but why not? PVP would be useless too as you could cheat your stats anyway.
     
  13. Meltdown

    Meltdown

    Joined:
    Oct 13, 2010
    Posts:
    5,822
    If I as a peer spawn an NPC, then the other peers would need to see this NPC too.
    Then what happens if I disconnect? All the NPC's owned by me would dissapear off all the peers screens.

    i.e FAIL

    PS : It might work for a Ghost Busters MMO, where things vanish in the neighbourhood
     
  14. Chris-Clark

    Chris-Clark

    Joined:
    Jan 16, 2012
    Posts:
    130
    You misunderstood what he said, and asked a question that was off track, he explained it further and you then acted like a dick.

    Don't be a dick.
     
  15. npsf3000

    npsf3000

    Joined:
    Sep 19, 2010
    Posts:
    3,830
    By trying to manage tens of thousands of 'player' servers that may or may not drop out at any time, that have a myriad of connection issues, and may or may not be hacked or part of a large hacking effort.

    Etc. and so on.

    Ultimately it does depend on how you set it up - by don't think for a second that anything will happen magically.
     
    Last edited: Mar 11, 2012
  16. Ensane

    Ensane

    Joined:
    Jul 13, 2010
    Posts:
    221
    I use Badumna and it works quite efficiently...

    its a hybrid solution... First you can use a central server for persistence. Storring character data etc and replicating to the local client when a user logs on...

    The as far as npcs go you can host on your own unity based server then offloading a certain percentage onto clients that come within range. The system is set up so that if a player is hosting one npc if he disconnects it has a backup client to migrate to or will migrate back to the server... All this goes on with minimal hitch...

    As far as cheating goes they are working on a new system called.distributed validation... Basicly you can designate peers in the network to host a entity for a client... That client then sends input to the validator and validator replys back in the same fashion a simulated authorative server would. Accept these calidators can be other players or hosted by your servers...

    Im developing a system that rates clients and matches them with validators... If none are matched then the server will spawn a validator. You are getting alot more from this then just saving valuable server resources... Think about the possibilties... You can create single sharded worlds lush with animals, other networked objects with minimal cost.