1
0
mirror of https://github.com/minetest/minetest_game.git synced 2025-06-30 13:50:23 +02:00

Added can_grow function to plant definition (#3131)

This commit is contained in:
ssdaniel24
2024-06-23 19:03:36 +03:00
committed by GitHub
parent f03c992864
commit 061f4e76dd
2 changed files with 9 additions and 3 deletions

View File

@ -382,6 +382,8 @@ The farming API allows you to easily register plants and hoes.
-- ^ Always provide a plant texture for each step, format: modname_plantname_i.png (i = stepnumber)
minlight = 13, -- Minimum light to grow
maxlight = default.LIGHT_MAX -- Maximum light to grow
can_grow = function(pos) -- Сalled every growth tick to check if the plant can grow, returns bool
-- (optional, checks for wet soil by default)
}