mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-06 09:03:52 +00:00
feat(editor): edge ramp tool for seamless multi-tile connections
- Edge Ramp: smoothly transitions tile borders to a target height so adjacent tiles can connect seamlessly - Configurable target height and ramp width (how far in from the edge) - Quadratic blend for smooth start from edge → interior - Essential for multi-tile zone creation: ramp each tile's edges to match its neighbor's border height
This commit is contained in:
parent
d56ea9ae64
commit
6277800773
3 changed files with 49 additions and 0 deletions
|
|
@ -645,6 +645,18 @@ void EditorUI::renderBrushPanel(EditorApp& app) {
|
|||
ImGui::TextColored(ImVec4(0.6f, 0.6f, 0.6f, 1), "No stamp copied");
|
||||
}
|
||||
|
||||
if (ImGui::CollapsingHeader("Edge Ramp (Multi-tile)")) {
|
||||
static float rampTarget = 100.0f, rampWidth = 20.0f;
|
||||
ImGui::SliderFloat("Target Height##ramp", &rampTarget, 0.0f, 500.0f);
|
||||
ImGui::SliderFloat("Ramp Width##ramp", &rampWidth, 5.0f, 60.0f);
|
||||
if (ImGui::Button("Ramp Tile Edges", ImVec2(-1, 0))) {
|
||||
app.getTerrainEditor().rampEdges(rampTarget, rampWidth);
|
||||
app.showToast("Edges ramped");
|
||||
}
|
||||
ImGui::TextColored(ImVec4(0.6f, 0.6f, 0.6f, 1),
|
||||
"Smoothly transitions tile borders to target height\nfor seamless multi-tile connections");
|
||||
}
|
||||
|
||||
if (ImGui::CollapsingHeader("Thermal Erosion")) {
|
||||
static int erosionIters = 10;
|
||||
static float talusAngle = 40.0f;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue