From 46587164bd87b7699e151144927e21b562be7b20 Mon Sep 17 00:00:00 2001 From: Starbeamrainbowlabs Date: Thu, 29 Jun 2023 03:19:30 +0100 Subject: [PATCH] //sculpt: tweak the default settings I got the idea from an MC video about voxelsniper. Surprisingly it works rather well :P --- CHANGELOG.md | 5 ++++- Chat-Command-Reference.md | 2 +- worldeditadditions_commands/commands/sculpt.lua | 10 +++++----- 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 11e4e5f..aef94c5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,7 +8,10 @@ Note to self: See the bottom of this file for the release template text. - Add `//dome+`, which allows you to change the direction the dome is pointing in, and also create multiple domes at once - Add `//metaball`, which renders 2 or more [metaballs](https://en.wikipedia.org/wiki/Metaballs) in Minetest - Migrate from `depends.txt` to `mod.conf` - - `//sculpt`: Fix undefined `default` brush + - `//sculpt`: + - Fix undefined `default` brush + - Change defaults to `circle`, `height=1`, and `brushsize=8`. + - **TODO:** change ordering to put `height` after `brushsize` instead of the other way around - Commands that modify the terrain now ignore liquids - `//hollow`: Fix safe region bug - Significant backend refactoring to tidy things up diff --git a/Chat-Command-Reference.md b/Chat-Command-Reference.md index 7f5962e..ce63c9a 100644 --- a/Chat-Command-Reference.md +++ b/Chat-Command-Reference.md @@ -670,7 +670,7 @@ Lists all the available sculpting brushes for use with `//sculpt`. If the `previ ``` -### `//sculpt [ [ []]]` +### `//sculpt [ [ []]]` Applies a specified brush to the terrain at position 1 with a given height and a given size. Multiple brushes exist (see [`//sculptlist`](#sculptlist)) - and are represented as a 2D grid of values between 0 and 1, which are then scaled to the specified height. The terrain around position 1 is first converted to a 2D heightmap (as in [`//convolve`](#convolve) before the brush "heightmap" is applied to it. Similar to [`//sphere`](https://github.com/Uberi/Minetest-WorldEdit/blob/master/ChatCommands.md#sphere-radius-node), [`//cubeapply 10 set`](https://github.com/Uberi/Minetest-WorldEdit/blob/master/ChatCommands.md#cubeapply-sizesizex-sizey-sizez-command-parameters), or [`//cylinder y 5 10 10 dirt`](https://github.com/Uberi/Minetest-WorldEdit/blob/master/ChatCommands.md#cylinder-xyz-length-radius1-radius2-node) (all from [WorldEdit](https://content.minetest.net/packages/sfan5/worldedit/)), but has a number of added advantages: diff --git a/worldeditadditions_commands/commands/sculpt.lua b/worldeditadditions_commands/commands/sculpt.lua index f84ac80..a61549e 100644 --- a/worldeditadditions_commands/commands/sculpt.lua +++ b/worldeditadditions_commands/commands/sculpt.lua @@ -9,20 +9,20 @@ local Vector3 = wea_c.Vector3 -- ██ ██ ██ ██ ██ ██ ██ -- ███████ ██████ ██████ ███████ ██ ██ worldeditadditions_core.register_command("sculpt", { - params = "[ [ []]]", + params = "[ [ []]]", description = "Applies a sculpting brush to the terrain with a given height. See //sculptlist to list all available brushes. Note that while the brush size is configurable, the actual brush size you end up with may be slightly different to that which you request due to brush size restrictions.", privs = { worldedit = true }, require_pos = 1, parse = function(params_text) if not params_text or params_text == "" then - params_text = "circle_soft1" + params_text = "circle" end local parts = wea_c.split_shell(params_text) - local brush_name = "circle_soft1" - local height = 5 - local brush_size = 10 + local brush_name = "circle" + local height = 1 + local brush_size = 8 if #parts >= 1 then brush_name = table.remove(parts, 1)