Heya! This is my first person prototype that I made using Unity and C# to implement what would be the early steps in making a first person game. The script utilizes character controller and is based off of Brackey's first person movement video. After a bit of testing however, I realized that there were some logistical issues and one or two bugs with his code. I reworked his idea and essentially gave the first person gameobject a head so movement, angles, camera position, and code would work better and get rid of a few bugs. Overall, the script works fine and is a perfectly good option to build a game around. However, I believe there must be better ways to build a first person controller that would have less weird interactions and act more cohesive as a whole.
When I finished reworking the first person protoype I also wanted to push the limits a bit and added controls that mimick the abilities of Jett from Valorant. Essentially, the player will be able to updraft using q, dash using e, hover by holding space, smoke (and control its movement!) using mouse3, and can activate their ultimate by pressing x. This, of course, also means they will be able to use left click and right click to throw their knives (capsules since I lack the animation).
The biggest issue I had while working on the project was definitely implementing quaternion to control angles. I was able to use the internet and trail-and-error my way into making it work but I still do not understand how it fundamentally operates. From the sources I have seen, quaternion is a difficult concept to grasp (coincidentally created by the same guy who created Lagrangian which I am learning about) that most programmers don't bother to understand. I would like to understand quaternion. I shall pursue learning it and implementing its features in another project (or utilizing it better in this one).
I plan on coming back to this project whenever I want to fully commit to making a first person game. However, if I wanted to just add more features to the build as is, I would give the user the ability to change mouse sensitivity (a lot of converting), add a small map with obstacles, and add target dummies. Otherwise, that's all!