A good example of UE4 framework implementation?

TL;DR: What sample project is a good example of correctly using each of the UE4 framework pieces in blueprint? (GameMode, GameState, Controllers, Character)

Hi, I’m new to the Unreal engine, and have been working on a small project purely in blueprints. I’m currently having trouble understanding the UE4 framework. I’ve read the documentation at https://docs.unrealengine.com/latest/INT/Gameplay/Framework/index.html, but it does not appear to match up with the samples created by the Unreal team.

For example:

From the documentation - “The PlayerController implements functionality for taking the input data from the player and translating that into actions such as movement, using items, firing weapons, etc”

The two sample projects I’ve looked at so far (CouchKnights, SwingNinja) are detecting all of the player input in the Character, and not in the Controller.

From the documentation - “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.”

Neither example even implements GameState, and instead uses the default base GameState class. The things I would expect to be in the GameState are instead in the GameMode blueprint.

I understand that you don’t always need to implement the full framework for a simple game, but since I’m still learning, I don’t know when those shortcuts are appropriate. Is there a specific sample project that you would recommend that is a good example of correctly using the UE4 framework? Since I’m working purely in blueprints, I’d prefer to avoid examples in C. Thanks.

Diffrence is that character and contoller is that character can die where player controller is always on as long player is logged in. Dont sure about game state and game mode diffrence, i knows strategy demo use game state, i think game state should hold scores and things like that. Keep in mind use of those classes are conventions which you dont really need to follow stricly.

I’ve had the same question - turns out there’s no docs and not even a good example.

Controllers are rarely used for what the documentation says they’re for. Characters often have the input handling, for instance.

In my mind, as long as you understand the systems and make a reasonable attempt at being logically consistent, it’s fine.

As soon as I get there (soon), I am going to post a wiki article on using a FSM to manage game states.

Thanks, I have a general idea of what each class is designed to do but only a general idea. The documentation is not very specific, which is why I was looking for a few examples.

Yeah, even the blueprints don’t use custom controllers.

Let me know if you finish that article, I’d like to read it. I may just take your advice and do what makes sense to me, even if it’s not “right”. I just hope it doesn’t come back to bite me later.