79350459

Date: 2025-01-12 18:29:13
Score: 0.5
Natty:
Report link

I'm aware that i'm late, but just in case anyone hasn't figured it out...

Both jumpUp and glideDown have issues.

  1. jumpUp only needs to check three times, not four. the fourth check is dead code, and should be removed.
  2. glideDown should not have an else statement. it should turn right, advance 1-3 times depending on how many spaces are clear in front of it, and then turn left regardless. This is what's messing you up. if it glides down three, it fails to turn left, and is not facing the finish anymore. it then tries to leap the ground instead of the next hurdle, and runs into the hurdle. Crash boom bang. It's not the number of hurdles. It crashes after the first three high one. 100%

jumpUp can be optimized by using this.rightIsClear() instead of turning back and forth. If for some reason that function is not available, it can be defined easily enough.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (0.5):
Posted by: Mr. Beeblebrox