• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Solid 3D walls

D

Dan Williams

Guest
Does anyone know the code to make 3d walls solid?
in Game maker studio

Cheers
 

Mert

Member
Game Maker does not offer collision for 3D system, we basically do 2D collision for them. What's your game's orientation ? Top down, fps, platformer ?
 
D

Dan Williams

Guest
Game Maker does not offer collision for 3D system, we basically do 2D collision for them. What's your game's orientation ? Top down, fps, platformer ?
Its an First person maze game
 

Yal

šŸ§ *penguin noises*
GMC Elder
As others have said, you'll need to code a collision system by yourself if you need 3D collisions. However, for simple cases you could get away with a pretty easy hack: have 2D collisions like normal, but add in a check to compare Z and height values. If the objects just overlap in the 2D plane but doesn't overlap in Z as well, just abort without doing the actual collision stuff. To have a collision in 3D, you need to overlap both in X, Y, and Z.

And of course, for games like mazes and racing, you're usually stuck in the XY plane all the time anyway, so you don't need to code 3D collisions, you just use 2D collisions but add 3D graphics.

(I've made an asset for this kind of stuff, btw: https://yaru.itch.io/yarufps ... it's not super flashy or anything, but it exists)
 
Top