A 4D video game?

Viewing single post

Started by Legend, Feb 27, 2018, 04:58 AM

previous topic - next topic

Legend

Ok we've figured out potential ways to render the graphics. How would the game engine side of things work?

For starters I'd have to essentially create my own game engine. Unity is very customizable but none of its default things could be modified to 4D. Instead I'd need to build absolutely everything myself through scripts.

Some of these things would be pretty easy. I understand vector math and position/scale are simple to expand to 4D. Rotations however would suck. I barely understand how quaternions work, much less the math behind them, so building my own 4D versions would be hard. 4D objects have 6 degrees of freedom for rotation so I'd need two quaternions to define 1 rotation or use some other way to sort it out. A good solution is important since rotation will be used for graphics and physics too.

Speaking of physics, I'd need to program my own methods from scratch. I've already done this for VizionEck with some things but I'd need to heavily optimize it and add standard functions like raycasting and spherecasting. 4D objects are very "dense" so I might need to fake a lot of things to make it run reasonably fast. Would definitely help if I built the scene out of primitives instead of tetrahedron meshes.

Designing and building the game would require overhauling the unity editor window and making it run in 4D as well. Again I have a little bit of experience with modifying it so this won't be easy but should be doable. Could sync the editor with my custom list of objects and just make it an inactive view of what's really happening since during runtime the unity scene would be empty.


Programing an engine from scratch would probably be more efficient but I think it'd be smarter to start with Unity as a framework. I'd want to get this to a prototype state as fast as possible so I can really assess the idea.