Lesson 4: The Physics of Flight
Now that we’re getting into the chill back-and-forth flow of Jippity, let’s push on and add more to our little game. I’m going to ask to draw a rectangle that represents the ground, and mark distances along it with a marking every 100 pixels so that we can measure how far the bird flies.

Jippity separates the idea into two little blocks of code. Already, I’m picking up a good coding habit: keep it simple and keep it short. AI has the advantage of being trained on countless examples of code written by prudent professionals, so in most cases, it follows best practices — in this case, short, readable chunks of code. I insert them and keep requesting features.
I want the camera to follow the bird so that I can fly farther than just a single screen. Now I have to think! How should I describe this to a computer? I transport myself back to physics class and do my best:
Keep the bird in the center of the view of the game and translate the world in the opposite direction of its motion so that I can see the bird move.
Jippity responds with some clarifying questions — helpful — and I give it even more detail:
The ground should move opposite the bird so that while the bird is still, it appears to move because the world is translating in the opposite direction. We will add clouds and flowers and that kind of thing later.

We are implementing relative motion, a core principle in physics that is also essential to game development. Very cool. Jippity suggests using the translate() function to accomplish this, which does the trick, but it’s not quite what I want. When I test my game, I notice that I would prefer the bird to still move higher and lower on screen, but I do want to keep the bird centered horizontally.
Seems like a simple change, and indeed it is. Reminder: AI is not all-or-nothing! I can handle this one by hand and build a little confidence along the way. I take a look at the translate() function and replace its second argument, which controls vertical shifting, with plain ol' 0. I can even highlight that function and click the Explain button if I want to make sure I'm doing it right. A great benefit of AI tools is how flexible they can be. A coding assistant like Jippity can generate, debug, and explain at shifting layers of depth depending on the user's needs, mirroring the behavior of the best human tutors. In this case, after a few minutes of Jippity leading the way, I felt confident to make some changes by hand. The back-and-forth empowers me and keeps me moving forward.

We are progressing! We havve turned some simple descriptions into functional code and picked up a little physics along the way. Let's push on — in the next section we'll upgrade the visuals.