Any way to reset disable_reuse during the game?

So… I’ve got a game that I’ve (attempted) to put in a checkpoint style save system into (it really kind of needs it) but, realised a possible problem-> When I’ve used disable_reuse to check off some choices from being used more than once in some scenarios, if you return to an earlier point in the game, they stay unusable again which game breaking in some cases. I have been manually putting in *if variables to reset at the beginning of those sorts of choices (messy and I’m worried will be bug prone if I forget to reset any of them) or just turn the disable_reuse off which works, but means choices aren’t ticked off which could be annoyinig if players can’t remember which ones they’ve already tried if running through a series of dialogues for example.

Is there any way to reset the choices used on a page without having to start setting individual "choice1used = “no”, "choice2used= “yes” style resetable variables?

If you go to another scene the disable reuse are reset. You can do that to reset all your *disable_reuse but you can’t choose which one cause it affects all of them. I don’t know if that’s what you need.


Hi there @Loudbeat. Yep my problem is the majority of save points are within the same scene so they’re not being reset on a restore. I could send people out to a placeholder scene and then back again with variables and goto_scenes, but that’s potentially as much fiddling around with as creating and setting chosen choice variables. I could do it in a pinch though. Thanks for the suggestion.

1 Like

It might be possible to use a subroutine that would probably be easier to return from.

1 Like

Returning via *goto_scene scene_name label_name instead of *goto label_name would solve your problem, I believe.

That’s what I was saying, your “command” to reset the disable_reuse would be *goto_scene reset_disable_reuse, and on that file just put a *return and your code would keep going from there. You can use it like a function just for that purpose. Otherwise you’ll have to replace the disable_reuse for variables and do it manually.

Perhaps you can solve this issue with *temp boolean variables? :thinking:

Like this:

*temp pickedchoice1 false

And when you get to the choice 1 it would look like this:

*label choices
*if (pickedchoice1 = false) #Choice 1
*set pickedchoice1 true
*goto choices

Thus if the choice 1 has been picked, it wouldn’t be visible again, no *disable_reuse needed :slight_smile:

I’m doing a version of that, but there’s lots of occasions where they need to be reset throughout the scene or I’d run into dozens of variables relating to choices per scene. I might just keep going with that, I just need to remember to reset them all before the next problematic choice set runs though.

It might be possible to use a subroutine that would probably be easier to return from.

I could, except it’s not always the same place you’re returning to :slight_smile:

Thanks everyone for the input. Sounds like there’s no easy way. I’ll just need to program around that coding limitation from the sounds of it.


The only solution I have thought of is not to reset the affected variables in the (re)load of the game from the save check in the first place. This might require creating specific variables for disable on reuse situations.


Thanks Eiwynn. Yep the other alternatives would be to have lots of separate variables (or at least temp ones per page) and remember to put them in the save point instead rather than resetting them between choices. I’ll have a think about it and work something out. I was kind of hoping maybe there was an easy reset page type command or similar that I didn’t know about but seems not :slight_smile:

If you’re OK with resetting all your disable_reuses in a scene, there is*goto_scene.

I might be misunderstanding things, but it sounds like

  1. you have a save system that can return players to an earlier point in the game
  2. disable_reuses aren’t getting reset when the save point is in the same scene

While I can’t be 100% certain without seeing your code, if disable_reuses aren’t being reset then you’re probably returning to that save point using a *goto command.

If you replace that *goto command with the equivalent *goto_scene command, then everything will work the same except you will also force the scene to reload, resetting any disable_reuses.

Hope I’m making sense — you can see this behavior in this example:

*comment startup.txt

*label choice
    *disable_reuse #Option 1
        *goto choice
    *disable_reuse #Option 2
        *goto choice
    *disable_reuse #Option 3
        *goto choice
    #Return via *goto (won't reset options)
        *goto choice
    #Return via *goto_scene (will reset options)
        *goto_scene startup choice