Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2

Author Topic: Custom reaction not showing up  (Read 3598 times)

Nate McCloud

  • Bay Watcher
    • View Profile
Custom reaction not showing up
« on: April 06, 2010, 04:14:35 pm »

So I created a new reaction for the Smelter that should allow me to use 10 bars of any metal, 10 logs of any wood, 10 pieces of any stone, and 10 pieces of any gem to make one raw adamantine. I even remembered to put the custom reaction into the dwarf entity file. However, when I move to the Smelter while in q mode, there's a slight lag, and the reaction doesn't show up! There shouldn't be a problem, according to my empty error log...
Code: [Select]
[REACTION:RAW_ADAMANTINE]
[NAME:make raw adamantine]
[BUILDING:SMELTER:NONE]
[REAGENT:A:10:BAR:NO_SUBTYPE:METAL:NO_MATGLOSS]
[REAGENT:B:10:WOOD:NO_SUBTYPE:PLANT_MAT:NO_MATGLOSS:WOOD]
[REAGENT:C:10:BOULDER:NO_SUBTYPE:INORGANIC:NO_MATGLOSS]
[REAGENT:D:10:ROUGH:NO_SUBTYPE:INORGANIC:NO_MATGLOSS]
[PRODUCT:100:1:STONE:NO_SUBTYPE:STONE:RAW_ADAMANTINE][PRODUCT_DIMENSION:150]
[FUEL]
[SKILL:SMELT]
Logged

Upright Path

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #1 on: April 06, 2010, 04:16:13 pm »

A custom reaction has to be placed in the entity_default.txt...

Inside, find the tag [ENTITY:MOUNTAIN] and beneath it, place [PERMITTED_REACTION:RAW_ADAMANTINE]

And it should show up.
Logged

Nate McCloud

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #2 on: April 06, 2010, 05:16:22 pm »

That was actually the dwarf entity I was referring to. >_< Sorry, I should've been more clear. I did add the custom reaction to entity_default.txt for the dwarves, but the custom reaction never showed up.
Logged

Upright Path

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #3 on: April 06, 2010, 05:22:12 pm »

Did you add it in the raw/object file?

Or in the data/save/regionX/raw/object file?
Logged

Ilmoran

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #4 on: April 06, 2010, 05:25:15 pm »

You have to regen the world.  With the whole "copy changes into save folder raws" thing, I think people aren't making it clear, but if you modify something (reaction, creature, mineral, etc), you don't need regen the world, but if you add something, you do need to regen.  Since you're adding reactions to the smelter, you need to regen the world.

Tip:  If you want, make a copy of your saved fortress, abandon the copy, load that world in Legends mode, and export the world gen parameters, and you can remake the (mostly) same world.  I take no responsibility if a mod adjusts how history progress by allowing your dwarves to mass produce adamantine and become the master race.
Logged

Nate McCloud

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #5 on: April 06, 2010, 05:26:34 pm »

Upright Path: Both.
Ilmoran: Oh...well, that explains it...thanks.
Logged

Ilmoran

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #6 on: April 06, 2010, 05:31:35 pm »

Upright Path: Both.
Ilmoran: Oh...well, that explains it...thanks.

np; I spent about 2 hours last night going "Why the hell doesn't this work; I even copied over the example people posted in the tutorial thread.  Damnit, let me regen"... 5 minutes later "Sonofa... it worked.  Damnit."

I'm thinking about throwing about 10 buildings and 100 reactions into the files, regening with them blank, and then if people make mods for buildings/reactions that I like, I can just edit the dummy building/reaction.
Logged

Nate McCloud

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #7 on: April 06, 2010, 05:38:40 pm »

You know...that's not a bad idea.
Logged

Ilmoran

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #8 on: April 06, 2010, 05:56:26 pm »

You know...that's not a bad idea.

Yeah, the only problem is a lot of people are modding in new plants, animals, or materials, and I don't know if I could safely create blanks of those, and even if I could, it'd be limited to what traders bring you.
Logged

Bob Boberton

  • Escaped Lunatic
    • View Profile
Re: Custom reaction not showing up
« Reply #9 on: April 06, 2010, 05:58:09 pm »

On a similar note... Although being generally all-around awesome, DF2010 reworking reactions has broken my stone-to-food reaction. :c I'm back to the problem described in the original post here, though I'll re-post the reaction itself, as I made minor changes to bring it into line with DF2010:

Code: [Select]
[REACTION:FREE_FOOD]
[NAME:free plump helmets (10)]
[BUILDING:SMELTER:NONE]
[REAGENT:A:3:BOULDER:NO_SUBTYPE:NONE:NONE]
[PRODUCT:100:1:PLANT:NONE:MUSHROOM_HELMET_PLUMP:NONE][PRODUCT_DIMENSION:150]
[SKILL:SMELT]

Now, the same problem: This reaction doesn't appear to work (I have added it to entity_default as a permitted reaction)... it generates "plant(s)", which are completely inedible and sit around doing nothing - no stockpile accepts them either. Speaking of which, the following "response to embarking in a desert with no trees for miles" reaction broke as well; it generates "logs" which are usable as wood but don't fit into any stockpile.

Code: [Select]
[REACTION:FREE_WOOD]
[NAME:free wood]
[BUILDING:SMELTER:NONE]
[REAGENT:A:5:BOULDER:NO_SUBTYPE:NONE:NONE]
[PRODUCT:100:1:WOOD:NO_SUBTYPE:PLANT_MAT:NO_MATGLOSS][PRODUCT_DIMENSION:150]
[SKILL:SMELT]

Misguided syntax abounds! Does anyone happen to know the right way to get food/wood generated with the new system? :P
« Last Edit: April 06, 2010, 06:47:50 pm by Bob Boberton »
Logged

Upright Path

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #10 on: April 06, 2010, 08:01:25 pm »

Quote
Code: [Select]
[REACTION:FREE_FOOD]
[NAME:free plump helmets (10)]
[BUILDING:SMELTER:NONE]
[REAGENT:A:3:BOULDER:NO_SUBTYPE:NONE:NONE]
[PRODUCT:100:1:PLANT:NONE:[b]PLANT_MAT:[/b]MUSHROOM_HELMET_PLUMP:[b]PLANT[/b]][PRODUCT_DIMENSION:150]
[SKILL:SMELT]

Code: [Select]
[REACTION:FREE_WOOD]
[NAME:free wood]
[BUILDING:SMELTER:NONE]
[REAGENT:A:5:BOULDER:NO_SUBTYPE:NONE:NONE]
[PRODUCT:100:1:WOOD:NO_SUBTYPE:PLANT_MAT:[b]WOOD_NAME_FROM_RAWS[/b]:[b]WOOD[/b]][PRODUCT_DIMENSION:150]
[SKILL:SMELT]

Here would be a corrected version of that code.
Logged

Nate McCloud

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #11 on: April 06, 2010, 09:17:44 pm »

What do you use between PLANT_MAT and WOOD if you want to use ANY kind of wood as a reagent?
Logged

Upright Path

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #12 on: April 06, 2010, 09:23:49 pm »

As a reagent? Or as the product? Because if you just want to use wood as a reagent, that's simple enough.
Logged

Nate McCloud

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #13 on: April 06, 2010, 09:27:42 pm »

As a reagent, because I'm pretty sure you can't produce a random wood from a reaction.
Logged

Upright Path

  • Bay Watcher
    • View Profile
Re: Custom reaction not showing up
« Reply #14 on: April 06, 2010, 09:29:59 pm »

[REAGENT:A:WOOD:NO_SUBTYPE:NONE:NONE]
[PRODUCT:100:1:<ITEM>:<ITEM_SUBTYPE>:GET_MATERIAL_FROM_REAGENT:A:NONE]

Result? This is a oak item, if an oak WOOD was used. Palm item, if a palm WOOD was used.
Logged
Pages: [1] 2