In place of pictures I decided to upload gameplay footage to YouTube so that I could add annotations. It's not all that exciting but more illustrative than stills.
Although the idea for my project was not originally zombie-based, I wanted to use Assignment 4's freelook world to create a simple game in which the player hits enemies as quickly as possible. It would involve some physics-based motion and randomly position enemies for the player to hit.
Because I wanted to introduce a more interesting way for the enemies to appear, I decided to make them rise from underground. At the time I was still using the good ol' bunny.obj texture, but when I made them rise from the ground I realized that I had to find a zombie object file to make the game make more sense. I then added a condition that made the zombies pivot roughly about their feet instead of rising straight up.
Distance from the orb to the zombie determines if the zombie is 'hittable'. When it is in range, it lights up green to help the player know when they can smack it. With more time I would have implemented a shader that highlighted around a textured zombie instead of just changing its color from red to green.
Once I could spawn objects and detect when they were in close proximity to the player's orb, I needed to implement symplectic Euler motion equations in the object class as well as functions that allowed me to add forces together. The sum of forces is stored with each object individually and is resettable with a function call. A different function call updates the object's position with any chosen h value.
Using glfwGetTime() calls, zombie objects are created at decreasing intervals.
I added functions to the Camera class that allow it to send its eye and forward vectors to the main program. By scaling and adding the forward vector to the eye vector, a position is created that will always be directly in front of the camera.
This required applying a rotation and translation initially to each zombie when it was born, and then rotating it back to zero slowly over a bunch of render() calls.
Unfortunately I did not have time to find a zombie object file that had vertex normals or do the computation of normals myself. While all objects in the scene are rendered using Blinn-Phong lighting, only the yellow orb is representative of the lighting.