Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Plant-Gathering shrubs with growths yields nothing?  (Read 1277 times)

Rekov

  • Bay Watcher
  • Elf Aficionado
    • View Profile
Plant-Gathering shrubs with growths yields nothing?
« on: January 01, 2020, 03:10:50 am »

I'm wondering if I've maybe got a bug with my particular set up. I don't seem to be able to get any usable product when I set my plant gatherers to collect certain species. In particular I've tested Bilberry and Rhubarb. The dwarves 'gather' the plant, and it goes away, but they don't end up with any fruit.

Plants with the old set up like Sun Berries or Rope Reeds can still be collected. I was also able to collect strawberries, which are different because they have a growth:fruit, but it's not the part of the plant that's collected. Instead I collected 'strawberry plants'.

Is this a known bug? Am I somehow able to collect these plants before the fruit growths are ready?

EDIT:
It occurred to me that I was using dfhack to designate certain species of shrub for harvesting. Possibly this bug wouldn't occur if I created gather zones and let plant gatherers do as they will. Could be that dfhack just can't tell if a plant is ready using the getplants -s BILBERRY or whatever.
« Last Edit: January 01, 2020, 03:22:52 am by Rekov »
Logged

PatrikLundell

  • Bay Watcher
    • View Profile
Re: Plant-Gathering shrubs with growths yields nothing?
« Reply #1 on: January 01, 2020, 05:15:13 am »

I'm not aware of any bugs for plants that can be brewed (bilberry: I generally don't collect things that can't be made into booze, so I don't know much about those). However, berries and fruit are ripe only at certain times of the year, and if they contain any part that can be picked outside of that time, those plants will be picked (like strawberries, where the plant itself will be picked regardless of whether there is any berries on it or not), which means they're removed from the map and thus can't be picked when the berries ought to be ripe.

As far as I know getplant does the same thing as your area designations for picking does, except that it doesn't include the unwanted kinds of plants. It's also the same as the one applied when you designate them individually.
I would expect harvesting zones to have dorfs pick plants as soon as there is something to pick (like the area designation), without regard for your possible wishes to actually target berries/fruit.

I use this script to collect plants with the primary purpose of getting seeds for farm plots. Note that the parameter section (in the beginning) defaults to collect one of everything (to allow for growing not only for booze, thread, and paper, but for preferred foods as well). I use the script a number of times over the year, in particular the summer, to get berries. Since the script checks your existing designations as well as your current stocks, it should designate less and less over time.

Spoiler (click to show/hide)

Logged

Rekov

  • Bay Watcher
  • Elf Aficionado
    • View Profile
Re: Plant-Gathering shrubs with growths yields nothing?
« Reply #2 on: January 01, 2020, 12:44:23 pm »

Well, Bilberry is brewable at least. I guess I'm wondering if I should report this as a bug on the tracker, because they are being harvested before there is anything actually usable to harvest.
Logged

PatrikLundell

  • Bay Watcher
    • View Profile
Re: Plant-Gathering shrubs with growths yields nothing?
« Reply #3 on: January 01, 2020, 02:04:40 pm »

It's most likely a bug/deficiency in the getplants script. I generated a world, used Biome Manipulator floradiversity on it (to make sure Bilberry is available in suitable biomes), and embarked. I then located an immature Bilberry plant, painted over it with d-p (catching two nearby Bitter Vetch plants in the process) and it did NOT mark the Bilberry plant for picking. I then tried getplants -s BILBERRY and the Bilberry plant was designated.

Thus, the DFHack script presumably doesn't check if there's anything to collect from the plants it designates.
My script reported "Found BILBERRY but it's not ripe (13)", and so doesn't designate any Bilberries.
Logged

Quietust

  • Bay Watcher
  • Does not suffer fools gladly
    • View Profile
    • QMT Productions
Re: Plant-Gathering shrubs with growths yields nothing?
« Reply #4 on: January 01, 2020, 08:20:53 pm »

Thus, the DFHack script presumably doesn't check if there's anything to collect from the plants it designates.

I'm not surprised - "getplants" (which is actually a plugin, not a script) was written before plant growths existed, and it was never updated to take those into account. The last major update to that plugin was two and a half years ago when its Designation logic was updated, and the last major change before that was in late 2014 to improve the way it located plants to harvest (iterating across the global list instead of inspecting each chunk).
Logged
P.S. If you don't get this note, let me know and I'll write you another.
It's amazing how dwarves can make a stack of bones completely waterproof and magmaproof.
It's amazing how they can make an entire floodgate out of the bones of 2 cats.

PatrikLundell

  • Bay Watcher
    • View Profile
Re: Plant-Gathering shrubs with growths yields nothing?
« Reply #5 on: January 02, 2020, 04:58:50 am »

Good thing I was too lazy to look for the script code then, as it doesn't exist ;)

It seems to be a bit of overkill to have it as a plugin, given that it's not something that has to be compiled for efficiency since it operates at the human speed timescale.

If someone would like to update the plugin they're free to use whatever inspiration they can get from my script.
Logged

Rekov

  • Bay Watcher
  • Elf Aficionado
    • View Profile
Re: Plant-Gathering shrubs with growths yields nothing?
« Reply #6 on: January 03, 2020, 02:09:52 am »

I reported it on the tracker for dfhack as well:
https://github.com/DFHack/dfhack/issues/1479
Logged