Discussion in 'Game Design, Development And Publishing' started by Dan Williams, Nov 20, 2018.
Does anyone know the code to make 3d walls solid?
in Game maker studio
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
Unless you plan on having ramps and multiple levels and such, standard 2D collisions should suffice.
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)