Best_stat_4, non-existant variable stat_1```
I have two questions.
One, if I put the stats page into this, would someone be able to help me fix this, and two, this particular airor only comes up in choice two, with the
```gosub_scene best_stat``` flag being in the label that all three of the choices connect to. With that in mind, why is only choice two flagging this?
Anyway, here is the stats page:
The file at // says: dialog best_stat_5: non-existant variable stat_name_1
I’m still not totally sure what all the stat_ lines do, exactly, and every once in a while an error pops up that, when I reboot my computer, goes away, even if I can’t find anything wrong in the files I have.
Here is what I have in the startup file as far as stats go:
I can put more of the stat variables in, but I’m not sure if this will mess with the highest_calc page, and getting the relationships figured out correctly.
Also, for things like
*set stat_1 XXX
*set stat_2 XXX
ETC, how would you set that up as a create variable in startup? It seems that I don’t have the *stat_1 and such there, and right now, I can’t think of how I would go about setting it up, as it’s neither a true/falce, or a 1/2/3.
All the variables you use need to be created, whether with *create name value in the startup.txt file or with *temp name value before you try to use them.
Have a look at this to get a better understanding of how choicescript works.
From what I am getting from the guide, (I am not sure if there is a spasific guide that talks about the *set anty-repeat 0), or at least I was not able to find one, do I have to put the, for example
*create stat_1 ""
```?
It wants a create variable, but as the current variable is,
*set stat_1 combat
I am a little confused on what to do here.Also, thanks for all the links.
Looking at the startup file for your WIP on Dashingdon, it looks like you have already created the variables for combat and the other stats. But you will still need to create all the variables that you listed in the first post. That means stat_1, stat_name_1, stat_2, stat_name_2, and so forth.
Basically, you cannot *set a variable without creating it first. This is because a variable does not exist until you use *create to include it in the game. (This is also why you got the error message about the non-existent variable.)
That is neither true/falce, a number, or in a quoted string. I can put quotes after it, but I don’t know how that will affect the other highest_calc page.
Using this will result in an error. You need to include a number instead, so something like:
*create stat_1 0
And then when it’s needed, you can set the variable:
*set stat_1 combat
This means that stat_1 will hold the same value as combat.
CMIIW here, but using quotation marks will result in the variable being treated as a string, not a number. It will probably affect the stat calculations like you said.