Learn Intermediate OOP by Building a Platformer Game - Step 117

Tell us what’s happening:

I think I’ve done what they want me to but it says my code doesn’t pass, could somebody please point out my error for me

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region


      if (index === checkpoints.length - 1) {
        isCheckpointCollisionDetectionActive = false;
        showCheckpointScreen("You reached the final checkpoint!");
        movePlayer("ArrowRight", 0, false);
      }
      else if(player.position.x >= checkpoint.position.x && player.position.x <= checkpoint.position.x + 40){
    showCheckPointScreen("You reached a checkpoint!");
      }



// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36

Challenge Information:

Learn Intermediate OOP by Building a Platformer Game - Step 117

Hello!

You have one small mistake here. It is supposed to be showCheckpointScreen