Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Is is possible to select specific sets of plants as reaction targets [Answered]?  (Read 1439 times)

PatrikLundell

  • Bay Watcher
    • View Profile

What I want to achieve: Repair the vanilla DF plant functionality purely through raw modding so there's a way to get seeds for plants/growths when the only way to process the plants/growths is to cook them (and thus destroy the seeds).

I've been able to define one plant and one growth reaction that takes sources that have seed extraction reactions, which is a good start, but I want to exclude all the plants/growths that can be used for anything other than cooking so these reactions only compete for targets that can otherwise be used only for cooking (extracting plump helmet spawn from plum helmets worked, but it's obviously a waste).

I can imaging two ways to achieve my objective:
1. Somehow detect that the target can only be cooked. I have no idea how to do that, and doubt it's possible. Restricting targets to those that can be cooked would be an improvement, even if it doesn't go all the way.
2. Somehow explicitly identify the targets I want to target, though some kind of token or custom reaction that would act as a target identifier. Again, I don't have any idea about how to achieve this.
3. There's obviously the possibility of a solution I fail to imagine.

As can be seen by the above, I have a rather limited knowledge of raw modding.
« Last Edit: January 22, 2020, 03:30:42 am by PatrikLundell »
Logged

Nahere

  • Bay Watcher
    • View Profile
Re: Is is possible to select specific sets of plants as reaction targets?
« Reply #1 on: January 19, 2020, 02:19:05 pm »

Slap a Reaction Class called, say, COOKABLE_ONLY on any plants/growths that are cookable only, then require that class in the reactions.
Logged

PatrikLundell

  • Bay Watcher
    • View Profile
Re: Is is possible to select specific sets of plants as reaction targets?
« Reply #2 on: January 19, 2020, 04:33:54 pm »

Thanks. This seems to be exactly what I was looking for.
Logged