Please sign in to access this page
I will be creating a 3D Math and hopefully physics Engine in which I will attempt to make as realistic of a game as possible. At the moment I am not sure as to what game I will make, but I have considered Minecraft.
Rohan the Codebreaker (my code)
Check their projects out: Ruby Mine - for Railway YSWS!, Jumpstart Project Showcase Page, Math Map, DNA-cryption, Euclidia, Personal Page
Once you ship this you can't edit the description of the project, but you'll be able to add more devlogs and re-ship it as you add new features!
I was having problems with clipping and could not figure it out for many days, so I finally decided that I would search YouTube. Resources: Javid9x had a video on clipping and the mountains.obj. I also plan to use his camera since mine is too slow. You can find the copied sections in massive commented code blocks. Note: the current camera used in the video is mine.
Refactored my rendering methods and added some optimizations as well as a means to render .obj files. On the other hand, I have yet to add a means of sorting the triangles so that they can be seen in the appropriate manner (it is currently drawn randomly).
Implemented an artificial Triangle Clipping by considering whether or not the centroid and half points of the triangle are within the normalized screen or not. Now we cannot see behind the camera and the triangles don't go insane when the camera approaches it.
Implemented a basic light system by calculating the dot product of the triangle normal to the light source and assigning an albedo value to each set of albedo values to act as a multiplier on the RGB value, hence, darkening the color.
I attempted to implement clipping so that my triangles didn't misbehave when approached, however, I was unsuccessful in my task. Instead, I decided to put clipping on a pause, and implement a stationary type camera as seen in the video. I even added features to encase the entire screen of the player as well as button functionality.
Used the Cross and Dot Product to figure out which triangles should be displayed and which ones should not. The cross and dot product took a while because I have never done them before, however, organic chemistry was a great resource.
My Vector-Matrix multiplying method wasn't working because I forgot to divide by w (xyzw matrix), but now everything is working fine and I even added rotation.
I created a sleep methodological game loop and spent lots of time attempting to derive the projection matrix as shown in the image. Now I need to create a method for actually rendering the points/triangles onto the screen as well as many other things. I'm still very far away from being anywhere near finished but overall happy with my progress so far! :)