Bay 12 Games Forum

Please login or register.

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

Author Topic: [MODDING] 0.47.x General modding questions thread - lots of new stuff!  (Read 136253 times)

Untrustedlife

  • Bay Watcher
    • View Profile
    • My Website
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #15 on: January 29, 2020, 04:03:28 pm »

I did some tests with summoning. So far, everything points out that you cannot specify a creature and instead can only do random summons based on the presence or absence of tokens.

And that sucks.

I DID SOME TESTING!


I made the summon interaction this:
[INTERACTION:EXAMPLE SUMMON]
   [I_TARGET:A:LOCATION]
      [IT_LOCATION:CONTEXT_LOCATION]
   [I_TARGET:B:LOCATION]
      [IT_LOCATION:RANDOM_NEARBY_LOCATION:A:5]
   [I_EFFECT:SUMMON_UNIT]
      [IE_TARGET:B]
      [IE_IMMEDIATE]
      [IE_FORBIDDEN_CREATURE_FLAG:MAMMAL]
      Also available: IE_CREATURE_FLAG, IE_FORBIDDEN_CREATURE_FLAG, IE_FORBIDDEN_CREATURE_CASTE_FLAG
      [IE_TIME_RANGE:200:300]

AND IT Appeared to work, it didnt summon any animals with the MAMMAL Class, just various animal people/birds It also didnt give any sort of error.

But my testing is limited, so someone else should also do it just to be sure the science works.

It doesn't reproduce for me, I'm afraid :(. I get giant raccoons and tapirs by repeating exactly, and when I revert it by using IE_CREATURE_FLAG:MAMMAL I get lorikeets and a bogeyman(!). This means I got to see the boogieman transformation live though, as it shifted into a cheetah and proceeded to slaughter one of my testing dwarves before vanishing as its summoning timer ran out.
damn. I hope theres some way. I want to make an orc summoning interaction.
Logged
I am an indie game dev!
My Roguelike! With randomly generated creatures Roguelegends: Dark Realms
My Turn Based Strategy game! Which you can buy on steam now!DR4X
My website untrustedlife.com

Warlord255

  • Bay Watcher
  • Master Building Designer
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #16 on: January 29, 2020, 04:08:47 pm »

Normally this would prevent goblin civs entirely from appearing in the world, but if there are any UNIQUE_DEMONs defined in the raws, then only those will appear as leaders of gobbos.

Holy crap! This is an incredible tool. Most delightfully, it could be possible to flip the "demons" into a series of nature-themed monsters and make Elves the demon-worshippers!
Logged
DF Vanilla-Spice Revised: Better balance, more !!fun!!
http://www.bay12forums.com/smf/index.php?topic=173907.msg7968772#msg7968772

LeadfootSlim on Steam, LeadfootSlim#1851 on Discord. Hit me up!

iceball3

  • Bay Watcher
  • Miaou~
    • View Profile
    • My DA
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #17 on: January 29, 2020, 05:31:16 pm »

A bit of a pain that the summoning interaction happens to have the limitation of "only random creatures not on the blacklist", but if it can be made to consistently spawn a debug creature and transform it/give it interactions, it'll open up a whooole lot of interaction loops that I believe were entirely dependent on dfhack before to work i think.
Will the interactions system finally become turing complete? ;P
Logged

LargeSnail

  • Bay Watcher
  • Sluggish Modder
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #18 on: January 29, 2020, 07:20:31 pm »

My current research:
Summoning creatures in Fortress Mode via interactions sets them as friendly to the fort.


I used the MAGICAL token in the raws of my Gabbro Golems to force the dwarves to only summon them.

Code: [Select]
[CREATURE:GOLEM_GABBRO]
[DESCRIPTION:Living gabbro in the shape of a man.  These strange creatures are found deep underground.]
[NAME:gabbro golem:gabbro golems:gabbro golem]
[CASTE_NAME:gabbro golem:gabbro golems:gabbro golem]
[CREATURE_TILE:'G'][COLOR:0:0:1]
[PETVALUE:1000]
[NOPAIN][EXTRAVISION][NOBREATHE][NOSTUN][NONAUSEA][NOEMOTION]
[NOTHOUGHT][NOEXERT]
[NO_DIZZINESS]
[NO_FEVERS]
[INTELLIGENT][SLOW_LEARNER]
[NO_DRINK][NO_EAT][NO_SLEEP]
[NOT_LIVING][MAGICAL][PET]
[CANOPENDOORS]
[EQUIPS]
[NOT_BUTCHERABLE]
[NOFEAR]
[PREFSTRING:rockiness]
[ODOR_LEVEL:0] no smell
[SMELL_TRIGGER:10000] cannot smell
[NOBONES]
[APPLY_CREATURE_VARIATION:STANDARD_BIPED_GAITS:900:750:600:439:1900:2900] 20 kph
[APPLY_CREATURE_VARIATION:STANDARD_CLIMBING_GAITS:2990:2257:1525:731:4300:6100] 12 kph
[APPLY_CREATURE_VARIATION:STANDARD_CRAWLING_GAITS:2990:2257:1525:731:4300:6100] 12 kph
[BODY:HUMANOID_SIMPLE]
[NO_THOUGHT_CENTER_FOR_MOVEMENT]
[TISSUE:ROCK]
[TISSUE_NAME:gabbro:NP]
[TISSUE_MATERIAL:INORGANIC:GABBRO]
[MUSCULAR]
[FUNCTIONAL]
[STRUCTURAL]
[RELATIVE_THICKNESS:1]
[CONNECTS]
[TISSUE_SHAPE:LAYER]
[TISSUE_LAYER:BY_CATEGORY:ALL:ROCK]
[BODY_SIZE:0:0:70000]
[BODY_APPEARANCE_MODIFIER:HEIGHT:90:95:98:100:102:105:110]
[BODY_APPEARANCE_MODIFIER:BROADNESS:90:95:98:100:102:105:110]
[ATTACK:PUNCH:BODYPART:BY_TYPE:GRASP]
[ATTACK_SKILL:GRASP_STRIKE]
[ATTACK_VERB:punch:punches]
[ATTACK_CONTACT_PERC:100]
[ATTACK_PREPARE_AND_RECOVER:3:3]
[ATTACK_FLAG_WITH]
[ATTACK_PRIORITY:MAIN]
[ATTACK:KICK:BODYPART:BY_TYPE:STANCE]
[ATTACK_SKILL:STANCE_STRIKE]
[ATTACK_VERB:kick:kicks]
[ATTACK_CONTACT_PERC:100]
[ATTACK_PREPARE_AND_RECOVER:4:4]
[ATTACK_FLAG_WITH]
[ATTACK_PRIORITY:SECOND]
[ATTACK_FLAG_BAD_MULTIATTACK]
[ITEMCORPSE:BOULDER:NO_SUBTYPE:INORGANIC:GABBRO]
[ALL_ACTIVE]

Edit: Adding IE_MAKE_PET_IF_POSSIBLE to the interaction makes the summoned creature a pet of the summoner.


The summoned creature is unable to work, much like a trained gremlin.

Spoiler: The interaction (click to show/hide)
« Last Edit: January 29, 2020, 08:01:54 pm by LargeSnail »
Logged

Scruiser

  • Bay Watcher
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #19 on: January 29, 2020, 08:52:56 pm »

Normally this would prevent goblin civs entirely from appearing in the world, but if there are any UNIQUE_DEMONs defined in the raws, then only those will appear as leaders of gobbos.

Holy crap! This is an incredible tool. Most delightfully, it could be possible to flip the "demons" into a series of nature-themed monsters and make Elves the demon-worshippers!

An old thread response I found seems to indicate a few more limitations on that.  I have not tested this  for 47.01...

http://www.bay12forums.com/smf/index.php?topic=163667.msg7416609#msg7416609:

Quote
If memory serves, to start with a Demon ruler (as goblins do), a civ must have the Dark Tower site type, no RELIGION token, and VARIABLE_POSITIONS:ALL.

Toady might have loosened the requirments when making [DEMON] and [UNIQUE_DEMON] available in the RAWs, so I guess this needs to be checked via trial and error in world generation.  Even within the thread I linked it seems uncertain, you can have hard coded positions in addition to variable positions, it's just some may cause crashes when conflicting with the demon position.

Another old thread response with some relevant information: http://www.bay12forums.com/smf/index.php?topic=110027.msg6920786#msg6920786

Quote
Closest I know of at the moment is that a [SUPERNATURAL] creature that has taken a leadership role using its [POWER] token may write books about secrets if the secret and the creature both share a [SPHERE], which is [SPHERE:DEATH] for the default necromancy.

In a few of my own tests in 44.12, it seemed this technique was not working on individual custom castes added to standard races, but from other mods (in particular Spellcraft's Wizard race http://www.bay12forums.com/smf/index.php?topic=149426.0), it seem to work on when used on entire creatures (and not individual castes)?

So you could make custom demons, give them each a mix of thematically appropriate spheres, then make spells for various spheres with various mixes of MUNDANE_TEACHING_POSSIBLE and MUNDANE_RECORDING_POSSIBLE, so that the resulting nature themed demon led civs then get various.  And add various uncivilized creatures with the [POWER] and [SUPERNATURAL] tokens and various spheres to further go along with this theme.

One thing worth checking... if the elfs don't get driven out for immortality, will the elf necromancers still create undead lieutenants and/or experiments if given war/conquest to give them raw materials?  I don't see what the tokens are for allowing experiments or setting what the experiments are (maybe not available in RAWs yet?), but if they do get made available in RAW some nature themed experiments would be fun.  Likewise for nature themed intelligent undead... 
« Last Edit: January 29, 2020, 09:01:48 pm by Scruiser »
Logged
Things I have never done in Dwarf Fortress;

- Won.

Random_Dragon

  • Bay Watcher
  • Psycho Bored Dragon
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #20 on: January 30, 2020, 12:13:20 am »

There's also this:
Code: [Select]
[SKILL_ROLL_RANGE:<basic range>:<multiplier>]
The skill roll is: random(basic range) + random((skill level * multipler)/2 + 1) + random((skill level * multipler)/2 + 1)
random(x) returns a number between 0 and x-1, so basic range is always 1 or more.  The default is 11.
The default multiplier is 5.
[SKILL_IP:<integer>]  Default is 30.
[ATTRIBUTE_IP:<integer>]  Default is 10.

I'm not 100% sure what skill roll range does, and the last two are a complete mystery to me. Seems to have no current usage in the raws.
Logged
On DF Wiki · On DFFD

"Hey idiots, someone hacked my account to call you all idiots! Wasn't me you idiots!" seems to stretch credulity a bit.

Nahere

  • Bay Watcher
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #21 on: January 30, 2020, 01:57:21 am »

SKILL_IP and ATTRIBUTE_IP presumably govern how much the reaction skill and it's associated attributes are increased by performing the reaction. I know that skill exp used to be 30 per product, I wonder if it still scales when you use those tokens?
Logged

FantasticDorf

  • Bay Watcher
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #22 on: January 30, 2020, 06:20:02 am »

SKILL_IP and ATTRIBUTE_IP presumably govern how much the reaction skill and it's associated attributes are increased by performing the reaction. I know that skill exp used to be 30 per product, I wonder if it still scales when you use those tokens?

I misunderstood this the first time i saw it without a bit of dissection here.

Assumedly you could have a workshop that trains philosophy (a abstract skill) by bringing paper to it, then increase their intellectualism and skills like memory through the modifier for training benches. Going off physical and mental attributes.
Logged

Nahere

  • Bay Watcher
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #23 on: January 30, 2020, 06:27:53 am »

I can't seem to get item summoning to work with a location, but it works with a creature, and can summon water. That is, [IE_ITEM:100:3000:LIQUID_MISC:NONE:WATER:NONE] creates a tile of water on your target. Presumably it does magma as well.
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #24 on: January 30, 2020, 07:27:53 am »

(I)m(P)rovement, I assume, and yeah, that's super useful.

I can't seem to get item summoning to work with a location, but it works with a creature, and can summon water. That is, [IE_ITEM:100:3000:LIQUID_MISC:NONE:WATER:NONE] creates a tile of water on your target. Presumably it does magma as well.

I knew it. That's wonderful.

Warlord255

  • Bay Watcher
  • Master Building Designer
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #25 on: January 30, 2020, 07:44:15 am »

I can't seem to get item summoning to work with a location, but it works with a creature, and can summon water. That is, [IE_ITEM:100:3000:LIQUID_MISC:NONE:WATER:NONE] creates a tile of water on your target. Presumably it does magma as well.

You tried with the "random nearby location"? I was hoping to use that for an upgraded Bonfire that won't kill furnace operators... more testing required, I suppose.
Logged
DF Vanilla-Spice Revised: Better balance, more !!fun!!
http://www.bay12forums.com/smf/index.php?topic=173907.msg7968772#msg7968772

LeadfootSlim on Steam, LeadfootSlim#1851 on Discord. Hit me up!

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #26 on: January 30, 2020, 07:56:20 am »

Oh, I should note: IE_ITEM_QUALITY:SUPERIOR has generated no errors for me.

EDIT: Clearly, I was mistaken, cause it's not in the strings I've just datamined near ARTIFACT. Huh. Anyway, OP updated with datamined strings that can be presumably be used for new interaction effects.
« Last Edit: January 30, 2020, 08:08:30 am by Putnam »
Logged

Asin

  • Bay Watcher
  • A short and sturdy creature fond of modding.
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #27 on: January 30, 2020, 08:21:16 am »

Question: What has been added to entities, besides the new naming rules for merchant companies and the like?

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #28 on: January 30, 2020, 08:25:48 am »

Question: What has been added to entities, besides the new naming rules for merchant companies and the like?

A bunch of new flavorful position responsibilities and, if you stretch the term "added to entities", the ability to raw-define UNIQUE_DEMONs.

pikachu17

  • Bay Watcher
  • PADORU PADORU
    • View Profile
Re: [MODDING] 0.47.x General modding questions thread - lots of new stuff!
« Reply #29 on: January 30, 2020, 08:26:21 am »

Is there any way to limit summonings to a specific class?

Also, if there isn't, the token MAGICAL will be useful for summons, since it has no actul use AFAIK.

Those of you have wiki accounts, please add this stuff to the wiki.

Will creatures with [DEMON] show up in the underworld?

Can someone show me their code for a functioning item summon?

What does RAISE_GHOST do?
« Last Edit: January 30, 2020, 09:11:54 am by pikachu17 »
Logged
Sigtext!
dwarf 4tress from scratch
The Pikachu revolution!
Thank you NatureGirl19999 for the avatar switcher at http://signavatar.com

A warforged bard named Gender appears and says"Hello. I am a social construct."
Pages: 1 [2] 3 4 ... 61