Sunday, May 8, 2011

Free Camera and Lifted Vertex Limit

I redid the camera to be a free roaming camera. Later I'll stick some limitations and physics to be associated with it so that the camera is more like the eyes of the player. But this is excellent for my purposes right now. Instead of being stuck focused on one spot, I can fly anywhere to observe how the world is coming along.

While redoing the camera, I was going to have to redo a bunch of the draw code. So, while I was at it, I lifted off the vertex limit. Instead of being limited to 65000, it can go as high as it needs to. Only limit will be processing speed. Doing that was quite a bit of work, in that it broke quite a bit and I only just now got everything drawing again. But it does. The only thing is some minor glitches about which faces should be drawing. Shouldn't be much to fix.

After this, instead of height maps, I'm going to focus on what's known as "picking". Basically, it's how you decide what object the center of the screen is pointing at. With that, I'll finally be able to get back to the world where data is virtual instead of necessarily being rendered right on the screen. So I'll be able to do stuff like letting you be able to open doors. Or yes, digging out and placing blocks. The engine behind what I'm doing being similar to Minecraft and Infiniminer, that shouldn't surprise you. It's only once I have this up that I'll be able to do stuff like NPCs and procedurally generated quests.

No comments:

Post a Comment