Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 102 103 [104] 105 106 ... 247

Author Topic: [MODDING] 0.40.x QUESTIONS THREAD  (Read 334465 times)

UnicodingUnicorn

  • Bay Watcher
  • Competent at Incompetency.
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1545 on: November 21, 2014, 10:01:46 am »

I'm tempted to say magical energy weaponry, but apart from that, crushed gems behave surprisingly much like sand, e.g. they are abrasive.
Logged
I do stuff, I guess

Sergarr

  • Bay Watcher
  • (9) airheaded baka (9)
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1546 on: November 21, 2014, 12:03:00 pm »

That's because they're basically the same thing: crystals made from tough oxides.
Logged
._.

heydude6

  • Bay Watcher
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1547 on: November 21, 2014, 12:04:44 pm »

If they are just like sand, then let's just assume that they can make some sort of glass.
Logged
Lets use the ancient naval art of training war parrots. No one will realize they have been boarded by space war parrots until it is to late!
You can fake being able to run on water. You can't fake looking cool when you break your foot on a door and hit your head on the floor.

milo christiansen

  • Bay Watcher
  • Something generic here
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1548 on: November 21, 2014, 05:12:15 pm »

DFHack is the answer: anything (well, almost anything) is possible if you use DFHack. Your best bet is to use a lua hook and do all the logic from the DFHack side of things (you need a lua hook so you can destroy the reagents if needed, AFAIK this is just a matter of playing with some reaction flags). You will need to ask someone else for exact information about how to do some of the stuff, but just experimenting can get you quite a ways.

One thing: If you create all your items from lua the dwarf will not gain experience from the reaction, make sure you ad some in the script.

Edit: How are you planning to keep failures from being reprocessed?
Logged
Rubble 8 - The most powerful modding suite in existence!
After all, coke is for furnaces, not for snorting.
You're not true dwarven royalty unless you own the complete 'Signature Collection' baby-bone bedroom set from NOKEAS

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1549 on: November 21, 2014, 05:23:15 pm »

If they are just like sand, then let's just assume that they can make some sort of glass.
In the raws, sand and gems have the same basic properties (melting point, etc.) but you can't really mod the glass furnace.  I think it'd be more realistic to use gem powder as some kind of dopant to "dye" the sand, and go from there.

Would adding additional [IS_GLASS] materials make them show up at the glass furnace, and how could I possibly designate the reactions to make them?  I ask because the three vanilla glasses are hard-coded and never appear as intermediate products (you go straight from bag o' sand to green glass item).

The only other possible use I can think of for gem powder is making elixirs, which would basically be edible liquids with ingestion syndromes.
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

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1550 on: November 21, 2014, 05:31:53 pm »

DFHack is the answer: anything (well, almost anything) is possible if you use DFHack. Your best bet is to use a lua hook and do all the logic from the DFHack side of things (you need a lua hook so you can destroy the reagents if needed, AFAIK this is just a matter of playing with some reaction flags). You will need to ask someone else for exact information about how to do some of the stuff, but just experimenting can get you quite a ways.

One thing: If you create all your items from lua the dwarf will not gain experience from the reaction, make sure you ad some in the script.

Edit: How are you planning to keep failures from being reprocessed?
I have a "poof" material for reactions like that: it boils off at room temperature and makes a cloud of blue mist.

As for preventing reprocessing, that's a hard one.  If there is some individual-item-level data that's basically invisible to the player, I could encode it there.  For example, a rough gem might mass at 8 Urists and be hacked to 7 Urists by the script.  Then it just needs to check the rough gem's mass and issue an "error" if the gem's already been checked (preferably with no experience given).  If I could use a completely inappropriate property without weirding out the player (marking the rough gem as "rotten" or something), that would be great.

The important thing is that the rough gem still be a rough gem, be useable in any situation you'd normally use a rough gem, and still be the same material.
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

milo christiansen

  • Bay Watcher
  • Something generic here
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1551 on: November 21, 2014, 05:45:10 pm »

What happens if you set one of "unused" item flags? AFAIK some of them are simply unknown, but others are unused and could be set without issues (flags2.unk30 may be a good place to start).

But how will you keep dwarves from using the same item over and over? It would be easy to mark an item so the script will notice it is ineligible, but the reaction code will not handle that.

One idea: Use large gems, failures are returned as small gems. Make a reaction to produce a large gem guaranteed and you're set.
Logged
Rubble 8 - The most powerful modding suite in existence!
After all, coke is for furnaces, not for snorting.
You're not true dwarven royalty unless you own the complete 'Signature Collection' baby-bone bedroom set from NOKEAS

Sergarr

  • Bay Watcher
  • (9) airheaded baka (9)
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1552 on: November 22, 2014, 03:08:59 am »

Ok so is there any way to add descriptions to items?
I guess the lack of response means there isn't one. Crap.
Logged
._.

UnicodingUnicorn

  • Bay Watcher
  • Competent at Incompetency.
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1553 on: November 22, 2014, 10:57:18 am »

Is there a way to make a specific part of a creature, for example the left hand, to be made of a different tissue material, like steel?
Logged
I do stuff, I guess

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1554 on: November 22, 2014, 01:49:49 pm »

Is there a way to make a specific part of a creature, for example the left hand, to be made of a different tissue material, like steel?
You can coat it in steel with something like [TISSUE_LAYER:BY_TOKEN:LH:HANDSTEEL] (where HANDSTEEL is a local creature tissue you've made out of INORGANIC:STEEL) but making a standard bodypart entirely out of an odd material would require you to make your own body plan.  Basically you build a BODY of all-but-the-left-hand, apply standard tissues to it, add a separate [BODY:LEFT_HAND_OF_DOOM] which is its own tiny body plan, and apply the above tissue layer.  Since there are no other layers, the entire bodypart will be made of the stuff.

Note that this is just the hand.  It gets a bit more tedious if you want the fingers as well, but the same principles apply.
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

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1555 on: November 22, 2014, 01:53:34 pm »

If I want to make a plant that will never appear in the wild but can be planted by Dwaves if the happen upon a seed, can I just set its natural location to be [UNDERGROUND_DEPTH:4:4] and still expect it to sprout properly in an underground farm?
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

Wysthric

  • Bay Watcher
  • I'm actually Korbac! :)
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1556 on: November 22, 2014, 06:17:22 pm »

My non - material interaction isn't compiling correctly - any ideas why?

Spoiler (click to show/hide)
Logged
I'm Korbac. Not sure what happened to that account.

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1557 on: November 22, 2014, 06:45:27 pm »

There's no such thing as [CDI:ADD_SYNDROME]; that goes in the actual interaction. Nyx nyx.

Grimlocke

  • Bay Watcher
  • *kobold noises*
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1558 on: November 22, 2014, 10:11:18 pm »

Is there a way to make a specific part of a creature, for example the left hand, to be made of a different tissue material, like steel?
You can coat it in steel with something like [TISSUE_LAYER:BY_TOKEN:LH:HANDSTEEL] (where HANDSTEEL is a local creature tissue you've made out of INORGANIC:STEEL) but making a standard bodypart entirely out of an odd material would require you to make your own body plan.  Basically you build a BODY of all-but-the-left-hand, apply standard tissues to it, add a separate [BODY:LEFT_HAND_OF_DOOM] which is its own tiny body plan, and apply the above tissue layer.  Since there are no other layers, the entire bodypart will be made of the stuff.

Note that this is just the hand.  It gets a bit more tedious if you want the fingers as well, but the same principles apply.

Actually, SET_LAYER_TISSUE lets you do this without mucking with the bodypart raws. It's a funny obscure tag that I don't think is used anywhere in the stock raws but it works fine.

Tested it with this example:

[SELECT_TISSUE_LAYER:ALL:BY_TOKEN:LH]
[SET_LAYER_TISSUE:SPLEEN]

And I successfully tore the spleen tissue and bruised the spleen tissue.

I did do that with one hit though so it seems to game might handle the combat text weirdly when you have multiple layers of same tissue. Depending on your needs you might still have to go with Dirts's method.
Logged
I make Grimlocke's History & Realism Mods. Its got poleaxes, sturdy joints and bloomeries. Now compatible with DF Revised!

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: [MODDING] 0.40.x QUESTIONS THREAD
« Reply #1559 on: November 22, 2014, 10:28:34 pm »

Thanks for tip, Grimlocke.  Not sure where I might use that little tidbit, but I'm sure it will come up eventually.
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
Pages: 1 ... 102 103 [104] 105 106 ... 247