I’m getting an error and I can’t figure out why.
This is the error, which shows up when I try to access my stat screen:
{message:"Result of expression \‘variable.toLowerCase\’ [undefined] is not a function. ",line:543,sourceId:354648424,sourceURL: “file:///Users/Sienna/Desktop/GAME/scene.js”,expressionBeginOffset: 17252,expressionCaretOffset:17272,expressionEndOffset:17274,name:“TypeError”}
This is the code for the stat screen. And yes, I’ve set the variable charm in mygame.js. It equals 5.
`
*temp skill
*set skill 0
Skills:
*line_break
*if (charm > 0)
*set skill {charm}
Charm:
*gosub skill_level
*finish
*finish
*label skill_level
*if (skill > 0) and (skill < 10)
Novitiate
*return
*if (skill >= 10) and (skill < 20)
Novice
*return
*if (skill >= 20) and (skill < 30)
Amateur
*return
*if (skill >= 30) and (skill < 40)
Apprentice
*return
*if (skill >= 40) and (skill < 50)
Adept
*return
*if (skill >= 50) and (skill < 60)
Journeyman
*return
*if (skill >= 60) and (skill < 70)
Specialist
*return
*if (skill >= 70) and (skill < 80)
Expert
*return
*if (skill >= 80) and (skill < 90)
Guru
*return
*if (skill >= 90) and (skill < 100)
Master
*return
*if (skill = 100)
Grandmaster
*return
*return`
Help please!