Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Online Subsystem and Sessions WTF

I am trying to wrap my brain around the Online Subsystem and I thought Shooter Game would be a decent example. However all I seem to be doing is getting utterly lost. I've look around at a few tutorials and my game scenario is that you can play single player or join a dedicated server to play online. Your machine will never be the host.

Similar to the Shooter Game I created a new GameInstance and GameSession class. From what I assume a build dedicated server will call RegisterServer when it comes online. Within that function it will create the GameSession. The thing I do not understand is the GameSession never seems to be created on the client, and yet the GameInstance performs operations such as Searching and Joining through the GameSession object. The GameSession even has functions for Hosting, Finding, and Joining Sessions. In another tutorial I have found those same functions are on the GameInstance, which makes more since because GameSession object would not be created in a non dedicated server build.

I'm pretty sure you need to create a GameSession on the dedicated server, I'm not sure why the GameInstance on the client needs/uses the GameSession when one would not be created... am I missing something?

Product Version: UE 4.21
more ▼

asked Nov 23 '18 at 07:33 AM in C++ Programming

avatar image

454 32 25 55

avatar image ArcainOne Nov 29 '18 at 07:59 AM

Okay, this one was a late night rant really. I'm still not sure how this works or if this works in the Shooter Game but I've decided to just ignore it. Basically what I have done is have Session Creation, Startup, and Destruction be Handled by the Custom Session for my game. GameInstance Handles Finding and Joining Sessions.

(comments are locked)
10|2000 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question