Incremental movement & terrains
Blitz3D Forums/Blitz3D Beginners Area/Incremental movement & terrains
| ||
Hey everyone, how it going? I have 2 questions! a) I want to position an entity incrementally by 5 (without going in between) either in front, behind or to the sides of it depending on mouse movement. I use position entity but it goes too fast and looks like move entity. Its probably VERY simple, but how would I solve this? b) For a terrain made out of a mesh (not an actual terrain), how many polys would you reccomend it be? Thanks for your help! |
| ||
a) Divide your mouse movement by some number say 3 or 5. b) My favorite is 10 meter tiles (100 blitz units), each tile is a quad (made up of two triangles), Each mesh has 32x32 tiles, I then arrange 8 meshes x 8 meshes to make up the world that 256x256 or 2560m x 2560m. I use a single surface for each mesh. I'll share some sample code if your interested. There are many solutions to get results you want, I hope this info helps. |
| ||
a) newx = 5 * floor( mousex() / 5 ) b) .. best to go with a similar system to what wayne suggests as blitz will automatically cull the terrain entities not in view. |
| ||
Thanks Wayne & Stevie, Ill get cracking! :-) |
| ||
Sorry, I have another question...If something isn't visible, does its still take up computing power?. For example if I was to have a mesh with 60,000 verticies but it was invisible, would this affect my performance much? |
| ||
It really depends on what you're using this mesh for? Collisions? Note that each surface in blitz has a maximum poly count, around 33k, so if you exceed this then you'll get a MAV at renderworld() |