mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Set sky API: Add bool for clouds in front of custom skybox
Default true. Add 'm_clouds_enabled' bool to sky.h, set from new bool in 'set sky' API. Make 'getCloudsVisible()' depend on 'm_clouds_enabled' instead of 'm_visible' (whether normal sky is visible).
This commit is contained in:
parent
f9fdb48dc8
commit
ad9fcf859e
12 changed files with 53 additions and 20 deletions
|
@ -3077,13 +3077,15 @@ This is basically a reference to a C++ `ServerActiveObject`
|
|||
* `hud_set_hotbar_selected_image(texturename)`
|
||||
* sets image for selected item of hotbar
|
||||
* `hud_get_hotbar_selected_image`: returns texturename
|
||||
* `set_sky(bgcolor, type, {texture names})`
|
||||
* `set_sky(bgcolor, type, {texture names}, clouds)`
|
||||
* `bgcolor`: ColorSpec, defaults to white
|
||||
* Available types:
|
||||
* `type`: Available types:
|
||||
* `"regular"`: Uses 0 textures, `bgcolor` ignored
|
||||
* `"skybox"`: Uses 6 textures, `bgcolor` used
|
||||
* `"plain"`: Uses 0 textures, `bgcolor` used
|
||||
* `get_sky()`: returns bgcolor, type and a table with the textures
|
||||
* `clouds`: Boolean for whether clouds appear in front of `"skybox"` or
|
||||
`"plain"` custom skyboxes (default: `true`)
|
||||
* `get_sky()`: returns bgcolor, type, table of textures, clouds
|
||||
* `set_clouds(parameters)`: set cloud parameters
|
||||
* `parameters` is a table with the following optional fields:
|
||||
* `density`: from `0` (no clouds) to `1` (full clouds) (default `0.4`)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue