I‘m writing a simple save game system, it uses ListView. This ListView has Entry Widget is called WBP_SaveGameSlot with a button and few TextBlocks.
I’m strugling to find a way to override selected savegame (file). I can click on the button with its name but it happens inside of WBP_SaveGameSlot. I need to pass the slot name to the main savegame widget and set textblock content.
You can create a Game Instance, declare a variable with the slot name in your custom Game Instance and retrieve it from the widget with the node getGameInstance, remember to cast the default game Instance to your custom game instance to be able to get your slot variable.
That’s what it look like.
Saving, loading and deleting work with GameInstance.
SaveButton needs something from the textblock on the left, so I need to click on one of those items which are SaveGameSlots widgets in listView Widget which is in SaveGameWidget.
After a while I came with an idea to redesign SavegameSlot and use its button instead.
I didn’t want to use this before because I don’t want to override savegame strait away. Some info should be shown that pressing a button will delete content of the file, but event on pressed with some text and progressBar should do the job.