Announcement

Collapse
No announcement yet.

Networking - having a server not be Unreal?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Networking - having a server not be Unreal?

    Hi!

    I am currently working on an RTS game. This RTS needs online multiplayer.
    Currently, nothing in our game needs our servers to know anything about Unreal. Our clients would only use Unreal as a graphical interface while all the game logic would happen server side. The clients would populate and/or move objects in the world based on data given from the server.
    I've previously done some networking with Winsock API, but never touched networking in Unreal. What's the easiest way to set up so that the client can just send and receive messages quickly? I've looked a bit at Third Party Socket Service Connection (https://wiki.unrealengine.com/Third_...ver_Connection) since this wouldn't require any replication (which I really don't think we need). Does this seem like a feasible idea? Is there something I should avoid if trying this?
    I've looked a bit at the Unreal dedicated server as well, but since we don't want replication or any built in physics calculation or so this seems like overkill.

    Also, does anyone have any insights into an easy to work in framework to code the server in?


    #2
    Yes, it's feasible, probably not even that complicated, assuming you're already decided on which data to send and to whom. I've worked with sockets, socket subsystems and, most of all, the NetDriver class, for my own plugin, for months. If you don't need any replication and your server-authoritative stuff is lightweight, bonus points for you, because that link you posted seems sufficient.

    Regarding easy frameworks, I'm probably going to sound a bit subjective here, by indirectly and unintentionally appearing to be advertising my product, but Steam has a dedicated Networking interface ( https://partner.steamgames.com/doc/api/ISteamNetworking ) which handles NAT traversal quite reliably as well. It has 2 sets of functions: old/new. If you use the new ones (noted in their comments), your work should almost be a walk in the park.

    Also regarding frameworks, I've heard good things about Photon, GameSpark and GameLift, but I haven't worked with either yet so I wouldn't know what to advise on that.

    Comment


      #3
      Thank you so much for the reply!
      I'll check those frameworks out!
      Do you have to use steam servers to use that framework?

      Comment


        #4
        No. You can base your code on the engine's built-in Steam module and follow their "Getting Started" guide to setup 2 callbacks and that's pretty much it. Then you just decide on your own protocol (i.e. server listens on channel X and replies on Y so the clients will always know to do the opposite).

        Edit: Internally, it is using Steam's relay servers for NAT traversal, but you have nothing to do with those.

        Comment


          #5
          We use FSockets for a variety of things and have had no problem.

          Comment


            #6
            Depending on scale of things, Photon my be a very good option as well.
            | Savior | USQLite | FSM | Object Pool | Sound Occlusion | Property Transfer | Magic Nodes | MORE |

            Comment


              #7
              Shipped 3 projects already with this engine and TCP for networking. TBH its simpler than Unreal replication.

              Comment

              Working...
              X