Hiding String Variable

Hey so I’m new to coding trying to get used to commands and stuff while I’m still planning. So one thing I want to do is have a affiliation stat sort of thing at a later point in the game, but I also wanted to keep it hidden for spoiler reasons. So it would appear on the stats screen as like “Army Rank - Captain” just as an example. I can hide other stats and relationships using true/false if and such fine but I just can’t figure out the wording for this one, any help is appreciated.
Thanks in advance!

1 Like

I haven’t ever tried this myself, but wouldn’t it work the same way as hiding relationships since all these things would use variables?

But if it doesn’t work that way, and you can’t figure out anything better, you could just try this. Make the “army rank” words and the “captain” word separate variables that both have values of spaces until you want to reveal it. Yes, it may create an awkward space in the stats screen but you could probably still make it look good.

1 Like

You need to be a bit more specific about what you are actually wanting to do.

Ok ok, I don’t know if I understood correctly, but you can do that with the same true/false system you used for your other variables, I believe. As in, like

*if (affiliation = true)
    Army Rank - Captain

(and this doesn’t show up in your stats screen unless affiliation = true, which you can set up easily later after a choice or scene or chapter)

OR, in case you’re trying to do something a bit more complex (which I guess you do?) and work around changing the rank depending on the choices the player makes, you could set up your stats screen to change according to certain variables, as in

(this would be in your startup doc)

*create affiliation false
*create variable1 0
*create variable2 false
*create variable3 "text"

And you set the stats screen as something like

*if (affiliation = true)
    Army Rank - 
    *if (variable1 >= 2)
        something something / Soldier
    *if (variable2 = true)
        something else / Commander
    *if (variable3 = "inputtext")
        the third option / Idk military names

And this would be your scene where those variables come to play

Hello! Make your choice.

*choice
    #Set affiliation true.
        *set affiliation true
        *goto yisnextscene
    #Show text for variable1.
        *set affiliation true
        *set variable1 3
        *goto yisnextscene
    #Show text for variable2.
        *set affiliation true
        *set variable2 true
        *goto yisnextscene
    #Show text for variable 3.
        *set affiliation true
        *set variable3 "inputtext"
        *goto yisnextscene

And it’d show up as something like this while running the game
image

so if you chose the first, your stat screen goes
image
because you didn’t set any of the other variables for the text to show up
and in the second choice the stat screen goes
image
because the variable affiliation = true and the condition for “something something / Soldier” is met
and the same goes for the third and fourth options
image
image

Is this what you wanted to do or have I made things unnecessarily complicated? :sweat_smile:
I hope it helps!

2 Likes

Ooooooooh, okay, I get it, sorry my original wording was unclear. I think this method would work for me I just could not figure out how to word things at all, I’ll give it a try.
Thank you!

1 Like