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"

In which blueprint class should I put widget logic?

As mentioned in the title, I was wondering where i should put my widget logic for menus and such. I was thinking either gamestate or playerstate but I don't understand the differences between them. Any help is appreciated!

Thanks

Product Version: UE 4.20
Tags:
more ▼

asked Aug 24 '18 at 04:27 AM in Blueprint Scripting

avatar image

Matthebest
8 2

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

1 answer: sort voted first

Are you making a multiplayer game?

GameState - is replicated across server and client.

The GameState contains the state of the game, which could include things like the list of connected players, the score, where the pieces are in a chess game, or the list of what missions you have completed in an open world game. The GameState exists on the server and all clients and can replicate freely to keep all machines up to date.

PlayerState - holds data relevant to the player

A PlayerState is the state of a participant in the game, such as a human player or a bot that is simulating a player. Non-player AI that exists as part of the game would not have a PlayerState. Example data that would be appropriate in a PlayerState include player name, score, in-match level for something like a MOBA, or whether the player is currently carrying the flag in a CTF game. PlayerStates for all players exist on all machines (unlike PlayerControllers) and can replicate freely to keep things in sync.

more ▼

answered Aug 24 '18 at 10:18 AM

avatar image

Everynone
14.8k 77 25 62

(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