I wrote down some observations about the Hoppy Days lesson that I hope will help.
For a while, I found that the jump button was being very unresponsive, only working about half the time. It took me a while to realize I should fix this, that it wasn’t just my keys being sticky or the Godot engine being slow. After some poking around, I realized that is_on_floor() was only returning true intermittently. I managed to fix this with:
if is_on_floor() or is_on_ceiling(): motion.y = 10 else: motion.y += GRAVITY * delta
instead of motion.y = 0. I first tried motion.y = 1, but this was not strong enough. Since Yann didn’t seem to have this problem, I’m wondering if it’s because my collision polygons were not quite flat (I did not use the snapping tool).
It might interest you, I tested this problem by making an extra sprite to the Player object and making it visible when is_on_floor() was true. When I used to use blit engines for games, I would do that kind of thing a lot, often having it blit some kind of text onto the screen with more information, and there would be a global debug variable that I could turn on and off to disable all such information as needed.
When getting the paths to scenes, instead of right-click, copy path, you can just drag the item from the File System into the script editor. You can also do this with items from the scene inspector to get their relative path.
For the GUI animations, I tried to make variables for the animation names, like var anim_coin_up = “CoinPulse”, because I thought the code editor would be able to autocomplete variable names instead of needing to remember exactly what the string was called, but the editor did not autocomplete these variables, I assume because it’s wrapped up in so many references. I’d be interested to know if there’s a way to make it autocomplete for a project with a lot more animations.
I was disappointed that the spikeman is just animated. I was hoping to learn how to make enemies that physically exist, and one that could walk to the edge of a platform and turn around by AI. Using the AnimationPlayer was an interesting technique though.
I’d be interested to see a way to make the cloud check if any terrain is in its way before shooting lighting at the player. So for example, in a situation where there’s the cloud, then a platform, then a player, it won’t shoot.
I also would have liked to see a way to make the spring more physically realistic, like it idles on the spring.png, then when bunny lands on it, it goes to spring_in.png for a few frames, and then it goes to spring_out.png and launches bunny. Part of that would be easy by using the AnimationPlayer, but I’m not sure how you’d get bunny to stay on top of it while it’s in spring_in.png phase.