hey can I get a vibe check on my terrain system first, the building system: buil...
Ben Lubar (any pronouns) @ben@lubar.me
hey can I get a vibe check on my terrain system
first, the building system:
- building "cells" are 0.25m wide by 1m tall by 0.25m deep
- floors fill the top 0.25m of a cell
- room interiors are 3m tall
- "doorways" are 1.5m wide and 0.25m deep with an 1.75m tall opening and 1.25m of wall above that
- "walls" are 3m tall with an 0.25m tall floor below them automatically
- "interior floors" clear a 3m tall area above them from terrain
- "exterior floors" do not clear terrain above them
- "pillars" are 1m tall
- characters can crawl through a 0.75m tall/0.75m wide space
- characters can walk through a 1.5m tall/0.75m wide space
- characters can climb a 1m tall ledge
- some characters can climb on walls, some on walls and ceilings, some can fly
- any surface that is at least partially pointing up is considered walkable floor
the terrain system operates on a larger grid; 4m wide by 1m tall by 4m deep, but cut along both diagonals of the square
so for example the bottom face of the terrain cell at (0, 0, 0, 0) is a triangle with vertices (2, 0, 2), (4, 0, 4), and (4, 0, 0)
each of the vertices of the cell can be moved up or down to create terrain.
the vertices touching the hypotenuse of the right isosceles triangle can be moved up or down by 1m increments and the third vertex can be moved up or down by 0.5m increments.
all of the vertices of the top and the bottom triangle (the two triangles separately) must be within 2m of the height of the other two vertices.
the two triangles can touch, but cannot cross or swap places.
once the triangles are positioned, the resulting volume is clipped to the original terrain cell.
there are 671 possible "shapes" for the contents of a terrain cell, including empty.
each terrain cell has a material, so if you had something like "grass", it would be a solid block of grass within that 1m tall cell. empty cells do not have a material.