@Slightly - I changed the spinach minlight level to 7 as a test and planted a row with a few print statements enabled to show minlight, maxlight and node_name, they all grew fine and showed the light levels I changed with no bugs.
How are you setting the light levels, are you using minlight and maxlight or naming them differently ?
[Mod] Farming Redo [1.49] [farming]
Re: [Mod] Farming Redo [1.49] [farming]
I didn't touch the spinach. It's in the crop file asTenPlus1 wrote: ↑Fri Nov 14, 2025 18:17@Slightly - I changed the spinach minlight level to 7 as a test and planted a row with a few print statements enabled to show minlight, maxlight and node_name, they all grew fine and showed the light levels I changed with no bugs.
How are you setting the light levels, are you using minlight and maxlight or naming them differently ?
-- add to registered_plants
farming.registered_plants["farming:spinach"] = {
crop = "farming:spinach",
seed = "farming:spinach",
minlight = 7,
maxlight = farming.max_light,
steps = 4
}
Spinach is already minlight = 7. I didn't do anything at all to it. Just used it as an example. How did you change it? Did you put it in the node definition instead of this registered_plants?
- Attachments
-
- nogrowat11.png (209.45 KiB) Viewed 176 times
Re: [Mod] Farming Redo [1.49] [farming]
The farming.registered_plants["spinach"] contains information for 3rd party mods, to change the actual crop light level you would need to add "minlight = 7," to the actual crop definition on line 21 of the spinach.lua file, or the same line using farming.register_plant as per the api.txt definition.
Re: [Mod] Farming Redo [1.49] [farming]
Ok, that makes sense given the original growth timing function (mine's doing it differently now), but I still don't get that from reading the api.txt. Probably some basic coding thing I'm still missing. Just for my information, what's the minlight in the registered plants doing, then? When would it be used?TenPlus1 wrote: ↑Sat Nov 15, 2025 06:19The farming.registered_plants["spinach"] contains information for 3rd party mods, to change the actual crop light level you would need to add "minlight = 7," to the actual crop definition on line 21 of the spinach.lua file, or the same line using farming.register_plant as per the api.txt definition.
Re: [Mod] Farming Redo [1.49] [farming]
@Slightly - Usually most mods will use the farming.add_plant() api function to register crops, which will add the relevant nodes, seeds and drops while adding the relevant crop information to the farming.registered_crops[] table for 3rd party mod lookup. Most of the crops in farming redo I register manually simply for custom control, which needs to add each of the above seperately.
Re: [Mod] Farming Redo [1.49] [farming]
Ok, thanks for explaining. So, in that case, only rhubarb currently has different light settings, I guess.TenPlus1 wrote: ↑Sat Nov 15, 2025 11:21@Slightly - Usually most mods will use the farming.add_plant() api function to register crops, which will add the relevant nodes, seeds and drops while adding the relevant crop information to the farming.registered_crops[] table for 3rd party mod lookup. Most of the crops in farming redo I register manually simply for custom control, which needs to add each of the above seperately.
Except my undergarden crops. It's pretty fun to go under the regular garden and see the root crops growing below. :)
Re: [Mod] Farming Redo [1.49] [farming]
@Slightly - Underground crops will be a nice addition, will be eager to see your mod when it's complete :)
Who is online
Users browsing this forum: No registered users and 1 guest