Hey there,
I'm working on a game in the Sugarcube 2 format at the moment, and I've run into something that might be an issue. At one point, I allow the player to name a few different things, but I've come to realize that if the player names these items something such as "<<set $Gold to 999999>>" then that code will be run every time I would have otherwise just called what was supposed to be a name.
I figured I might be able to stop this with <<print>> but I haven't had any luck with that, and admittedly I don't really know much about Javascript to be able to manipulate the strings to limit them to alphanumeric symbols, or at least stop this code from being run. Anyone have any ideas on how I could prevent this? Thank you!
I'm working on a game in the Sugarcube 2 format at the moment, and I've run into something that might be an issue. At one point, I allow the player to name a few different things, but I've come to realize that if the player names these items something such as "<<set $Gold to 999999>>" then that code will be run every time I would have otherwise just called what was supposed to be a name.
I figured I might be able to stop this with <<print>> but I haven't had any luck with that, and admittedly I don't really know much about Javascript to be able to manipulate the strings to limit them to alphanumeric symbols, or at least stop this code from being run. Anyone have any ideas on how I could prevent this? Thank you!