Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 217 218 [219] 220 221 ... 357

Author Topic: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)  (Read 423264 times)

Black Rabbit

  • Escaped Lunatic
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3270 on: July 12, 2011, 11:13:04 pm »

I searched, but I wasn't quite sure exactly what to search for for the answer to this, so pardon if this has already been answered.

With reactions that have a less-than-100% probability of producing their products, is it correct to say that, say, in the example below, courtesy of dividebyzero's metals mod, we have an independent 75% probability of producing plain iron, plus another independent 25% probability of producing pig iron, resulting in practice in a small probability of getting nothing, and a small probability of getting two bars?

(In other words, each probability gets its own roll and is resolved independently of any other -- instead of one roll resolving both probabilities.)

I heard it suggested that this is the case, and I was hoping someone could verify.

Mucho thankees in advance.

Code: [Select]
[REACTION:WORK_IRON_PIG]
[NAME:work pig iron]
[BUILDING:IRONWORKS:NONE]
[REAGENT:A:150:BAR:NO_SUBTYPE:METAL:PIG_IRON]
[PRODUCT:75:1:BAR:NO_SUBTYPE:METAL:IRON][PRODUCT_DIMENSION:150]
[PRODUCT:25:1:BAR:NO_SUBTYPE:METAL:PIG_IRON][PRODUCT_DIMENSION:150]
[FUEL]
[SKILL:SMELT]
Logged

narhiril

  • Bay Watcher
  • [DUTY_BOUND]
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3271 on: July 13, 2011, 12:41:40 am »

I searched, but I wasn't quite sure exactly what to search for for the answer to this, so pardon if this has already been answered.

With reactions that have a less-than-100% probability of producing their products, is it correct to say that, say, in the example below, courtesy of dividebyzero's metals mod, we have an independent 75% probability of producing plain iron, plus another independent 25% probability of producing pig iron, resulting in practice in a small probability of getting nothing, and a small probability of getting two bars?

(In other words, each probability gets its own roll and is resolved independently of any other -- instead of one roll resolving both probabilities.)

I heard it suggested that this is the case, and I was hoping someone could verify.

Mucho thankees in advance.

Code: [Select]
[REACTION:WORK_IRON_PIG]
[NAME:work pig iron]
[BUILDING:IRONWORKS:NONE]
[REAGENT:A:150:BAR:NO_SUBTYPE:METAL:PIG_IRON]
[PRODUCT:75:1:BAR:NO_SUBTYPE:METAL:IRON][PRODUCT_DIMENSION:150]
[PRODUCT:25:1:BAR:NO_SUBTYPE:METAL:PIG_IRON][PRODUCT_DIMENSION:150]
[FUEL]
[SKILL:SMELT]

I can verify that.  Each product has its own check.  This reaction would have an 18.75% chance of producing nothing, and a 18.75% chance of producing both an iron and pig iron bar, with each reaction having an independent 75% chance of an iron bar and a 25% chance of a pig iron bar.

There is currently no way that I know of to change this, as there is no way to put a hard high or low "cap" on the number of products from a reaction with percentage chances.

As such, a reaction with 100 possible products each with a 1% chance of being produced will not always produce a product, and it is also theoretically possible for that reaction to produce all 100 products at once, though the chance of this is extremely low.

It is also worth noting that skill gain is directly tied to the number of products, so a skill (in this case, smelting) will increase by twice as much as usual when the reaction produces both bars, and will not increase at all if no bars are produced.

Source: I do a lot of experimenting in my own mod with randomized reaction results to simulate "research and development" phases of engineering.

Black Rabbit

  • Escaped Lunatic
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3272 on: July 13, 2011, 01:14:59 am »

Ah well.  Thanks for verifying that, narhiril!
Logged

Charismatic

  • Bay Watcher
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3273 on: July 15, 2011, 08:21:02 pm »

I recently started modifying my game, and have a couple questions about some of the creatures I am making:

1. One of the creatures I am making is a 'carnivorous tree' kind of thing. I want it to be immobile, but still capable of attacking and eating dwarves. Is there any tag or body type that stops it from wandering around?
2. Another creature I am trying to make is a shadowman. If i give them only one tissue layer (made of a custom 'shadowflesh') will they act as normal, or do they need an underlying skeleton?
3. If I make a race whose bodies are made out of wood,with different types serving as different tissues (i.e. a flexible wood for the tendons/ligaments, a harder type for bones, etc.) will they leave a usable wood item if they are butchered without making their corpse explicitly be an item? If so, is there any way to keep my dwarves from eating *twigman wood roasts*?
Logged
Oh, and I also found a second continent, "The Released Syrup-Continents". It houses "The Finger of Silkness". I think I died a little inside.

Greiger

  • Bay Watcher
  • Reptilian Illuminati member. Keep it secret.
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3274 on: July 15, 2011, 08:26:36 pm »

1. Try [IMMOBILE_LAND] if they get submerged somehow they may swim around but that should keep them from moving under normal situations

2. Should work fine.

3. That is a little tricky.  It should be possible, but that is a bit more into unusual tissue layers than I have ever delved, if no-one answers experimentation should eventually get you what you want, but hopefully somebody else can give you more to go on..
Logged
Disclaimer: Not responsible for dwarven deaths from the use or misuse of this post.
Quote
I don't need friends!! I've got knives!!!

narhiril

  • Bay Watcher
  • [DUTY_BOUND]
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3275 on: July 15, 2011, 10:34:33 pm »

I recently started modifying my game, and have a couple questions about some of the creatures I am making:

1. One of the creatures I am making is a 'carnivorous tree' kind of thing. I want it to be immobile, but still capable of attacking and eating dwarves. Is there any tag or body type that stops it from wandering around?
2. Another creature I am trying to make is a shadowman. If i give them only one tissue layer (made of a custom 'shadowflesh') will they act as normal, or do they need an underlying skeleton?
3. If I make a race whose bodies are made out of wood,with different types serving as different tissues (i.e. a flexible wood for the tendons/ligaments, a harder type for bones, etc.) will they leave a usable wood item if they are butchered without making their corpse explicitly be an item? If so, is there any way to keep my dwarves from eating *twigman wood roasts*?

The shadow race should work fine.  I did a similar thing for a creature once that worked.

--

The last one is a little bit more difficult.  This might require some significant trial and error, and probably requires a fair bit of modding experience with creatures, reactions, and material tokens.  It's possible to define these tissues, give them the proper names, and prevent butchering.  If you wanted them to actually yield usable wood without using an itemcorpse token, that's a bit more difficult...  This is a challenge that I have never personally tackled, but I'll give it a go.

Technically, it SHOULD be possible.  What you would need to do is set up a new reaction that takes a corpse of this specific creature and produces wood, although you would have to assign it to a building that wasn't hard coded (a custom one would be a good solution).  The problematic part is the actual lines of the reaction code...



The problem is going to come from the bold line, which is obviously missing a fair number of parameters.  The issue here is that I don't fully understand how DF handles corpses as objects - as in, specifically, what material is a "corpse" of a creature made from if the creature consists of multiple materials?  Bearing that in mind, the first thing I would try is this:

[REAGENT:A:1:CORPSE:NONE:CREATURE_MAT:(creature ID):NONE]

What this *should* do is designate any corpse of a material belonging to that creature as eligible to be used for the reaction.  What it will *actually* do is take any object, corpse or otherwise, of a material belonging to that creature as a reagent (because the CORPSE tag is currently broken and the game treats it exactly the same as NONE).  My guess is that this will result in one of two things...


1) The reaction not recognizing anything as a possible reagent (possible if DF does not handle materials of body parts in the way it handles others).  If this is the case, I'm afraid I'm outside of my field of experience.


2) The reaction using any body part of the creature in question, rather than just the corpse.  This will likely mean that severing a limb before killing the creature will yield twice as much wood (two reactions worth of reagents), even though this doesn't make any sense.  Nevertheless, it is similar to the intended result.

--

Unfortunately, that's the closest approximation I can come up with right now.  Hopefully at least something in this post helps you out.
« Last Edit: July 15, 2011, 10:40:23 pm by narhiril »
Logged

Karnewarrior

  • Bay Watcher
  • That guy who used to be here all the time
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3276 on: July 15, 2011, 11:03:48 pm »

Is it possible to work a breath attack into a modded creature that boils at a low temprature and thusly freezes dwarves in the like but doesn't kill the creature itself? I'm trying to make Frost Dragons.
Logged
Thou art I, I art Thou.
The trust you have bestowed upon thy comrade is now reciprocated in turn.
Thou shall be blessed when calling upon personae of the Hangman Arcana.
May this tie bind thee to a brighter future!​
Ikusaba Quest! - Fistfighting space robots for the benefit of your familial bonds to Satan is passe, so you call Sherlock Holmes and ask her to pop by.

TomiTapio

  • Bay Watcher
  • OldGenesis since 2012
    • View Profile
    • My Flickr animal photos
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3277 on: July 16, 2011, 06:15:24 am »

Is it possible to work a breath attack into a modded creature that boils at a low temprature and thusly freezes dwarves in the like but doesn't kill the creature itself? I'm trying to make Frost Dragons.
It is possible, and Genesis mod already has frost wyrms / blue dragons.
Spoiler (click to show/hide)
Logged
==OldGenesis mod== by Deon & TomiTapio. Five wood classes, four leather classes. Nine enemy civs. So much fine-tuning.
47.05e release: http://dffd.bay12games.com/who.php?id=1538
OldGenesis screenshots: https://twitter.com/hashtag/OldGenesis?src=hashtag_click&f=image
My Finnish language file: http://dffd.bay12games.com/file.php?id=14884

Karnewarrior

  • Bay Watcher
  • That guy who used to be here all the time
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3278 on: July 16, 2011, 11:21:26 am »

 :(
It isn't quite having the intended effect...

My Frost Dragon seems to be lighting me on fire...
Logged
Thou art I, I art Thou.
The trust you have bestowed upon thy comrade is now reciprocated in turn.
Thou shall be blessed when calling upon personae of the Hangman Arcana.
May this tie bind thee to a brighter future!​
Ikusaba Quest! - Fistfighting space robots for the benefit of your familial bonds to Satan is passe, so you call Sherlock Holmes and ask her to pop by.

arclance

  • Bay Watcher
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3279 on: July 16, 2011, 12:35:29 pm »

I recently started modifying my game, and have a couple questions about some of the creatures I am making:

1. One of the creatures I am making is a 'carnivorous tree' kind of thing. I want it to be immobile, but still capable of attacking and eating dwarves. Is there any tag or body type that stops it from wandering around?
2. Another creature I am trying to make is a shadowman. If i give them only one tissue layer (made of a custom 'shadowflesh') will they act as normal, or do they need an underlying skeleton?
3. If I make a race whose bodies are made out of wood,with different types serving as different tissues (i.e. a flexible wood for the tendons/ligaments, a harder type for bones, etc.) will they leave a usable wood item if they are butchered without making their corpse explicitly be an item? If so, is there any way to keep my dwarves from eating *twigman wood roasts*?

The shadow race should work fine.  I did a similar thing for a creature once that worked.

--

The last one is a little bit more difficult.  This might require some significant trial and error, and probably requires a fair bit of modding experience with creatures, reactions, and material tokens.  It's possible to define these tissues, give them the proper names, and prevent butchering.  If you wanted them to actually yield usable wood without using an itemcorpse token, that's a bit more difficult...  This is a challenge that I have never personally tackled, but I'll give it a go.

Technically, it SHOULD be possible.  What you would need to do is set up a new reaction that takes a corpse of this specific creature and produces wood, although you would have to assign it to a building that wasn't hard coded (a custom one would be a good solution).  The problematic part is the actual lines of the reaction code...



The problem is going to come from the bold line, which is obviously missing a fair number of parameters.  The issue here is that I don't fully understand how DF handles corpses as objects - as in, specifically, what material is a "corpse" of a creature made from if the creature consists of multiple materials?  Bearing that in mind, the first thing I would try is this:

[REAGENT:A:1:CORPSE:NONE:CREATURE_MAT:(creature ID):NONE]

What this *should* do is designate any corpse of a material belonging to that creature as eligible to be used for the reaction.  What it will *actually* do is take any object, corpse or otherwise, of a material belonging to that creature as a reagent (because the CORPSE tag is currently broken and the game treats it exactly the same as NONE).

You can make this reaction work by adding
[REACTION_CLASS:FLESH_WOOD] to the material template used for the body parts you want to use in the reaction.
and using this line for the reagent in the reaction
[REAGENT:A:1:NONE:NONE:NONE:NONE][REACTION_CLASS:FLESH_WOOD] this will use anything made out of a material with [REACTION_CLASS:FLESH_WOOD]
If you want to make a new type of wood you will need to make a new plant that only has wood to use in the product line
[PRODUCT:100:(number of logs):WOOD:NONE:PLANT_MAT:(tree ID):(material ID)]
Use a different REACTION_CLASS for each different type of wood you want to make.
Logged
I think that might be one of the most dwarfen contraptions I've ever seen the blueprints of.
The Bloodwinery v1.3.1 | Dwarven Lamination v1.5 | Tileset Resizer v2.5 - Mac Beta Tester Needed
Sigtext

Eldrick Tobin

  • Bay Watcher
  • [ETHIC: MODDING_UNDWARFY: PERSONAL_MATTER]
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3280 on: July 16, 2011, 05:39:57 pm »

So say you wanted to make a... easy example drop... IN: Giant Cave Spider :have a CHITIN made of Slade. Just the chitin, only that layer, no where else.

Anyone have any MORE ideas I might try? It hasn't seemed to work right so far.


And yeah I'm trying to avoid the Bronze Colossus situation of [TISSUE_LAYER:BY_CATEGORY:ALL:SLADE], but I'm having trouble nailing down BY_CATEGORY, BY_TYPE, BY_TOKEN in relation to which thing is which.


Help! My flavor_spiders must live ;.; (well they live... but even against a level 2 combatant they don't last exceptionally long)*continues rambling for hours*
Logged
--
Eldrick Tobin
Behold the unimpressive Aspectus Lolin mod. || My Little Arachnid Fortress attempt...
I mumble to myself on tumblr... Sometimes about DF Modding.

Sphalerite

  • Bay Watcher
    • View Profile
    • Drew's Robots and stuff
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3281 on: July 16, 2011, 06:08:42 pm »

I think you're going to want something like this:

Spoiler (click to show/hide)

This will be in place of the line that just says [BODY_DETAIL_PLAN:CHITIN_TISSUES] in your creature raws.  This imports all the normal tissues of the spider, then removes CHITIN, then declares a new CHITIN tissue with the tissue material replaced by slade.
Logged
Any intelligent fool can make things bigger and more complex... It takes a touch of genius --- and a lot of courage to move in the opposite direction.

Charismatic

  • Bay Watcher
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3282 on: July 16, 2011, 08:17:40 pm »

Welp, the carnivorous tree works just as expected. The only problem is, because [LAND_IMMOBILE] implies [AQUATIC], I had to give them [NO_BREATHE] so they wouldn't airdrown. I haven't tested the other two, mainly because my sister's playing Wizard101 and she has issues with sharing computer time. She has issues with everything else, too, but that's a different story.
Logged
Oh, and I also found a second continent, "The Released Syrup-Continents". It houses "The Finger of Silkness". I think I died a little inside.

stabbymcstabstab

  • Bay Watcher
  • OW SNAP!
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3283 on: July 16, 2011, 08:26:46 pm »

magma my friend can solve all you problemsor a battle axe that works too
Logged
Long Live Arst- United Forenia!
"Wanna be a better liberal? Go get shot in the fuckin' face."
Contemplate why we have a sociopathic necrophiliac RAPIST sadomasochist bipolar monster in our ranks, also find some cheese.

Ultimuh

  • Bay Watcher
  • BOOM! Avatar gone! (for now)
    • View Profile
Re: 0.31. MODDERS WORKSHOP (NEWCOMERS WELCOME!)
« Reply #3284 on: July 16, 2011, 10:05:32 pm »

I made something to put in the description_shape_standard txt.
It's rather monstrous tough.  :P
And there are probably some typos in there..

Code: [Select]
[SHAPE:ADVENTURER]
[NAME:adventurer:adventurers]
[ADJ:male]
[ADJ:female]
[ADJ:Human]
[ADJ:Dwarven]
[ADJ:Elven]
[ADJ:Goblin]
[ADJ:Gnome]
[ADJ:colossal]
[ADJ:brave]
[ADJ:cowardly]
[ADJ:honorable]
[ADJ:dishonest]
[ADJ:fiendish]
[ADJ:evil]
[ADJ:zealous]
[ADJ:armed]
[ADJ:attacking]
[ADJ:victorious]
[ADJ:defeated]
[ADJ:dead]
[ADJ:sneaky]
[ADJ:cunning]
[ADJ:posing]
[ADJ:sexy]
[ADJ:buff]
[ADJ:flexing]
[ADJ:insane]
[ADJ:pyromaniac]
[ADJ:silly]
[ADJ:dumb]
[ADJ:stupid]
[ADJ:laughing]
[ADJ:cringing]
[ADJ:lonely]
[ADJ:friendly]
[ADJ:heroic]
[ADJ:devilish]
[ADJ:naked]
[ADJ:poor]
[ADJ:rich]
[ADJ:fleeing]
[ADJ:sleeping]
[ADJ:disturbed]
[ADJ:disturbing]
[ADJ:cocky]
[ADJ:hanged]
[ADJ:stabbed]
[ADJ:executed]
[ADJ:exiled]
[ADJ:hopeless]
[ADJ:demanding]
[ADJ:adventurous]
[ADJ:exploring]
[ADJ:slain]
[ADJ:scared]
[ADJ:spelunking]
[ADJ:terrified]
[ADJ:terrifying]
[ADJ:bathing]
[ADJ:swimming]
[ADJ:tolerated]
[ADJ:incapacitated]
[ADJ:stunned]
[ADJ:blind]
[ADJ:blinded]
[ADJ:mute]
[ADJ:muted]
[ADJ:poisoned]
[ADJ:dieing]
[ADJ:intoxicated]
[ADJ:drunk]
[ADJ:bragging]
[ADJ:godless]
[ADJ:zealous]
[ADJ:pious]
[ADJ:unharmed]
[ADJ:wounded]
[ADJ:stricken]
[ADJ:Diseased]
[ADJ:rotting]
[ADJ:rotten]
[ADJ:bitten]
[ADJ:eaten]
[ADJ:troubled]
[ADJ:troublesome]
[ADJ:ancient]
[ADJ:tribal]
[ADJ:unimportant]
[ADJ:futuristic]
[ADJ:laughable]
[ADJ:facepalming]
[ADJ:facepalmed]
[ADJ:dirty]
[ADJ:clean]
[ADJ:lawful]
[ADJ:unlawful]
[ADJ:thieving]
[ADJ:captured]
[ADJ:imprisoned]
[ADJ:beheaded]
[ADJ:prideful]
[ADJ:royal]
[ADJ:noble]
[ADJ:common]
[ADJ:wealthy]
[ADJ:fat]
[ADJ:obese]
[ADJ:powerful]
[ADJ:weak]
[ADJ:tall]
[ADJ:short]
[ADJ:impaled]
[ADJ:trapped]
[ADJ:unlucky]
[ADJ:lucky]
[ADJ:blessed]
[ADJ:cursed]
[ADJ:almighty]
[ADJ:mighty]
[ADJ:cheating]
[ADJ:overpowered]
[ADJ:invincible]
[TILE:'@']
« Last Edit: July 16, 2011, 11:47:31 pm by Ultimuh »
Logged
Pages: 1 ... 217 218 [219] 220 221 ... 357