Keyboard: WASD to move, arrow keys and NM to rotate, space to hide the forward button Touch: Drag to move, the big Forward button to move forward
I implemented some robust world to object transformation, object to world transformation and cuboid rendering routines. Also, the code is ready for having different kinds of 3D objects, as tailored to the requirements of my game that's soon to be released. The use of quaternions not only makes the code run fast but can also give you an head-start in implementing smooth rotation animations. All code by me, @boraini. I can have your questions in the comments. If you just need a clean quaternion math implementation instead of all the clutter here you can see my project specifically for it. https://scratch.mit.edu/projects/454897467/ UPDATES 03/12/2021 - Optimized the fill quad routine so it attempts to do less scans than before. 13/12/2021 - Proper backface culling added. 06/02/2022 - Performance improvement. Cleaned up code.