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"

Struct Will Only Set One Type of Variable from SaveGame, Based on Replication Setting

So I have my GameMode's post login event calling an event in my Player Controller, InitialSetup.


This event, which is set to replicate to owning client, calls a function, LoadSettings, that takes settings (the user's Steam name and integer values representing which character they'd prefer to spawn in as) that were saved to a SaveGame in the Main/Options menus and then sets the according variables in the PlayerInfo structure on the PlayerController.

alt text

Problem is, the PlayerInfo structure will only update the PlayerName OR the Preferred Character ID's, not both. As it's currently set up, with InitialSetup replicating to owning client, the Player Name variable will be set correctly, but the Preferred Character IDs will be ignored. Conversely, if I set the InitialSetup event to Not Replicated, the Preferred Character ID's are set correctly, but the PlayerName is not.

I've done Print String tests and can confirm that all the values are being saved and then loaded from the SaveGame, but when I try to read the same values off the structure where they should have been set, they return defaults.

What do I need to do to make ALL the values stick when setting them in the PlayerInfo structure?

Product Version: UE 4.16
image-121194.png (48.9 kB)
image-121195.png (124.3 kB)
more ▼

asked Nov 08 '17 at 12:54 AM in Blueprint Scripting

avatar image

6 1 2 5

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

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