Opened 5 years ago
Last modified 3 years ago
#5566 new enhancement
Refactor Terrain - reduce coupling with simulation components and actual graphical rendering.
Reported by: | wraitii | Owned by: | |
---|---|---|---|
Priority: | Must Have | Milestone: | Backlog |
Component: | Core engine | Keywords: | |
Cc: | Patch: |
Description
This is a high-level task.
Terrain is very tightly coupled with the simulation in a variety of ways:
- TERRAIN_TILE_SIZE is used in many, many places. It has a value of 4 meters. The corresponding NAVCELL_PER_TILE constant is used to convert that back to meters, usually.
- Terrain height map and passability are very tightly coupled.
- LOS is coupled with terrain.
- Several components expect a height map (least of all the map generator and atlas).
- Terrain rendering is tile-based and detail cannot be added for now, and this is an increasing graphics issue.
- Terrain is strictly 2D.
- Textures are very coupled with our terrain specs (which makes some sense, but also limits our abilities).
- Overlays are coupled with terrain.
- Water rendering is coupled with terrain rendering
- We only support a single terrain implementation, simulation-wise and graphics-wise.
+ ... Possibly unidentified other ways ...
A variety of these issues can be fixed somewhat easily and will decrease coupling. Some will be harder, and some require some foresight (do we _need_ several terrain implementations?).
I intend to work on this on and off. Priority will be fixing simulation-terrain coupling, then seeing what can be done for the graphics and texture aspect of it, then seeing how that can be handled in Atlas and such.
Change History (2)
comment:1 by , 3 years ago
Milestone: | Work In Progress → Backlog |
---|
comment:2 by , 3 years ago
Note:
See TracTickets
for help on using tickets.
In 24980: