x

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"

GameMode and PlayerController connections.

Because UE4 currently has no way to pass large amounts of data over the network, I had to create my own implementation using an FTcpListener. Once that is done, then I need to connect the connection to the associated PlayerController. I've currently placed my BigDataNet host class in the game instance so I would only have to do this once. I have a few concerns.

  1. When running a dedicated server, multiple game instances are created and I need to be able to tell which lives on the server.

  2. Are connected playercontrollers persistent. Or do they disconnected and reconnect when the map/gamemodes are changed?

Product Version: Not Selected
Tags:
more ▼

asked Jan 23 '15 at 03:41 AM in C++ Programming

avatar image

MJ_01
822 38 39 241

avatar image Duncan Dam Jan 23 '15 at 04:09 AM

Not sure what u mean on first one, but for second one is not persistent once you load new new map it will be initialized again, but you can use seamless travel to keep player connected and all the information of controller or whatever actor you want from the previous level.

avatar image MJ_01 Jan 23 '15 at 04:13 AM

Thanks. That should be all that I need then. As far as my first question is concerned. I went and looked at the shooter example and think that I need to call a function on the gameinstance from an actor/level that has authority.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

As Duncan Dam said, PC's are disconnected and connected on servertravel ( level change ) unless you use seamless travel ( https://docs.unrealengine.com/latest/INT/Gameplay/Networking/Travelling/#enablingseamlesstravel ).

To tell which gameinstance is Server, use the role check for authority when creating/calling functions:

 if (HasAuthority())
 {
      MyGreatFunc();
 }
 else 
 {
       Server_MyGreatFunc();
 }

more ▼

answered Feb 23 '16 at 09:13 PM

avatar image

Oyand
6 1

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
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