Integrating SF into your project
Let's talk about integrating SF into your own project. You might have already started a project, but like the way SF handles the various different systems included. This guide will take you through migrating, and enabling all that SF has to offer.
Modifying your player controller
Story Framework utilizes a player controller blueprint for its functionality. So if your project does not have one yet, you would need to create one. If you already have this class, open it up and add and attach the following components shown here, (This our found by simply searching for them in the Components hierarchy)

Then, we need to implement the SFPlayerControllerData_BPI
blueprint interface into our player controller by heading over to the "Class Settings" section towards the top of your blueprint, and adding said interface.

With this interface now implemented, open up the Get SF Components
interface function in the bottom left of your blueprint, and add those previously added actor components to their respective references.

Then, we can add SF's Player Camera Manager class from inside the "Class Defaults" section towards the top of your blueprint.

Finally, we need to copy over all of SF's input actions from our Story Framework project, into your player controller blueprint inside your own project (You would remove the Generic Movement
graph if you have your own character movement solution already setup).

On Begin Play logic
A few things must be defined on theBeginPlay
event in any blueprint of your choice. For future reference, I would advise doing this in either the player controller, or player character blueprint.
We need to add SF's input mapping to the player, which can be done by using the Update Input Mapping Context
function. (If you already have an input mapping, you would either need to migrate over your current inputs to SF's SFGameplay_IMC
input mapping context, or remove your own input mapping entirely).

Then, we can add the Auto-Save
function from the SFSaveManager_AC
actor component here too (This is optional).

Character Restrictions (If not using SF's movement)
SF restricts things like movement and camera rotation at specific times. These restrictions should also be set up on your players Movement and Look inputs if you'd like some of SF's systems to work as intended. This restrictions use the SF Movement Condition
function for movement limitations.

And finally, we can copy the SF Camera Look Conditon
graph from SF, and connect it up off of your "Look" input.

Last updated