Hi, okay so ive got got a 3d game with a lot of wall and objects that i want to have collision detection and resolution with, so far ive been using bounding boxes like this:
//Right bunker wall
if(playerX > nuclearBunkerX + 7 && playerX < nuclearBunkerX + 8
&& playerY > nuclearBunkerY - 8 && playerY < nuclearBunkerY + 6
&& playerZ > nuclearBunkerZ - 3 && playerZ < nuclearBunkerZ + 16.3)
{
playerWallCollisionResolution();
}
but having all these bounding boxes takes up a lot of space meaning it takes me longer to find different parts of code, has anyone got any ways that they use bounding boxes while still being able to keep the BBs from filling up my code, for example maybe i could have a text file that i read in to my program that contains all the BBs and then have a for loop running through them? has anyone done it and been successful doing it this way?
Thanks :)