MattSurabian/DuckHunt-JS

Level 5 loading

anastasia-horbachevska opened this issue · 2 comments

Description:

Level 5 takes longer to load than the previous and subsequent levels. need to wait more than 5 seconds.

Steps to reproduce:

  1. Open the link https://duckhuntjs.com.
  2. Start the game.
  3. Play up to level 5.

Actual result:

Level 5 takes longer to load.

Expected result:

The level will load at the same speed as the other levels.

Additional info:

Tested on Chrome.

Thanks for opening this issue!

I suspect this experience is due to how I lazily implemented the dogs retrieve behavior. Level 4 has lots of ducks in each wave and the dog currently will animate and retrieve every single one that gets shot so it's possible if you're a particularly fast or otherwise skilled player that the level ends so quickly the dog is left bobbing up and down trying to clean up everything, while also sometimes seeing there are 0 ducks left and laughing along the way. The end result is that players have to sit through that instead of just moving on to level 5.

I'll try to fix this and update some underlying deps, been a while since I've been in this codebase.

Finally addressed this. Thanks again for opening the issue.