Quality Farming


You can now farm plants that are affected by quality. Modded plants are supported! Includes optional setting to tint quality plants to match their quality color.

Content
a month ago
2.0 - 2.1
889
Manufacturing

g Crash on Factorio 2.1 — possible fix available

3 months ago

Hi,

first of all, I really like the idea of this mod. I think it is an interesting addition to the quality system.

After updating to Factorio 2.1, the mod crashes during startup with an error related to tree-plant leaf sprites:

The given sprite rectangle is outside the actual sprite size

I looked into the issue a bit and it seems to be caused by the tree sprites. From what I can tell, the tree/plant sprite handling changed between Factorio 2.0 and 2.1, and the hardcoded tree handling in the mod no longer matches the current sprite dimensions.

I made a small local fix that solves the crash for me. The mod now loads correctly again in Factorio 2.1.

If you are interested, feel free to contact me and I can send you the fixed version or the patch. I would be happy if this helps keep the mod working.

3 months ago

Sure, what’s a good way to reach you?

3 months ago

https://drive.google.com/file/d/1mwGSuG3CZ7vIfZTQRGA-PkKyILnYUwig/view?usp=drive_link
Hope this works
I used ChatGPT
It changed this in functions.lua:

if (quality.name.."-tree-plant" == plant.name) then
variation.leaves.filename = "quality-plants/plant/tree-plant/tree-08-"..letters[i].."-leaves.png"
else
variation.leaves.filename = func.base_tintable[gsub] or variation.leaves.filename
end

to

if not (quality.name.."-tree-plant" == plant.name) then
variation.leaves.filename = func.base_tintable[gsub] or variation.leaves.filename
end

3 months ago

Will this be an update to mod soon I ran into the same problem

3 months ago

If you want you can use my temporary fix until then

a month ago

So I'm updating this to 2.1, but I don't seem to get that startup crash. Do you still get it on the most recent experimental branch?

a month ago

Looks like it's working maybe Wube changed something on there site

New response