mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-05-06 00:53:52 +00:00
feat(editor): island terrain generator with beach falloff
- Island Generator: creates raised center terrain dropping to edges with configurable center height and edge drop depth - Flat interior plateau → gradual beach slope → steep underwater drop - Preserves existing noise detail at 30% blend for natural variation - Add water around the island for instant ocean environment - Workflow: New Terrain → Island → Noise → Smooth → Auto-paint
This commit is contained in:
parent
f15fbf508f
commit
7971fd7989
3 changed files with 58 additions and 0 deletions
|
|
@ -603,6 +603,18 @@ void EditorUI::renderBrushPanel(EditorApp& app) {
|
|||
ImGui::TextColored(ImVec4(0.6f, 0.6f, 0.6f, 1), "No stamp copied");
|
||||
}
|
||||
|
||||
if (ImGui::CollapsingHeader("Island Generator")) {
|
||||
static float islandHeight = 30.0f, islandDrop = 20.0f;
|
||||
ImGui::SliderFloat("Center Height##island", &islandHeight, 5.0f, 100.0f);
|
||||
ImGui::SliderFloat("Edge Drop##island", &islandDrop, 5.0f, 50.0f);
|
||||
if (ImGui::Button("Create Island Shape", ImVec2(-1, 0))) {
|
||||
app.getTerrainEditor().createIsland(islandHeight, islandDrop);
|
||||
app.showToast("Island created");
|
||||
}
|
||||
ImGui::TextColored(ImVec4(0.6f, 0.6f, 0.6f, 1),
|
||||
"Raised center dropping to edges. Add water around for ocean.");
|
||||
}
|
||||
|
||||
if (ImGui::CollapsingHeader("Ridge / Mountain Range")) {
|
||||
static glm::vec3 ridgeStart{0}, ridgeEnd{0};
|
||||
static float ridgeWidth = 20.0f, ridgeHeight = 30.0f;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue