I'm creating a game on the Sugarcube platform, and I'm really extraordinarily bad at coding. -_- (why do I do this to myself)
Anyhow.
I'd like to find a way for a variable counter to increase/decrease every time the player clicks on certain links/goes to certain pages, and if they click said links too much, the game automatically redirects them to a page (saying something like, you died. I don't know.) and ends the game.
Sorry if this is too basic!
Comments
1. You can use a <<set>> macro to increasing/decrease a variable whenever a particular passage is visited, it is generally places near the top of that passage.
2. You can use either a Link w/ Setter or a Link w/ Text & Setter to increasing/decrease a variable whenever a particular link is clicked.
3. You can use an <<if>> macro to check the current value of a variable. You can use a <<goto>> macro to redirect the reader to a passage.