I want to run a Quicktest, but when I try, I always get the same error. I know what’s causing it, and will explain below the excerpt of code, but I can’t get rid of the offending lines, so I need to find out some way, like Randomtest’s *if choice_randomtest, to get around it.
Here’s the offending code:
*if (length(name) >= 1) *temp letter1 name#1 *if (length(name) >= 2) *temp letter2 name#2 *if (length(name) >= 3) *temp letter3 name#3 *if (length(name) >= 4) *temp letter4 name#4 *if (length(name) >= 5) *temp letter5 name#5 *if (length(name) >= 6) *temp letter6 name#6 *if (length(name) >= 7) *temp letter7 name#7 *if (length(name) >= 8) *temp letter8 name#8 *if (length(name) >= 9) *temp letter9 name#9
See, when the player chooses their name, I need to grab each letter in their chosen name, whether it’s one of the default names or one they input. Each *if statement in the code above stores each letter in the name in a *temp variable. When I first tried doing this, I got errors if the inputted name wasn’t long enough, e.g. the name Helen would result in “There is no character at position 6. “Helen” is only 5 characters long.” Adding the *if statements to check that the letter existed fixed it for manual playthroughs and Randomtests. However, since Quicktest checks *if statements even if they should be impossible to reach, I can’t test past these lines of code. This is right at the beginning of the game as well, so I essentially can’t use Quicktest at all. Help please?