Flavor text that changes depending on player's current highest stat

Hi! So I’d like to revamp the personality system in my game. When a player chooses a certain choice, that choice will put a point towards a personality variable (let’s say witty, tough, charming, or quiet.) I’d like for different versions of scenes to appear depending which personality trait has the most “points.” Actually, I have something like this implemented in my stat screen for the player’s actual stats. It looks a little like this:

*label main_stat_calc
*temp mainstat
*set mainstat "Might"
*temp mainstatval
*set mainstatval might
*if charm >= mainstatval
  *set mainstat "Charm"
  *set mainstatval charm
*if wit >= mainstatval
  *set mainstat "Book-smarts"
  *set mainstatval wit
*if lie >= mainstatval
  *set mainstat "Mythomania"
  *set mainstatval lie
*if invent >= mainstatval
  *set mainstat "Quick-thinking"
  *set mainstatval invent

with a *gosub and various *if (mainstat = “inserstathere”) commands. Depending on what is currently set as “mainstat”, some fun flavor text will appear talking about your prowess.

Would the same code work for what I’m trying to accomplish with personality? Is there anything major I have to change? Thank you so much for your time! :smiling_face:

1 Like

Do you use multireplace at all?

I don’t, to be honest in order to accomplish the other flavor text thingy, I asked a similar question to this and simply used the code given to me. I know intermediate-ish Choicescript, but have never touched stuff like multireplace :sweat_smile:

1 Like

It’s a lot less hairy than it looks. And it’s perfect for this kind of thing.

1 Like

I think it’s fine. You could experiment with multireplace as Aletheia suggested but it really depends how much you want to change based on the stat - if it’s shorter than a paragraph I’d recommend multireplace, otherwise carry on.
Multireplace just takes less time for smaller changes and you’ll be repeating these commands a lot.

That’s tough, I think it might be more than a paragraph at times. MC’s responses in most scenes will differ depending on personality (they’ll sound a little more standoffish, witty, or upbeat, etc.) I’ll play around with both. Thank you all so much!

Multireplace is definitely better suited to small stuff than big passages of text. But it’s perfect if you want to slip in subtle nuances that alter otherwise invariable text based on how the character sees the world. The effect can be almost magical.


That’s absolutely what I was going for. A little always goes a long way in stuff like this. Thank you so so much for your help :smiling_face:

1 Like

This topic was automatically closed 24 hours after the last reply. If you want to reopen your WiP, contact the moderators.