Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Reaction to produce rock crystal?  (Read 851 times)

hughesdylan

  • Bay Watcher
    • View Profile
Reaction to produce rock crystal?
« on: November 16, 2009, 02:37:58 pm »

Lo all,

I pilfered this from a much better DF modder, but im using this in Reaction_standard. I want it to rarely produce a single rock crystal.. but i cant seem to get the tags right. Help?

Code: [Select]
[REACTION:SIFT_STONE]
[NAME:Sift Stone]
[SMELTER]
[REAGENT:1:STONE:NO_SUBTYPE:STONE:NO_MATGLOSS]
[PRODUCT:1:1:ROUGH:CRYSTAL_ROCK]
[PRODUCT:2:1:BAR:NO_SUBTYPE:METAL:IRON]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:COPPER]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:TIN]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:GOLD]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:SILVER]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:ALUMINUM]

This works for all the bars, because i was able to find exact lines of code to copy.
Logged

slink

  • Bay Watcher
  • Crazy Cat Dwarf
    • View Profile
    • Slink's Burrow Online
Re: Reaction to produce rock crystal?
« Reply #1 on: November 16, 2009, 03:39:35 pm »

Try:

PRODUCT:1:1:ROUGH:NO_SUBTYPE:CRYSTAL_ROCK:NO_MATGLOSS
Logged
There is only one cat, and all cats are that cat.
Almost losing is sometimes fun.

hughesdylan

  • Bay Watcher
    • View Profile
Re: Reaction to produce rock crystal?
« Reply #2 on: November 16, 2009, 04:05:26 pm »

I will try that when i am able. Thanks for your help.
Logged

forsaken1111

  • Bay Watcher
    • View Profile
    • TTB Twitch
Re: Reaction to produce rock crystal?
« Reply #3 on: November 16, 2009, 06:31:15 pm »

If I am remembering the system correctly, your reaction there won't be rare or random but very predictable. Every 100 stones will suddenly produce 1 bar of each metal and 1 crystal, every 50 stones will produce a bar of iron. I don't know if you care about that though, just thought I should point it out.
Logged

hughesdylan

  • Bay Watcher
    • View Profile
Re: Reaction to produce rock crystal?
« Reply #4 on: November 16, 2009, 06:37:34 pm »

Yes, i am aware of that. I would prefer it to be an actual % chance, but i realise these are % completion instead. What im going to do is make an intermediary step, at least i hope. Instead of actually making the bars, those would "sift out" ore. So like every 100 stones killed, give me a hematite.

Then i can refine iron from that. But also, have a "rough gem" placeholder that would give 1% chances (completion, i know) of several gems. So, that would lower the number to 1 in 10,000 for the gems. Much more reasonable. The same would work for "Precious Metals", that would randomly give low amounts of gold silver platinum or aluminum (Again i know this isnt percentage. bear with me). So, a tiered list.

It gives my dwarves a lot of work, to keep them busy, gives me access to things that... statistically i should have tiny amounts of anyway, and clears out tons of stone. A single bar of (native) aluminum every 10,000 stones isnt that unreasonable... i don't think. It also allows me to access to things i normally couldent get without the damn carravans. I hate them. Die treehuggers!
Logged

hitto

  • Bay Watcher
    • View Profile
Re: Reaction to produce rock crystal?
« Reply #5 on: November 16, 2009, 06:53:55 pm »

Thatwould be a pretty cool reaction, doesn't feel like cheating with such low percentages, gives you a fighting chance in case of needy nobles and gets rid of the useless stone...
Logged

Deon

  • Bay Watcher
  • 💀 💀 💀 💀 💀
    • View Profile
Re: Reaction to produce rock crystal?
« Reply #6 on: November 16, 2009, 08:17:23 pm »

Your reactions lack tabs.

It's:
[PRODUCT:%:#:ITEM TOKEN:ITEM SUBTYPE:MATGLOSS:MATGLOSS SUBTYPE]
% = percent, # = number.
For rock crystals I think it is (I may be wrong):
[PRODUCT:1:1:GEM:NO_SUBTYPE:STONE:CRYSTAL_ROCK]

Try with [PRODUCT:100:1:GEM:NO_SUBTYPE:STONE:CRYSTAL_ROCK] to be sure.
Logged
▬(ஜ۩۞۩ஜ)▬
✫ DF Wanderer ✫ - the adventure mode crafting and tweaks
✫ Cartographer's Lounge ✫ - a custom worldgen repository

hughesdylan

  • Bay Watcher
    • View Profile
Re: Reaction to produce rock crystal?
« Reply #7 on: November 16, 2009, 11:13:16 pm »

Actually, that code produces Large Gems. I need cut gems. In fact, i would prefer raw stone that had to be refined, or cut at the workshop, but im guessing thats impossible. did you intend the code to produce large gems?


Please, if you wouldent mind, could you try to code in the rough gems, or even cut would be ok. Not large though.

<EDIT>
Actually, i fixed it myself. Turns out i wasnt too far off before.

Code: [Select]
[REACTION:SIFT_STONE]
[NAME:Sift Stone]
[SMELTER]
[PRODUCT:1:1:ROUGH:NO_SUBTYPE:STONE:CRYSTAL_ROCK]
[PRODUCT:2:1:BAR:NO_SUBTYPE:METAL:IRON]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:COPPER]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:TIN]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:GOLD]
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:SILVER]

This works just fine, for those who want to use some of it.
[PRODUCT:1:1:BAR:NO_SUBTYPE:METAL:ALUMINUM]
« Last Edit: November 16, 2009, 11:24:14 pm by hughesdylan »
Logged