Hey I’m new to UE4 and I was wondering how I would incorporate choices into part of a game, which will have consequences later in the game?
For example: (Steal the money) or (Leave it).
Thank you.
Hey I’m new to UE4 and I was wondering how I would incorporate choices into part of a game, which will have consequences later in the game?
For example: (Steal the money) or (Leave it).
Thank you.
You can create a couple structs and a data table to help you do this.
ChoiceOption Struct
CharacterChoices Struct
ChoiceOption Struct
-1
)Make a DataTable
to hold the CharacterChoices Struct
. Fill this table with the choices you want available in your game.
In your GameMode
create a new Map of CharacterChoices
variable. On BeginPlay
load the variable with default values of your choices DataTable
.
Then you can lookup the choices in your gamemode’s table, and when someone makes a choice you can set the Index of selected choice
.
If you include the variable in your save data, then this will become persistent.
the general idea behind it is that you take the stuff step by step - and break it to smaller tasks, which you can later learn by order.
for example:
mind, there are many other variations of breaking it down. you should find yours, because there is no ultimate way. good luck with your further development.
Hello, you can use my plugin to create choice based games. It doesnt require blueprint or c++ experience. You just need to create your sequencers and use the plugin to connect them each other with choices. Have a look at it from here;
https://forums.unrealengine.com/unreal-engine/marketplace/1564449-interactive-story-plugin