Quantcast
Channel: GameDev.net
Viewing all articles
Browse latest Browse all 17825

Adding Prerotations to game objects

$
0
0
When I was modelling the truck, the cab must face towards me, that is positive +z, which makes the object having a negative z vertex positions because the truck has to be animated moving forwards. When rendering a navigation mesh on it, I would like to use to have the mesh having all positive z positions. the problem is mine because my pathfinder isn't able to look up nodes locally that is in negative range. Therefore, when I render the navigation mesh, I'll give a pre-rotation on the geometry and the navigation mesh has positive z, but now the geometry and the navigation mesh is 180 degrees of out each other. As I am rendering on frame level for the truck, I want to do prerotations on the frames too. but when I multiply the prerotation matrix (with no translations) with the transformation matrix of the frame, things getting bizzard. I just cannot control it because the pivot of each frames is not predefined.... how do I prerotate the frame hierarchy?

Viewing all articles
Browse latest Browse all 17825

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>