Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 2 3 [4] 5 6 ... 12

Author Topic: [MODDING] REACTIONS QUESTIONS THREAD  (Read 33779 times)

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #45 on: February 12, 2015, 03:37:21 pm »

According to the wiki, the GET_ITEM_DATA_FROM_REAGENT specified the material in addition to the item type.  Maybe if you reverse the order of GET_s it will trick the game into doing what you want.

not sure if you mean this...
Code: [Select]
[PRODUCT:100:1:GET_MATERIAL_FROM_REAGENT:thing2:NONE:GET_ITEM_DATA_FROM_REAGENT:thing1:NONE]I tried it, and it crashed my shell, and causes a Unrecognized Item Token error.
changing the order of reagents just changes which reagent will be copied, it always takes the item data and material from the first reagent listed... afaik
That was what I meant.  Sorry it didn't work.  I guess Toady was worried about people making dwarven wine breastplates or something.
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

Snergler

  • Bay Watcher
  • The world is the same as ever.
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #46 on: February 12, 2015, 03:57:58 pm »

using  GET_ITEM_DATA_FROM_REAGENT:reagent:NONE  basically cancels any material tokens after it, however there is...  GET_ITEM_DATA_FROM_REAGENT:reagent:REACTION_PRODUCT_ID   ...which might work, by adding...  REACTION_PRODUCT_ID   tokens to certain material tokens... maybe
Logged

pastafriend

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #47 on: February 21, 2015, 07:36:52 am »

I can't get these custom reactions working.

Code: [Select]
[REACTION:MAKE_BULLETS_2]
[NAME:make Mk II rifle bullets]
      [BUILDING:SMELTER:NONE]
[REAGENT:A:150:BAR:NO_SUBTYPE:METAL:IRON]
[PRODUCT:100:1:AMMO:ITEM_AMMO_BULLETS_2:GET_MATERIAL_FROM_REAGENT]
[FUEL]
[SKILL:FORGE_WEAPON]

[REACTION:MAKE_GUN_2]
[NAME:make Mk II rifle]
      [BUILDING:SMELTER:NONE]
[REAGENT:A:150:BAR:NO_SUBTYPE:METAL:NONE]
[PRODUCT:100:1:AMMO:ITEM_WEAPON_RIFLE_ADV:GET_MATERIAL_FROM_REAGENT]
[FUEL]
[SKILL:FORGE_WEAPON]

[REACTION:MAKE_GUN_MG]
[NAME:make machine gun]
      [BUILDING:SMELTER:NONE]
[REAGENT:A:150:BAR:NO_SUBTYPE:METAL:IRON]
[PRODUCT:100:1:AMMO:ITEM_WEAPON_MACHINEGUN:IRON_HEAVY]
[FUEL]
[SKILL:FORGE_WEAPON]

IRON_HEAVY is a material defined in one of the inorganics files.

Added this to entity file:

Code: [Select]
[PERMITTED_REACTION:MAKE_BULLETS_2]
[PERMITTED_REACTION:MAKE_GUN_2]
[PERMITTED_REACTION:MAKE_GUN_MG]

The reactions don't show up when using the smelter.
Logged

UnicodingUnicorn

  • Bay Watcher
  • Competent at Incompetency.
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #48 on: February 21, 2015, 08:37:22 am »

Try changing the BAR:NO_SUBTYPE to BAR:NONE.
Logged
I do stuff, I guess

pastafriend

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #49 on: February 21, 2015, 09:24:12 am »

Try changing the BAR:NO_SUBTYPE to BAR:NONE.

Hmm. Didn't work.
Logged

UnicodingUnicorn

  • Bay Watcher
  • Competent at Incompetency.
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #50 on: February 21, 2015, 10:30:39 am »

Try changing the BAR:NO_SUBTYPE to BAR:NONE.

Hmm. Didn't work.
Right, for product materials you also need to specify :NONE and GET_MATERIAL_FROM_REAGENT requires you to specify the label of the reagent that you want the material from, for example, GET_MATERIAL_FROM_REAGENT:A
Logged
I do stuff, I guess

pastafriend

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #51 on: February 21, 2015, 11:01:30 am »

Quote
Right, for product materials you also need to specify :NONE and GET_MATERIAL_FROM_REAGENT requires you to specify the label of the reagent that you want the material from, for example, GET_MATERIAL_FROM_REAGENT:A

Code: [Select]
[REACTION:MAKE_BULLETS_2]
[NAME:make Mk II rifle bullets]
[BUILDING:SMELTER:CUSTOM_A]
[REAGENT:A:300:BAR:NONE:INORGANIC:NONE][REACTION_CLASS:METAL]
[PRODUCT:100:50:AMMO:ITEM_AMMO_BULLETS_2:GET_MATERIAL_FROM_REAGENT:A:NONE]
[PRODUCT:100:50:AMMO:ITEM_AMMO_BULLETS_2:GET_MATERIAL_FROM_REAGENT:A:NONE]
[PRODUCT:100:50:AMMO:ITEM_AMMO_BULLETS_2:GET_MATERIAL_FROM_REAGENT:A:NONE]
[SKILL:FORGE_WEAPON]



[REACTION:MAKE_GUN_2]
[NAME:make Mk II rifle]
[BUILDING:SMELTER:CUSTOM_P]
[REAGENT:A:150:BAR:NONE:INORGANIC:NONE][REACTION_CLASS:WEAPON_METAL]
[PRODUCT:100:1:WEAPON:ITEM_WEAPON_RIFLE_ADV:GET_MATERIAL_FROM_REAGENT:A:NONE]
[FUEL]
[SKILL:FORGE_WEAPON]

[REACTION:MAKE_GUN_MG]
[NAME:make machine gun]
[BUILDING:SMELTER:CUSTOM_M]
[REAGENT:A:150:BAR:NONE:INORGANIC:NONE][REACTION_CLASS:WEAPON_METAL]
[PRODUCT:100:1:WEAPON:ITEM_WEAPON_MACHINEGUN:IRON_HEAVY]
[FUEL]
[SKILL:FORGE_WEAPON]






That's what I've got now, also tried permitting one of the weapons in the entity file. Still doesn't work  :/
« Last Edit: February 21, 2015, 12:24:01 pm by pastafriend »
Logged

scamtank

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #52 on: February 21, 2015, 01:04:56 pm »

You're not doing this on an ongoing save, are you? Entities don't look at their raws after worldgen.
Logged

pastafriend

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #53 on: February 21, 2015, 05:18:16 pm »

You're not doing this on an ongoing save, are you? Entities don't look at their raws after worldgen.

Nope, regenning the world after every RAW change.
Logged

BlackFlyme

  • Bay Watcher
  • BlackFlyme cancels Work: Interrupted by bird.
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #54 on: February 21, 2015, 06:17:47 pm »

Are you saving these reactions in their own file or inside of another one?

If they are in their own file, be sure to check that you have the proper headings, or that the file is named correctly.
Logged

pastafriend

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #55 on: February 21, 2015, 06:31:46 pm »

Are you saving these reactions in their own file or inside of another one?

If they are in their own file, be sure to check that you have the proper headings, or that the file is named correctly.

Oh man. Used [OBJECT_REACTION] instead of [OBJECT:REACTION]  ::). It's all working now, thanks guys.
Logged

Urist McGoombaBrother

  • Bay Watcher
  • Trust the plump helmet! ♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠♠
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #56 on: February 22, 2015, 02:25:19 pm »

I have got a weird problem regarding glazing.

I created slag and amended it from stone to metal to avoid the stockpile problems when adding the [METAL_ORE:SLAG:12] tag to the various ores. By stockpile problem I mean, that the METAL_ORE tag creates bars of slag, which can't be matched to the stone definition of slag and ends up sitting forever in the workshop till I decide to glaze something. Weirdly the [MATERIAL_REACTION_PRODUCT:GLAZE_MAT:INORGANIC:SLAG_GLAZE] token does recognise it properly.

Now Slag is defined as following:

Spoiler (click to show/hide)

Also with metal-properties the Kiln takes the slag and glazes an unglazed clay product as intended. It also has the defined colour. The problem is, that the slag does not disappear in the workshop after usage. So I could basically glaze unlimited clay products with just one slag.

just a note: I did not have this problem when slag was defined as stone boulder. I could make custom reactions for each of the automatic smelt ore into metal reactions and remove the METAL_ORE tags and add a boulder of slag as side product. But then then my ore stockpile menu will basically end up empty, which does not look good either.

So to sum up, what I would like to do is following:

1) add slag as side product to each one of the smelt ore into metal reactions
2) make the slag useable for glazing and actually disappear after usage
3) keep the ores as ores in the stockpile menu

Any ideas?

Zarathustra30

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #57 on: February 28, 2015, 05:28:09 am »

So to sum up, what I would like to do is following:

1) add slag as side product to each one of the smelt ore into metal reactions
2) make the slag useable for glazing and actually disappear after usage
3) keep the ores as ores in the stockpile menu

Any ideas?

I'm not sure, but I think the problem comes using bars instead of boulders. Since bars have a material size of 150, each reaction peels off 1/150th of a bar and uses just that to glaze.  However, it wasn't working like that last I checked (it just used the entire bar).

Nevertheless, you may want to try an additional reaction that converts a bar of unusable slag into a boulder of slag glaze.
Logged
How did we pass from inns with merry songs and happy music to temples of doom and medieval torture with so much easiness and eagerness??

Urist McCoder

  • Bay Watcher
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #58 on: March 10, 2015, 10:22:49 am »

How do you select bone in a reagent?
Logged

BlackFlyme

  • Bay Watcher
  • BlackFlyme cancels Work: Interrupted by bird.
    • View Profile
Re: [MODDING] REACTIONS QUESTIONS THREAD
« Reply #59 on: March 10, 2015, 10:30:39 am »

I use this reagent in my own bone reactions:

Code: [Select]
[REAGENT:A:1:NONE:NONE:NONE:NONE][ANY_BONE_MATERIAL][USE_BODY_COMPONENT]
There are other methods though.
Logged
Pages: 1 2 3 [4] 5 6 ... 12