Stat based outcomes

Basically, I want the player to have a different outcome of a choice depending on the stat.

I found a way to do this by…
*if (Strength > 40) #Knock him out`

You knock him out.
*finish

*if (Strength < 40) #Knock him out

You fail at knocking him out
*finish

(These are just examples btw. Not from my game)
Once I quicktest it, it says
“Invalid expression, couldn’t extract another token”
Help

I changed your title for if others get the same problem,also wouldnt this work.

*choice
 #Knock them out
  *if (strength<40)
           Blank
  *if (strength>40)
           Other Blank

You don’t need to make multiple choices. Change it to something like this:

 #Knock him out
    *if (Strength >= 40)
         You knock him out.
         *finish
    *else
         You fail at knocking him out.
         *finish
1 Like

Is your suggestion and faewkless’s basically the same thing

There are always more then one to code it, but they both have the same effect.

I think that if you us feawkless way you have no option when you have the value of 40. You only got the higher and lower symbol < and >.
The = is equal,
so either >40 and <= 40
or >=40 and <40.

Which would you use?

Well, if the question was directed towards me, I am mostly writing as feawkless wrote, but both are possible, especially if you are working with two options.

Also, just wondering, in what program do you write it? Only asking because when I started writing I wrote in notepad, but I should have been using notepad++ because it’s a lot easier. (just a friendly tip)

I use notepad. I don’t have an option to use notepad++ when I click, open with…

True, you need to download notepad++ first, but it’s a free source program, so you can download it for free.

Biggest plus of it I found was that it was spell check and lining so you can see if you spacing is correct, which will come in handy (also, it’s easier to use the tab instead of space bar, you can’t use both or it will give an error).

Just installed it and it looks awesome. Btw, I thought you said it had spell check?

Yeah, should be. If it doesn’t start automatically try alt + A

Or go to plugins, dspellcheck

If it’s not installed go to plugins, plugin manager, and install dspellcheck

Okay, I got it. Thanks for the help.

Your very welcome, and good luck with your writing. Also, ctrl + f and ctrl + g are handy to know.