Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Trying to make a Treant creature, what tokens would you reccomend I add?  (Read 1250 times)

Urist McColeTheo

  • Bay Watcher
    • View Profile

I'm in the raw files and I'm trying to add a "treant" into the game, basically as an early-game challenge when you're attempting to chop trees after you embark.

I'm focusing on it being hostile to all but elves, and if possible, capable of disguising itself among other trees, showing you a message that you've encountered one, preferably once an axedwarf attempts to chop it down.

Generally what tokens should I look at?
Logged

smakemupagus

  • Bay Watcher
  • [CANOPENDOORS]
    • View Profile

As far as I know, none of that can be done by editing tokens; to the extent those things are possible it will involve DFHack shenanigans.

Urist McColeTheo

  • Bay Watcher
    • View Profile

Oh I see, so I couldn't just add a [TREANT] creature token into the game's raw files and add the tags from there?
Logged

smakemupagus

  • Bay Watcher
  • [CANOPENDOORS]
    • View Profile

You could certainly create a treant creature, who is strong and made of wood, and bleeds sap, and lives in the savage forest.  fine.

But there are no tokens for anything like
* hostile but not to elves
* disguises itself among trees (not even sure quite what this means, but there are no multi-tile creatures)
* pops up a message (without being a megabeast etc.)
* ambushes woodcutters

Basically, raw modding lets you access the same game mechanics that vanilla stuff already uses, not create new mechanics.  If you look up "creature tokens" on DF Wiki you will get an exhaustive list of what you can do with raws -- if it's not there, 99.99% chance it's not possible without turning to the dark side.

Urist McColeTheo

  • Bay Watcher
    • View Profile

You could certainly create a treant creature, who is strong and made of wood, and bleeds sap, and lives in the savage forest.  fine.

But there are no tokens for anything like
* hostile but not to elves
* disguises itself among trees (not even sure quite what this means, but there are no multi-tile creatures)
* pops up a message (without being a megabeast etc.)
* ambushes woodcutters

Basically, raw modding lets you access the same game mechanics that vanilla stuff already uses, not create new mechanics.  If you look up "creature tokens" on DF Wiki you will get an exhaustive list of what you can do with raws -- if it's not there, 99.99% chance it's not possible without turning to the dark side.

I see what you mean now. My phrasing was bad. When I said disguising itself among other trees I meant using a standard tree icon until you triggered it to attack you where it would take the Treant icon. Thank you anyway, that's a shame but I'm sure once dwarf fortress comes out of the alpha it'll have much more modding potential.
Logged

Random_Dragon

  • Bay Watcher
  • Psycho Bored Dragon
    • View Profile

Derp.I don't know how to replicate the original, lost-to-history versions of treants that would've been used by elves. Nor do I know how to make a creature pretend to be a plant, ESPECIALLY since we have fleshed out multi-tile trees but not multitile creatures (wagons notwithstanding).

I do however know how to make it into a megabeast. Sadly it will not count as a natural creature and this ignore elves, but the basic structure may prove useful for your modding. From my mod Adventurecraft, edited ad-hoc from the bronze colossus based off what little info the DF wiki had about treants, then altered further from there.

Spoiler (click to show/hide)
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.

smakemupagus

  • Bay Watcher
  • [CANOPENDOORS]
    • View Profile

Thank you anyway, that's a shame but I'm sure once dwarf fortress comes out of the alpha it'll have much more modding potential.

Probably so, although I would say it has a lot of modding potential already.  Just the fact that you can already drop stuff in a token language which is practically English plaintext in the raws.  And then no matter how big or small your changes you have seamless integration of your new things into the complex procedural world, it seems fairly remarkable to me.

But, yeah, you're constrained to work inside the framework of game mechanics that are there in the base game, and you run into a wall if you're brainstorming new stuff that simply doesn't exist in the code.

Roses

  • Bay Watcher
    • View Profile

You could certainly create a treant creature, who is strong and made of wood, and bleeds sap, and lives in the savage forest.  fine.

But there are no tokens for anything like
* hostile but not to elves
* disguises itself among trees (not even sure quite what this means, but there are no multi-tile creatures)
* pops up a message (without being a megabeast etc.)
* ambushes woodcutters

Basically, raw modding lets you access the same game mechanics that vanilla stuff already uses, not create new mechanics.  If you look up "creature tokens" on DF Wiki you will get an exhaustive list of what you can do with raws -- if it's not there, 99.99% chance it's not possible without turning to the dark side.

I see what you mean now. My phrasing was bad. When I said disguising itself among other trees I meant using a standard tree icon until you triggered it to attack you where it would take the Treant icon. Thank you anyway, that's a shame but I'm sure once dwarf fortress comes out of the alpha it'll have much more modding potential.

You would have to look into DFHack if you wanted to try and do something like this. It wouldn't be entirely impossible to have a tree "come to life" when it is chopped down (don't think you could do it before the actualy labor finishes, but maybe?). There are already DFHack mods that do something similar for mining and stones coming alive (originally using gas vapors that transformed the dwarf into the stone creature, and now using DFHack to spawn the creature itself).

As for making them peaceful to elves, adding the [NATURAL] tag should work, as elves have [AT_PEACE_WITH_WILDLIFE].
Logged

IndigoFenix

  • Bay Watcher
  • All things die, but nothing dies forever.
    • View Profile
    • Boundworlds: A Browser-Based Multiverse Creation and Exploration Game

The Mostly Mythical Monsters mod has passable treants based on the old ones from the earliest versions of DF.  They are NATURAL and therefore at peace with elves, made of wood, destroy buildings on sight, and leave a log when killed.  If you give them GOOD, PET_EXOTIC, and TRAINABLE_WAR, elves will bring them in sieges.  However, making them spawn from trees is impossible without DFhack, they basically function like regular wild animals.

FantasticDorf

  • Bay Watcher
    • View Profile

You could certainly create a treant creature, who is strong and made of wood, and bleeds sap, and lives in the savage forest.  fine.

But there are no tokens for anything like
* hostile but not to elves
* ambushes woodcutters

That's not nessecarily true. If you apply the [NATURAL] tag, since elves are at peace with nature, they wont aggravate (as i now have seen indigo & roses have also pointed out)

The other result could probably be done with a mixture of [LARGE_PREDATOR] and [LARGE_ROAMING] in conjunction with high natural ambusher stats (since mischievous already gives  plus stats in that field) and [AMBUSH_PREDATOR] to ensure that they do not charge at dwarves instead preferring to strike when they are in range (preferably woodcutting for the desired effect)

If you need more RAW reference for tokens, using the DFwiki - Creature Raw Tokens provided at this hyperlink may help.

If you need any more advice on ambusher stats for sneaky actions this is the DFwiki article for that DFwiki - Ambusher
« Last Edit: June 26, 2016, 06:31:11 am by FantasticDorf »
Logged

smakemupagus

  • Bay Watcher
  • [CANOPENDOORS]
    • View Profile

Yes, Fair point on [NATURAL], i forgot about that.

[AMBUSHPREDATOR] ... It works well on crocodiles (not sure if that's a vanilla thing or a Modest mod).  Of course they'll still be wild animals and can't be designated for woodcutting -- I may have been reading too much into "looks like a tree". 

Random_Dragon

  • Bay Watcher
  • Psycho Bored Dragon
    • View Profile

Yeah, [NATURAL] works if you want legit treants exactly as thy were, brought as war animal. I kinda like them as rampaging forces of nature, which sadly precludes use of the natural token.

The raw code I provided above might still be useful for fleshing out (wooding out?) the basic physical structure, at least.
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.

eerr

  • Bay Watcher
    • View Profile

Camouflage was in 40d, you just equip your dwarves with the appropriate color and they become harder to spot. It encourages real ambusher skill development.

You just need to make the creature the right colors. Pure green will probably work better against grass than tree color, but I couldn't say.
Logged