mirror of
https://github.com/luanti-org/luanti.git
synced 2025-10-14 09:05:19 +02:00
Add minetest.get_artificial_light and minetest.get_natural_light (#5680)
Add more detailed light detection functions, a function to get the artificial light (torches) and a function to get the sunlight as seen by the player (you can specify timeofday). Co-authored-by: rubenwardy <rw@rubenwardy.com>
This commit is contained in:
@@ -56,6 +56,11 @@ private:
|
||||
// timeofday: nil = current time, 0 = night, 0.5 = day
|
||||
static int l_get_node_light(lua_State *L);
|
||||
|
||||
// get_natural_light(pos, timeofday)
|
||||
// pos = {x=num, y=num, z=num}
|
||||
// timeofday: nil = current time, 0 = night, 0.5 = day
|
||||
static int l_get_natural_light(lua_State *L);
|
||||
|
||||
// place_node(pos, node)
|
||||
// pos = {x=num, y=num, z=num}
|
||||
static int l_place_node(lua_State *L);
|
||||
|
Reference in New Issue
Block a user