Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 215 216 [217] 218 219 ... 243

Author Topic: DFHack 50.12-r3  (Read 807883 times)

Gnomedevourer

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3240 on: November 12, 2022, 01:31:38 pm »

Is Advfort's tame animal job bugged? I couldn't get it to work, sadly, or was it always kind of not something possible to do?
if it is, is there any way for me to try and "tame" animals in adv mode?
(sorry if this is kind of out of place but this seemed like the right place to me at the time)
« Last Edit: November 12, 2022, 01:34:21 pm by Gnomedevourer »
Logged
tried to balance a mod, once upon a time, fell and scraped my knee, ain't doing that again.

Rumrusher

  • Bay Watcher
  • current project : searching...
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3241 on: November 13, 2022, 02:08:09 am »

Is Advfort's tame animal job bugged? I couldn't get it to work, sadly, or was it always kind of not something possible to do?
if it is, is there any way for me to try and "tame" animals in adv mode?
(sorry if this is kind of out of place but this seemed like the right place to me at the time)
oh yeah advfort tame animal job is probably not possible to do, at best you could... toggle the tame flag on an animal through gm-editor... or use tofort to switch into fort mode while on site and go through the animal taming process through there.
there some jobs and options in adv fort that would have work but after I think 30.xx era they stop and the quick access to fort mode assign job stuff is now mostly doable with companions and npcs.

edit: ok so someone asked for an all doors script so I went and modified an earlier doors script to now give the player means to set all doors to be close, or pet accessible and or 7 different options.

Code: ('gui-doors.lua') [Select]
local dlg=require("gui.dialogs")

--warmist corpse explosion script modified to open doors now with gui function...
-- the F options will set door flags to false and the T options will set them to true
-- the ------- line option does nothing and there for visual to help separate the list
  local items={}


function doors()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[0]=true
end
  end
  end
      return true
end
end
  function doors1()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[1]=true
end
  end
  end
      return true
end
end
  function doors2()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[2]=true
end
  end
  end
      return true
end
end
  function doors3()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[3]=true
end
  end
  end
      return true
end
end
 function doors4()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[4]=true
end
  end
  end
      return true
end
end
 function doors5()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[5]=true
end
  end
  end
      return true
end
end
 function doors6()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[6]=true
end
  end
  end
      return true
end
end
function fdoors()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[0]=false
end
  end
  end
      return true
end
end
  function fdoors1()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[1]=false
end
  end
  end
      return true
end
end
  function fdoors2()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[2]=false
end
  end
  end
      return true
end
end
  function fdoors3()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[3]=false
end
  end
  end
      return true
end
end
 function fdoors4()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[4]=false
end
  end
  end
      return true
end
end
 function fdoors5()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[5]=false
end
  end
  end
      return true
end
end
 function fdoors6()
  for _,checked_item in pairs(df.global.world.items.all) do
    if df.item_doorst:is_instance(checked_item) and checked_item.flags.in_building then
      table.insert(items,checked_item)
    end
  end

if #items==0 then
print"no Doors"
else
  for k,v in pairs(items) do
   knock=v.general_refs[0].building_id
  for o,lay in pairs(df.global.world.buildings.all) do
if lay.id==knock then
lay.door_flags[6]=false
end
  end
  end
      return true
end
end
function none()
--"divider line for gui"
end

  listofspells={
{text="forbidden", spell=doors,icon='T'},
{text="internal", spell=doors1,icon='T'},
{text="taken_by_invaders", spell=doors2,icon='T'},
{text="used_by_intruder", spell=doors3,icon='T'},
{text="closed", spell=doors4,icon='T'},
{text="operated_by_mechanisms", spell=doors5,icon='T'},
{text="pet_passable", spell=doors6,icon='T'},
{text="----------", spell=none,icon='-'},
{text="forbidden", spell=fdoors,icon='F'},
{text="internal", spell=fdoors1,icon='F'},
{text="taken_by_invaders", spell=fdoors2,icon='F'},
{text="used_by_intruder", spell=fdoors3,icon='F'},
{text="closed", spell=fdoors4,icon='F'},
{text="operated_by_mechanisms", spell=fdoors5,icon='F'},
{text="pet_passable", spell=fdoors6,icon='F'},
}

dlg.showListPrompt("Doorections","Choze Doorect option 'T'rue or 'F'alse",nil, listofspells,function(index,choice) choice.spell() end)

« Last Edit: November 14, 2022, 05:05:59 am by Rumrusher »
Logged
I thought I would I had never hear my daughter's escapades from some boy...
DAMN YOU RUMRUSHER!!!!!!!!
"body swapping and YOU!"
Adventure in baby making!Adv Homes

Gnomedevourer

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3242 on: November 13, 2022, 04:46:42 am »

ah, thank you! I suppose that'd be what I'll be doing from now on!
Logged
tried to balance a mod, once upon a time, fell and scraped my knee, ain't doing that again.

mross

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3243 on: November 24, 2022, 11:14:08 pm »

How do I stop dfhack from autosaving my game?
Logged

Putnam

  • Bay Watcher
  • DAT WIZARD
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3244 on: November 24, 2022, 11:45:19 pm »

How do I stop dfhack from autosaving my game?

Uninstall the vettlingr tileset, which adds a monthly quicksave for some reason. Or remove that from the install, don't quite recall how.

Ziusudra

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3245 on: November 25, 2022, 12:04:02 am »

How do I stop dfhack from autosaving my game?
In the file PE-0.47.05-r11/LNP/graphics/Vettlingr/raw/onLoad_gfx_Vettlingr.init add a # to the beginning of the line that contains -command [ quicksave ], that will make that line a comment and prevent it from running.

Edit: there's maybe a similar file copied into the save folder somewhere that might also need to be changed
« Last Edit: November 25, 2022, 12:08:33 am by Ziusudra »
Logged
Ironblood didn't use an axe because he needed it. He used it to be kind. And right now he wasn't being kind.

Rumrusher

  • Bay Watcher
  • current project : searching...
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3246 on: November 28, 2022, 09:29:27 am »

Code: ('justSum4.lua') [Select]
local dlg=require("gui.dialogs")
-- ok so this script is made for summoning gods into DF re-re-edited to just summon any historical figure so far, for this to work all you need is to be in fast traveling.
-- after which the game will spawn in a unit directly next to you.
-- going to give a warning about how this script messes with nemesis and probably less unstable than summoning gods though you might get killed summoning a larger hostile foe.
-- so BEST not use this on any important saves you care about and just test this out on an disposable save.
-- so far as a script that summons folks go this cuts down looking for them.
-- this script uses coding from spawn unit and gui scripting to make it work, don't think this works in fort mode as this was made and tested in adv mode.
-- so far getting two folks to hostile creatures and beasts fight with this is a breeze.

function justsummoning()
local Ark={}
for k,v in pairs(df.global.world.history.figures) do
BoaName=dfhack.TranslateName(v.name)
table.insert (Ark,{dfhack.TranslateName(v.name).." "..v.name.nickname,nil,v,search_key = dfhack.TranslateName(v.name):lower()})
end
local f=function(Name,C)
  justsummoning2(C[3])
end
dlg.showListPrompt("HistFig list","Select your figure for summoning",COLOR_WHITE,Ark,f,nil,nil,true)
end


function getArmyAtName(Divineslot)
for k,v in pairs(df.global.world.nemesis.all) do
if v.flags.ACTIVE_ADVENTURER then
print("Adv Nem",k)
local Cat=df.global.world.armies.all
for k1,v1 in pairs(Cat) do
if v1.members==nil then break else
for Del,ete in pairs(v1.members) do
if ete.nemesis_id==v.id then
print("Adv Army",k1)
return k1
end
end
end
end
end
end
end

function justsummoning2(HistfigID)
Divineslot=HistfigID.nemesis_id
 local horse=Divineslot
 print('Summon Nem ID',Divineslot)
 local NeArmy=getArmyAtName()
  df.global.world.armies.all[NeArmy].members:insert("#",{new=true,nemesis_id=horse})
end


justsummoning()

ok so here's a script made for locating key folks in your adventurers... by just warping them to your location with use of fast travel armies.
be warn the folks with no name are an mix bag on what you might pull. also this version of the script has a bare bones search function for user ease... but not super user ease like the other scripts in the dfhack repo.
would give the same warning about not knowing how unstable this script would do to the game but given it's inserting a one time hist fig into your party I feel like it's more stable than the usual.
Logged
I thought I would I had never hear my daughter's escapades from some boy...
DAMN YOU RUMRUSHER!!!!!!!!
"body swapping and YOU!"
Adventure in baby making!Adv Homes

A_Curious_Cat

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3247 on: December 01, 2022, 12:59:07 am »

Any news on the agui library?  I’m asking because it isn’t available as a precompiled package for my system and it’s needed for stonesense and isoworld.  I did have it working before on an older version of DFHack using instructions that somebody had posted to an older DFHack thread, but those instructions stopped working with newer versions of DFHack.
Logged
Really hoping somebody puts this in their signature.

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3248 on: December 01, 2022, 08:34:43 pm »

Any news on the agui library?  I’m asking because it isn’t available as a precompiled package for my system and it’s needed for stonesense and isoworld.  I did have it working before on an older version of DFHack using instructions that somebody had posted to an older DFHack thread, but those instructions stopped working with newer versions of DFHack.
Can you link to those instructions? The only thing I see that uses agui is isoworld, and it appears to bundle agui, so I'm not sure why installing it separately is necessary.
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

A_Curious_Cat

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3249 on: December 01, 2022, 09:07:23 pm »

Any news on the agui library?  I’m asking because it isn’t available as a precompiled package for my system and it’s needed for stonesense and isoworld.  I did have it working before on an older version of DFHack using instructions that somebody had posted to an older DFHack thread, but those instructions stopped working with newer versions of DFHack.
Can you link to those instructions? The only thing I see that uses agui is isoworld, and it appears to bundle agui, so I'm not sure why installing it separately is necessary.

Huh?  Interesting, I was getting an error about not being able to find agui when I was compiling 0.47.05-r6 and I could’ve sworn it wouldn’t go away until I disabled compilation of both isoworld and stonesense…

Anyways, I’m only seeing two other posts about agui in this forum other than this one and my previous one.  This one seems to be the most relevant (the other just states that they compiled agui by hand but doesn’t say how). 

I could’ve sworn I was able to compile agui by hand on an older version, but that the instructions stopped working after a newer version of DFHack came out.  I also could’ve sworn there were more precise instructions. 

In any case, I believe that the root problem is that DFHack assumes that the person compiling it already has agui available on their system (which is a problem if they are using a Linux distribution (such as Debian, for example) that doesn’t include agui in it’s package repository).  It’d be nice DFHack could pull in and compile agui automatically whenever it is compiled.

Edit:

Maybe the best thing for me to do would be to try recompiling DFHack again and post the output. Also, maybe try and do the same with agui.

Edit2:

Whelp!  The fun stops here.

I cloned DFHack and then proceeded to use ccmake to configure it for compilation but it spat out an error message about me needing a newer version of allegro.  “Fine.  I can just upgrade to the new version.”, I thought.  Then, when I went to upgrade, the package manager spat out a bunch of error that seem to be related to changes that the author of the distribution made when deriving the distribution from Debian (I’ve had problems updating before (for example, the package manager wanting to completely remove both the init system and glibc).  I’ve now got two choices:  A) wait for the author to release a new version of the distribution (it’s already more than a year past when one would’ve expected that to happen based on previous releases), or B) switch to a different distribution (I already know which one I’m going to choose)…
« Last Edit: December 01, 2022, 09:54:08 pm by A_Curious_Cat »
Logged
Really hoping somebody puts this in their signature.

myk

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3250 on: December 02, 2022, 10:03:06 am »

Allegro is downloaded by the stonesense build code. You shouldn't have to do anything at the system level. There is a CMake build option called "Link with prebuilt internal allegro libs and headers" that is on by default. Maybe check to see if this option has somehow been disabled?
Logged

myk

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r7
« Reply #3251 on: December 02, 2022, 02:55:40 pm »

DFHack 0.47.05-r8 has been released!

Download it here



This is the second usability-focused release of DFHack. In the previous release, we made initial progress with the in-game command launcher with autocomplete and integrated command help. This release builds on that start with improved mouse controls (like draggable scrollbars) and a brand new framework for on-screen informational overlays and interactive widgets that respond to what's currently happening in the game.

The cool thing is that this overlay framework is ready for use by mods, including Steam Workshop mods! All modders have to do is declare an OverlayWidget in their script code and the overlay framework will discover it and attach it to the correct Dwarf Fortress screens. Players can enable, disable, or reposition overlay widgets with the new click-and-drag gui/overlay configuration interface. You can start playing with this interface with the overlay widgets that we've already ported to the new framework, such as the date, happiness meter, and weather indicator from dwarfmonitor.

Q: Wait! Go back! So DFHack is ready for the steam release now??

A: No, sorry, not yet. We have a lot of work to do to adapt DFHack to the new Dwarf Fortress release. It might take us a few months, but you will have your favorite tools back. And we hope to have even more usability improvements ready for you then too!

Q: So, like, why are you releasing now? Don't you know that the Steam release is in a few days?

A: Yeah, we know. This release is more for those who aren't upgrading right away, like players who aren't on Steam, adventure mode players, and, of course, players who want to wait for DFHack to become available for the new version before they switch to it : )

Highlights


The Hotkeys Hotspot



The major new feature is the Hotkeys Hotspot. You may not know this, but DFHack has many default keybindings that are bound to specific Dwarf Fortress screens (like the manager orders screen or the main map) that run useful DFHack commands. For example, when you're on the manager orders screen and have a manager order selected, you can hit Alt-Q to change the number of items that the workorder will produce.

The Hotkeys Hotspot uses the new overlay framework to provide a mouse rollover menu that makes these bound commands available to you in a clickable list. You can also right-click on them to open them in the in-game launcher to modify the command and/or see the associated command help. You can add more commands to this list (or take some away) via the DFHack keybinding command, too.

You can show the rollover menu by moving your mouse near the upper left corner of the screen, a little down from the top. On the main map, this spot is marked by an exclamation point (!), but the spot is "hot" on every screen, even if the exclamation point is covered up by something. You can reposition the hotspot with gui/overlay if you want it in a more convenient place. You can also bring it up with the keyboard instead of the mouse by hitting the Ctrl-Shift-C hotkey.

gui/overlay



gui/overlay is the beginning of a new trend for DFHack: in-game configuration that remembers your choices from game to game without any editing of init files. Also, notice the fancy new mouse controls like mouse hover reactions and click-and-drag widgets. Expect to see more of this from DFHack in the future!

spectate

The spectate plugin has seen a good bit of improvement in this release. Once your fort is in a good, steady state, try firing this tool up to automatically follow dwarves around, switching among them periodically, so you can sit back and watch your dwarves be dwarfy!

channel-safely

The new channel-safely tool protects your dwarves from digging themselves to death while channeling out large projects. Digging a large drowning trap or a magma piston? Give this tool a try!

How to upgrade


  • Remove the existing `hack/` directory in your Dwarf Fortress game folder
  • Extract the DFHack release archive into your Dwarf Fortress directory. If it asks you, let it overwrite files.
  • If you use TWBT, you can get an updated version for this release here: https://github.com/thurin/df-twbt/releases/tag/0.47.05-r8

Full upgrade instructions are available online here

Full changelog


Spoiler (click to show/hide)
« Last Edit: December 03, 2022, 11:54:23 am by myk »
Logged

HammerDave

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r8
« Reply #3252 on: December 03, 2022, 02:48:28 pm »

I will have a window of opportunity to work on upgrade, if doing so looks like it will be a net add.  If it looks like it would take more effort to bring a legendary but rusty coder up to speed than the benefit then I'll just stay out of your way.   8)
Logged

myk

  • Bay Watcher
    • View Profile
Re: DFHack 0.47.05-r8
« Reply #3253 on: December 03, 2022, 04:03:48 pm »

There are several active projects within DFHack that you are welcome to get involved with (and that we really need help with!). Let me list a few:

1. Ruby turndown
DFHack is looking at options for distribution via Steam. One of the blockers for this is DFHack's support for Ruby as a scripting language. It causes too many support issues. We need to rewrite existing Ruby scripts in Lua so we can remove ruby support without losing popular functionally.

2. Initless
As part of DFHack's ongoing usability overhaul, we're trying to make init scripts completely optional. This means that many tools need to be updated to persist their state so that init files don't need to be edited by the user to get the game back into a preferred configuration. Plugins can (and some already do) reload their state when the plugin is loaded, but we need to design and implement a similar mechanism for scripts, which have no analogous "load" hook. We have some thoughts about how this can be accomplished, but it needs more careful and thorough design.

3. GUI config for automation tools
Also part of the usability track. Many of DFHack's most popular automation tools lack in-game configuration UIs. Moreover, many of the existing UIs need to be rethought for the steam release. The DFHack UI widget library has matured significantly in recent releases, so there are many useful primatives for building UIs now.

So, lots and lots of opportunities. What sounds interesting to you? We do most of our discussion and planning on discord nowadays. https://dfhack.org/discord

Of course, there's also the immediate need of reverse engineering, if you'd like to get involved with that too!
« Last Edit: December 03, 2022, 09:44:28 pm by myk »
Logged

Bumber

  • Bay Watcher
  • REMOVE KOBOLD
    • View Profile
Re: DFHack 0.47.05-r8
« Reply #3254 on: December 05, 2022, 08:12:47 am »

"channel-safely" certainly sounds handy.
Logged
Reading his name would trigger it. Thinking of him would trigger it. No other circumstances would trigger it- it was strictly related to the concept of Bill Clinton entering the conscious mind.

THE xTROLL FUR SOCKx RUSE WAS A........... DISTACTION        the carp HAVE the wagon

A wizard has turned you into a wagon. This was inevitable (Y/y)?
Pages: 1 ... 215 216 [217] 218 219 ... 243