Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 17 18 [19] 20 21 ... 61

Author Topic: [SUGGESTIONS] for DFhack plugins  (Read 143325 times)

PeridexisErrant

  • Bay Watcher
  • Dai stihó, Hrasht.
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #270 on: July 18, 2013, 01:46:33 am »

Would anyone be up for whipping up a script like soundsense-season, to add information to the gamelog on load that can identify the world?  I'm thinking of something like "Loaded RegionX, [dwarfname] [translatedname]".   

There's a nice little utility called Story Maker which could take advantage of something like this in the next version, but it would also be nice for flavor and tracking activity across different forts manually.  It would also potentially allow someone to build a plugin that lets DF show gamelog info from previous sessions, which could be nice for people who play in short bursts. 

Update:  Done.  Thanks to those who helped; it's included in my LNP or available at the link. 
« Last Edit: July 31, 2013, 10:25:30 pm by PeridexisErrant »
Logged
I maintain the DF Starter Pack - over a million downloads and still counting!
 Donations here.

Laggy

  • Bay Watcher
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #271 on: July 18, 2013, 12:23:10 pm »

Quote
Targeting only worn clothing with a reaction
- Possible: PROBABLY NO
 - Makes cleaning up worn clothing a lot easier
 - Could be used for a "burn worn clothing" or "recycle thread from worn clothing" reaction.

I'm just now seeing this, but why is this supposedly impossible?  You can have reactions trigger dfhack scripts now, correct?

I wrote a script months ago that removed the wear from all of the items in the fort just because I was tired of constantly making clothing.  To me, it seems that if you can target all of the items with wear, then targetting one item with wear should be pretty simple?  Although it might be hard to target a SPECIFIC item, it just seems to be like a "Hey, burn any clothing with wear > 3" should be perfectly possible.

For reference:

Spoiler: removewear.lua (click to show/hide)
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #272 on: July 18, 2013, 12:31:11 pm »

Targeting clothes should be easy, since they're all contained in the unit's inventory.

expwnent

  • Bay Watcher
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #273 on: July 18, 2013, 01:36:00 pm »

The probably impossible part is making the reaction only target worn clothing, preventing it from just always retargetting the same shoe over and over, and so on. It's probably possible if you really try hard enough, but it would be awkward at best and could result in a lot of job cancellation spam.
Logged

Kurik Amudnil

  • Bay Watcher
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #274 on: July 18, 2013, 01:37:43 pm »

could also use a two job cycle, where the first job runs the script that selects the damaged clothing for the second job which it creates (would want to have a free job slot in the workshop for the new job).  This way it can exclude the clothing worn by the worker.

expwnent

  • Bay Watcher
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #275 on: July 18, 2013, 01:43:40 pm »

I'm not sure if jobs like that preselect job items before they are started. If not, you'd just have to swoop in and change the job item every time such a workshop job is initiated and change the job item to something appropriate by doing an annoying pathfinding thing to locate all worn clothing, and cancel the job nicely if there is no worn clothing. It's possible, just more difficult than it seems at first glance. Framerate would only be a minor issue, because the percentage of frames on which the slow part of the script runs would be small, but of course, if there are a lot of different scripts that each have only a minor impact on framerate, the slowdown would add up over time.
Logged

Laggy

  • Bay Watcher
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #276 on: July 18, 2013, 01:58:50 pm »

The probably impossible part is making the reaction only target worn clothing, preventing it from just always retargetting the same shoe over and over, and so on. It's probably possible if you really try hard enough, but it would be awkward at best and could result in a lot of job cancellation spam.
Admittedly I know nothing about actual DF modding, only scipting in general.  Maybe I'm just missing something about how the reactions work.  I would think that if you had a script that returned an item with wear, and did something with it in a reaction to make it either not exist anymore or not have wear anymore, that the next time you ran the script it wouldn't be selecting the same item again.  But maybe because of the tick system, that just doesn't work?
Logged

thistleknot

  • Bay Watcher
  • Escaped Normalized Spreadsheet Berserker
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #277 on: July 18, 2013, 07:29:44 pm »

auto-dump items that produce miasma?  Preferably items that are not alive (mwmod has miasma producing rotten limbs that are attached to dwarfs)

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #278 on: July 20, 2013, 03:30:51 pm »

Rotten limbs still attached to dwarves can happen in vanilla, too

WillowLuman

  • Bay Watcher
  • They/Them Life is weird
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #279 on: July 20, 2013, 08:02:29 pm »

Has the OP been updated? I thought that power-dependent workshops had been confirmed to be possible.
Logged
Dwarf Souls: Prepare to Mine
Keep Me Safe - A Girl and Her Computer (Illustrated Game)
Darkest Garden - Illustrated game. - What mysteries lie in the abandoned dark?

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: [SUGGESTIONS] for DFhack plugins
« Reply #280 on: July 20, 2013, 08:04:47 pm »

Hasnt been updated... I didnt get much info though, so I wouldnt know what to change on the opening post.

Aboveground-only buildings would be nice. ^^
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

thistleknot

  • Bay Watcher
  • Escaped Normalized Spreadsheet Berserker
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #281 on: July 21, 2013, 05:35:20 pm »

auto-explore plugin for military dwarf's.  I could use my vampires to explore the caverns without me needing to constantly reissue stationary orders

thistleknot

  • Bay Watcher
  • Escaped Normalized Spreadsheet Berserker
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #282 on: July 21, 2013, 10:58:39 pm »

Workshop profile saves.  I.e. I'm playing mwmod and a lot of the libraries are only useful to specific group of dwarf's.  It would be nice if I could say, create a military grouping of dwarf's for the Profile, and then just load it while I'm inside the tavern's profile...  Hope that makes sense, would apply to other buildings as well.  Seems like something Falconne would be great at...

expwnent

  • Bay Watcher
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #283 on: July 23, 2013, 04:50:04 pm »

Hasnt been updated... I didnt get much info though, so I wouldnt know what to change on the opening post.

Aboveground-only buildings would be nice. ^^

Already been implemented for the next release.
Logged

Sutremaine

  • Bay Watcher
  • [ETHIC:ATROCITY: PERSONAL_MATTER]
    • View Profile
Re: [SUGGESTIONS] for DFhack plugins
« Reply #284 on: July 23, 2013, 07:13:22 pm »

I'd like something that allows animals to be treated medically the same way dwarves are treated. A manual switch between 'treat as animal' and 'treat as dwarf' would be fine.
Logged
I am trying to make chickens lay bees as eggs. So far it only produces a single "Tame Small Creature" when a hen lays bees.
Honestly at the time, I didn't see what could go wrong with crowding 80 military Dwarves into a small room with a necromancer for the purpose of making bacon.
Pages: 1 ... 17 18 [19] 20 21 ... 61