brucewong21 Posted November 7, 2017 Share Posted November 7, 2017 Hello everyone, I'm working on a doom clone which you can try out here metaldoom.herokuapp.com I want to create a 3D level grid so that I can visualize my A* path finding algorithm and also use my in game editor to snap cubes to certain points on the map. I tried to make a visualization using a mesh but with many meshes, performance obviously becomes too slow. How can I create a 3D reference grid in my scene yet avoid the performance hit? Thank you so much for your help. I have an image to show how the grid should behave and look like. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted November 7, 2017 Share Posted November 7, 2017 Hello and welcome! Did you check the gridMaterial: http://doc.babylonjs.com/extensions/grid Quote Link to comment Share on other sites More sharing options...
brucewong21 Posted November 7, 2017 Author Share Posted November 7, 2017 Hello, yes I did. From what I understand the grid material is just a material that covers a mesh right? I still would need a reference to each mesh in order to check collisions on whether or not another mesh had intersected it. I also need to have references to each mesh's position in order to move my units in a certain direction. To show you what i mean, I've updated my application onhttps://metaldoom.herokuapp.com/ Now there will be a grid which is just many 1x1 wireframe meshes put together. You can see that as the monster's hitbox collides, the mesh turns red. This game uses the UniversalCamera controls (WASD). Click the left mouse button to fall down to move around. Sorry if I wasn't too clear and thanks for helping! Let me know if you prefer a PG example. Quote Link to comment Share on other sites More sharing options...
brucewong21 Posted November 7, 2017 Author Share Posted November 7, 2017 I guess instead of just a reference point, I meant I need actual game objects that can react to other objects in the scene. Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted November 7, 2017 Share Posted November 7, 2017 I think so Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.