[Solved] Checkpoints Problems- Variable Issues


#1

Community,

I’ve watched a few tutorials on checkpoints. Both used different methods; however, both result in the same issue. My character does not appear at checkpoint locations. Instead, my character appears at the top left corner of the game (regardless of where the character’s actual spawn is).

What am I missing? Please consider the options in the uploaded image.


#2

Each of your options has spelling mistakes. This is not acceptable for GDevelop.
You have two options:

  • Be very very careful when you write names, values, variables, etc.
  • Use the menus, dropdowns and the expressions buttons image to avoid mistakes.

Read your events again (and again!) and fix the mistakes (I see 3 of them).

Protip: upper left corner coordinates are 0;0. Getting a 0 instead of an expected value means there is a mistake or it means that the action supposed to change the value was not executed for any reason.

Good luck


#3

Thank you for the tip.

I corrected the typos, but the bad result continued. However, it seems like when I titled the sprite and scene variable to checkpoint (instead of redbock [sic] or waystone). I was able to get option 2 to work, never option 1.

Since I am new to coding entirely, here are my questions. Did I succeed because I changed the sprite’s name and/or the name of the scene variable to “checkpoint”? Could checkpoints be titled anything?


#4

anything you like :slight_smile:
The only rules for object naming are no spaces, no special characters, and not starting with a number, I think.


#5

Appreciate the advice!