Bay 12 Games Forum

Please login or register.

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

Author Topic: DFHack 0.43.05-r1  (Read 1166 times)

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #30 on: May 20, 2017, 09:07:58 am »

Hmmm, I just checked one of my active reclaimed forts, df.global.world.world_data.active_site.entity_links and looked at the bottom of the list, numbers list the site id and relevant entity, usually player created/claimed site groups are near or at the end, went to that entity and grabbed this shot:
Spoiler (click to show/hide)
Isn't that it?
Yeah. Is that in assignments? I couldn't find it in assignments_by_type.

Quote
Oh yeah! Is there a simple way to recenter a screen on a unit or whatnot that I'm just a moron and overlooked? I couldn't figure out dfhack.screen.zoom() syntax at all though I tried feeding it my unit position, cursor position, unit id, and a couple other things.
dfhack.gui.revealInDwarfmodeMap() (it takes a df.coord, I believe). dfhack.screen.zoom() zooms the screen in and out.

Quote
Hmmm, there's an update screen check too isn't there? Was annoying trying out a "teleport to the cursor" hotkeyable script because if you have the cursor out of view you have to move before it will refresh your screen fully. Even tried having it just straight up list that tile as revealed through the dfhack.maps.getTileBlock(blah).designations[xmath][ymath] stuff with no luck.
Some tools that need that just feed CURSOR_DOWN_Z and CURSOR_UP_Z to the dwarfmode screen, although that doesn't work at the lowest z-level. I've been meaning to add something to the Gui module to handle that appropriately.

Yes it was... I couldn't find it anywhere online... but its just a basic repeating script... It works, its set to 2000 ticks if I understand it correctly, and in fortress mode that's just about perfect timing, I couldn't tell you how "optimized" it is.  Here you go:
Is there a reason why MDF needs it? I'm fine with including it, but I don't want to enable it by default unless it fixes something that comes up in vanilla often.

Edit: also, I don't see anything particularly wrong with the formatting...

Quote
yeah I had, and on abandon, it reset the counter when I claimed a new site on the same map.  I can try and do some more testing but It may be next week and I'll get back to you.  I've got a load of things I'm trying to accomplish between today and monday, so when I can, its back on my list.  I don't want to have to fix that set of scripts anymore...
Weird. I don't see an obvious reason why it would be doing that. I'll look into it, though.
« Last Edit: May 20, 2017, 09:10:09 am by lethosor »
Logged
DFHack scripts - Dwarf Manipulator (Lua) - DF Wiki talk

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

Amostubal

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #31 on: May 20, 2017, 09:15:34 pm »

Quote
Yes it was... I couldn't find it anywhere online... but its just a basic repeating script... It works, its set to 2000 ticks if I understand it correctly, and in fortress mode that's just about perfect timing, I couldn't tell you how "optimized" it is.  Here you go:

Is there a reason why MDF needs it? I'm fine with including it, but I don't want to enable it by default unless it fixes something that comes up in vanilla often.

Edit: also, I don't see anything particularly wrong with the formatting...

simply put its not a vanilla issue as much as its a modder issue.  Basically any time you produce gloves from reactions they are unhanded.  so if you mod a lot of reactions in as MDF has, multiple times (craft full armor sets, mass productions, custom shops, specialty glove sets, etc.), this fixes that without having to add a reaction-trigger for every reaction that has gloves to run a correction.  I was just surprised, it wasn't a part of the repo, and I yeah I wouldn't have it enabled by default.

really it just needs some documentation added to it on the second part... thats what I meant for about not being DFHack-esque.

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #32 on: May 20, 2017, 11:39:43 pm »

Hmmm, I just checked one of my active reclaimed forts, df.global.world.world_data.active_site.entity_links and looked at the bottom of the list, numbers list the site id and relevant entity, usually player created/claimed site groups are near or at the end, went to that entity and grabbed this shot:
Spoiler (click to show/hide)
Isn't that it?
Yeah. Is that in assignments? I couldn't find it in assignments_by_type.
entities[k].positions.own had that, .assignments just lists the histfig that it's linked to, never even thought to check assignments_by_type actually.
Quote
Quote
Oh yeah! Is there a simple way to recenter a screen on a unit or whatnot that I'm just a moron and overlooked? I couldn't figure out dfhack.screen.zoom() syntax at all though I tried feeding it my unit position, cursor position, unit id, and a couple other things.
dfhack.gui.revealInDwarfmodeMap() (it takes a df.coord, I believe). dfhack.screen.zoom() zooms the screen in and out.
That'll work even if not in dwarf mode?

Quote
Quote
Hmmm, there's an update screen check too isn't there? Was annoying trying out a "teleport to the cursor" hotkeyable script because if you have the cursor out of view you have to move before it will refresh your screen fully. Even tried having it just straight up list that tile as revealed through the dfhack.maps.getTileBlock(blah).designations[xmath][ymath] stuff with no luck.
Some tools that need that just feed CURSOR_DOWN_Z and CURSOR_UP_Z to the dwarfmode screen, although that doesn't work at the lowest z-level. I've been meaning to add something to the Gui module to handle that appropriately.
Yeah, I was trying to work out if I was just missing something or what, but then the lua api didn't mention anything remotely like what I was after.
Logged
Engraved here is a rendition of an image of the Dwarf Fortress learning curve. All craftsdwarfship is of the highest quality. It depicts an obsidian overhang which menaces with spikes of obsidian and tears. Carved on the overhang is an image of Toady One and the players. The players are curled up in a fetal position. Toady One is laughing. The players are burning.
The VectorCurses+1 tileset strikes the square set and the severed part sails off in an arc!

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #33 on: May 21, 2017, 04:37:40 pm »

Quote
dfhack.gui.revealInDwarfmodeMap() (it takes a df.coord, I believe). dfhack.screen.zoom() zooms the screen in and out.
That'll work even if not in dwarf mode?
I wouldn't expect it to work in adventure mode, but I haven't checked.

I got the CURSOR_UP_Z / CURSOR_DOWN_Z idea from gui/liquids.lua. There are a couple plugins that use it too (mousequery?).
Logged
DFHack scripts - Dwarf Manipulator (Lua) - DF Wiki talk

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

expwnent

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #34 on: May 21, 2017, 09:27:51 pm »

Old thread locked to avoid confusion.
Logged

necros

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #35 on: May 23, 2017, 01:55:13 pm »

Hello, wasn't sure where to put this and I haven't see anyone talk about this, but can someone explain why doors, tables and I guess other furniture are built with coke when they are put down in planning mode?
By coke, I mean they haul bars of coke to the location and then create a door or table from scratch!  I can deconstruct it and I get bars of coke back...  I've never seen this behaviour before.

Planning mode was working normally a while ago where it would wait until I'd build the funiture item and then a dwarf would go haul the constructed item to the spot and install it.  But suddenly (and I'm not sure exactly when as 'coke bar' furniture looks like gabbro) any planned furniture immediately gets made out of coke bars...  and it's always coke bars.  Any ideas?
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #36 on: May 23, 2017, 02:23:34 pm »

I haven't seen that happen before. What DFHack version are you using?
Edit: I can't reproduce it in DFHack 0.43.05-r1, even if there aren't any tables available (and coke bars are available).
« Last Edit: May 23, 2017, 02:26:23 pm by lethosor »
Logged
DFHack scripts - Dwarf Manipulator (Lua) - DF Wiki talk

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

necros

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #37 on: May 23, 2017, 03:51:27 pm »

Right, sorry I should have said all the technical stuff :)

I'm using the LNP (PeridexisErrant's Starter Pack 0.43.05-r03) which has DF 43.05 along with DFHack 0.43.05-r1 (thread: http://www.bay12forums.com/smf/index.php?topic=126076.0)

To be clear, I have the min quality set to ordinary and filter set to *any.  I have say 4 beds prebuilt.  I place 1 bed down in planning mode and a dwarf hauls a bar of coke over.

I don't think this happens on a new game.  I feel like I did something at some point that triggered this behaviour because it reliably does this as soon as I load up the save (even if I already have the furniture constructed).  But when I load an earlier save, it doesn't happen and dwarfs will wait until I construct a bed even if there is coke bars available.

I tried forbidding all my coke bars from the stocks screen.  When they are forbidden, dwarfs properly use normal constructed beds.   After unforbidding, it seems this has fixed the behaviour...  Very strange!!!  I'll post again if anything interesting happens...

Logged

lethosor

  • Bay Watcher
    • View Profile
Re: DFHack 0.43.05-r1
« Reply #38 on: May 23, 2017, 06:58:17 pm »

Right, sorry I should have said all the technical stuff :)

I'm using the LNP (PeridexisErrant's Starter Pack 0.43.05-r03) which has DF 43.05 along with DFHack 0.43.05-r1 (thread: http://www.bay12forums.com/smf/index.php?topic=126076.0)
Thanks :)
I asked because DFHack 0.43.05-alpha3 had several bugs related to planning mode (and other things) - planned buildings disappearing instantly or being unbuildable, for example.
Quote
To be clear, I have the min quality set to ordinary and filter set to *any.  I have say 4 beds prebuilt.  I place 1 bed down in planning mode and a dwarf hauls a bar of coke over.

I don't think this happens on a new game.  I feel like I did something at some point that triggered this behaviour because it reliably does this as soon as I load up the save (even if I already have the furniture constructed).  But when I load an earlier save, it doesn't happen and dwarfs will wait until I construct a bed even if there is coke bars available.

I tried forbidding all my coke bars from the stocks screen.  When they are forbidden, dwarfs properly use normal constructed beds.   After unforbidding, it seems this has fixed the behaviour...  Very strange!!!  I'll post again if anything interesting happens...
Yeah, that is weird. Let us know if you can reproduce it again, and upload the save if you can.
Logged
DFHack scripts - Dwarf Manipulator (Lua) - DF Wiki talk

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

MLP Pandemic

  • Escaped Lunatic
    • View Profile
    • MillionFoul's Channel - YouTube
Re: DFHack 0.43.05-r1
« Reply #39 on: Today at 01:23:19 am »

Absolutely fantastic. Please accept a gift of hundreds of sacrificed elf buttocks encircled with a useless mineral.
Logged
PHYSICALLY REMOVE GROUND
Pages: 1 2 [3]