Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 53 54 [55] 56 57 ... 373

Author Topic: DFHack 0.34.11 r3  (Read 1458297 times)

telamon

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #810 on: March 08, 2012, 04:39:51 pm »

Quote
The trigger isn't "discovering magma in a newly revealed area" - the trigger is discovering the appropriate map feature, specifically either a volcano, a magma pool, or a magma sea. If you're particularly tricky, you might be able to grab a suitably ordinary map block, set its global feature index to that of the magma sea (there might actually be more than one), then set the "is global feature" flag on a particular tile and dig to it to trigger the "You have discovered the magma sea" message and enable the magma workshops.

OOH. that has my attention. Can those flags be found and manipulated with tiletypes? I will absolutely try it if anybody proposes a method (I'm getting sick of using hacked reactions to generate charcoal, although it does keep my haulers busy), and report back.
Logged
Playing DF on Windows 98 since.... ?
At 55 frames per minute.

Antalia

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #811 on: March 08, 2012, 04:45:50 pm »

Antalia, you could always fork the DFHack source, and expand the XML export tool to contain all the information you want.
Yes, I wouldn't mind doing that, but my computer (Windows XP 32) is ancient enemies with MSVC 2010 Express. Whenever I try to build C++ stuff on this, I get the dreaded error message, "Invalid license data. Reinstall is required." I've tried every "solution" and "workaround" I can find, including a few hours of uninstalls->complete reinstalls again tonight. The only option I haven't tried this evening is to reinstall Windows. I really doubt that will help, since I've done it before over this very same problem, and look where it got me :) That's why I asked if there were any plans to expand the plugin--I can't get into it myself without a new computer for now. Thanks for trying to help me though :)
Logged
Author of Saga of Nutscaves, a tale of unsafe working conditions, plague, and worse

Creator of Dwarf Organizer, a Java application to help assign labor in your fortress

Valdrax

  • Bay Watcher
  • HUGE ELF (bluh bluh)
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #812 on: March 08, 2012, 07:59:36 pm »

actually, there is an experimental build that does the equivilant of replacing the dll, unless I mis-understand the purpose of the eggy branch.
Only it's libgraphics.so, i.e. a part of Dwarf Fortress that is linked into the exe on windows, but separate and open-source on linux. It basically hooks directly into the rendering code of the game in order to do some more fancy stuff.
I'm very interested in testing this to see if it would allow me to use DFHack on a hardened system with some tinkering (turning off PaX flags, etc.).  Where can I find this?

(EDIT:  Ah, I forgot to thank Quietust for answering my question above.  Thanks.)
Logged
The history of a good fortress is not written in blood, it's painted on the walls by the hand of a melancholy orphan.

Antalia

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #813 on: March 08, 2012, 09:04:51 pm »

Well, scratch what I said above...I [made a sacrifice to Armok and] was rewarded with access to a working copy of MSVC 2010. I've been looking at how rough it would be to manage the small additions to dwarfexport and submit them, and I've run into a couple problems. Where is the best place to ask these type of questions?

1 - I'm having a problem building. Cmake is complaining (accurately, it seems) about a missing /library/xml/codegen.pl, or a missing global_objects.h, or a problem with an empty Include variable in generate_headers.vcxproj, depending what I include in the build. Just building dwarfexport by itself (and most of the other stuff, I notice) is error-free. But building dwarfexport alone doesn't produce anything useful--I would think it needs the library and/or plugins as well (?). That's where the problems come. If something installed or copied incorrectly, it didn't complain. I think I'm at a loss here.

2 - It was mentioned that dwarves' skill levels are read from memory someplace in DFHack, but I haven't found this. In the units file I found some promising looking stuff, but it's commented out... Could it be labeled something besides 'skills', or 'jobs', or 'labor'?

I'm sorry if these are dumb questions or in the wrong place. Point me in the right direction if so :) This is getting to be quite some effort for something so small, but it's interesting.
Logged
Author of Saga of Nutscaves, a tale of unsafe working conditions, plague, and worse

Creator of Dwarf Organizer, a Java application to help assign labor in your fortress

Kogut

  • Bay Watcher
  • Next account: Bulwersator
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #814 on: March 08, 2012, 09:10:39 pm »

Small suggestion - add function "keep mayor X" to avoid replacing him every single year.
Logged
The worst bug - 34.11 poll
Tired of going decades without goblin sieges? Try The Fortress Defense Mod
Kogut, the Bugfixes apostle of Bay12forum. Every posts he makes he preaches about the evil of Bugs.

Girlinhat

  • Bay Watcher
  • [PREFSTRING:large ears]
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #815 on: March 08, 2012, 09:55:01 pm »

Counter suggestion - Add an ability to tie rooms to a noble position, instead of a dwarf.  Hit q, make the furniture into a room, assign to dwarf.  With q still open, open DFHack and select "roomlock noble" to make it refresh the room to the currently selected noble - as in, if you've made a room for your captain of the guard, he dies, and you reassign him, then DFHack will reassign the room to the current captain of the guard, or exchange dwarves when a new mayor is selected.

I feel this would solve more than locking the mayor position, though that's still a valid option, if I had to pick I'd go with my suggestion.  It helps in more areas (like when your militia commander dies), and probably solves your problem as well.  It'd let you make a mayoral suite and leave it alone.

ALSO: little trick for magma forges - apparently it's recorded as civ data.  Embark, dig down to the sea, and abandon.  Make a new embark anywhere, and magma forges will be enabled.  Seems once dwarves know about magma, they remember it!

peterix

  • Bay Watcher
    • View Profile
    • Dethware
Re: DFHack 0.34.05 r1
« Reply #816 on: March 08, 2012, 11:48:40 pm »

Well, scratch what I said above...I [made a sacrifice to Armok and] was rewarded with access to a working copy of MSVC 2010. I've been looking at how rough it would be to manage the small additions to dwarfexport and submit them, and I've run into a couple problems. Where is the best place to ask these type of questions?
#dfhack IRC channel on freenode.
1 - I'm having a problem building. Cmake is complaining (accurately, it seems) about a missing /library/xml/codegen.pl, or a missing global_objects.h, or a problem with an empty Include variable in generate_headers.vcxproj, depending what I include in the build. Just building dwarfexport by itself (and most of the other stuff, I notice) is error-free. But building dwarfexport alone doesn't produce anything useful--I would think it needs the library and/or plugins as well (?). That's where the problems come. If something installed or copied incorrectly, it didn't complain. I think I'm at a loss here.
You don't have all of the code :)

Read this first:
https://github.com/peterix/dfhack/blob/master/COMPILE.rst

2 - It was mentioned that dwarves' skill levels are read from memory someplace in DFHack, but I haven't found this. In the units file I found some promising looking stuff, but it's commented out... Could it be labeled something besides 'skills', or 'jobs', or 'labor'?
I don't know how complete is your build environment... but once you have everything and can make a build, it creates a lot more files:
library/include/df/unit.h
library/include/df/unit_soul.h
library/include/df/unit_skill.h
library/include/df/job_skill.h
... and many, many others. Those headers are relevant though. Skills are part of the creature's soul.

You can see this xml files from which those headers are generated:
https://github.com/peterix/df-structures/blob/master/df.units.xml#L853 - soul
https://github.com/peterix/df-structures/blob/master/df.units.xml#L899 - skills
https://github.com/peterix/df-structures/blob/master/df.skills.xml - skill types

robertheinrich

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #817 on: March 09, 2012, 12:01:20 am »

Counter suggestion - Add an ability to tie rooms to a noble position, instead of a dwarf.  Hit q, make the furniture into a room, assign to dwarf.  With q still open, open DFHack and select "roomlock noble" to make it refresh the room to the currently selected noble - as in, if you've made a room for your captain of the guard, he dies, and you reassign him, then DFHack will reassign the room to the current captain of the guard, or exchange dwarves when a new mayor is selected.

I feel this would solve more than locking the mayor position, though that's still a valid option, if I had to pick I'd go with my suggestion.  It helps in more areas (like when your militia commander dies), and probably solves your problem as well.  It'd let you make a mayoral suite and leave it alone.

Uh, I think that might be a bit beyond the scope of DFHack since it deals with room assignments etc. Also itīs not really *that* necessary since you donīt have to keep track of too many nobles. Just design a room for the position. When the person dies it is freed automatically. When the person changes just kick the old guy out - an ex-mayor doesnīt need any better room than a peasant. You can also minimize the chance of your nobles getting killed by not using them for military, hauling and labor outside of the fortress. For some positions this is wise anyway... I was wondering why my bookie would skill up his record keeping so slowly, then I noticed that he spent most of his day as furnace operator.

Quote
ALSO: little trick for magma forges - apparently it's recorded as civ data.  Embark, dig down to the sea, and abandon.  Make a new embark anywhere, and magma forges will be enabled.  Seems once dwarves know about magma, they remember it!

Oh, now thatīs really good to know. Thanks for that info.
Logged

Antalia

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #818 on: March 09, 2012, 06:35:43 am »

Quote
You don't have all of the code :)
Thanks, the problem was something I did in Tortoisegit. I recloned with the command line and now (there is a lot more code here and) I am able to build. I'll check IRC if I have any more problems :)
Logged
Author of Saga of Nutscaves, a tale of unsafe working conditions, plague, and worse

Creator of Dwarf Organizer, a Java application to help assign labor in your fortress

CheatingChicken

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #819 on: March 09, 2012, 08:34:20 am »

I've got a suggestion for you: Can you remake the job duplication plugin to work with the job manager screen? It would really help a lot if you could just duplicate jobs there instead of always typing in everything yet again or making a macro for it.
Logged

Quietust

  • Bay Watcher
  • Does not suffer fools gladly
    • View Profile
    • QMT Productions
Re: DFHack 0.34.05 r1
« Reply #820 on: March 09, 2012, 09:41:14 am »

Quote
The trigger isn't "discovering magma in a newly revealed area" - the trigger is discovering the appropriate map feature, specifically either a volcano, a magma pool, or a magma sea. If you're particularly tricky, you might be able to grab a suitably ordinary map block, set its global feature index to that of the magma sea (there might actually be more than one), then set the "is global feature" flag on a particular tile and dig to it to trigger the "You have discovered the magma sea" message and enable the magma workshops.

OOH. that has my attention. Can those flags be found and manipulated with tiletypes? I will absolutely try it if anybody proposes a method (I'm getting sick of using hacked reactions to generate charcoal, although it does keep my haulers busy), and report back.
I actually looked a bit closer at the code for populating the Build menus and it seems that there's a list that presumably contains all of the features in your current embark, so it might be necessary to choose a specific feature ID in order for it to work (since if it's not native to your embark, it might not be in that list and thus wouldn't be able to enable magma workshops).
Logged
P.S. If you don't get this note, let me know and I'll write you another.
It's amazing how dwarves can make a stack of bones completely waterproof and magmaproof.
It's amazing how they can make an entire floodgate out of the bones of 2 cats.

thistleknot

  • Bay Watcher
  • Escaped Normalized Spreadsheet Berserker
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #821 on: March 09, 2012, 12:38:11 pm »

I made a weighted formula for close combat dwarfs for dwarf therapist.  I was hoping I could somehow learn how dwarfexport gets these attribute values (i.e. memory address locations) and plug them into this formula so I can create a sortable list.

I'm hoping I can create a script that exports these values to notepad or something.  I've posted it on dwarf therapist in hopes that they might catch on and import it as well, there's talk on Dwarf Therapist, as well as Dwarven Guidance Counselor of getting such things to work.  DGC wants to use dfhack as well.

The formula consists of:

Basically it's ((attribute x factor) - 1380) x weight

For information on factor, you can see how I derived it from this post http://www.bay12forums.com/smf/index.php?topic=66525.msg3077752#msg3077752

but in essence, it's to get all the attributes on the same center range before subtracting it from the 1380, which is the averaged center of all dwarven attributes.

Weight is an importance for the said attribute for the profession (this case it's close combat dwarfs).

here's the formula as it works in Dwarf Therapist:

Spoiler (click to show/hide)
« Last Edit: March 09, 2012, 01:14:28 pm by thistleknot »
Logged

Girlinhat

  • Bay Watcher
  • [PREFSTRING:large ears]
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #822 on: March 09, 2012, 12:41:02 pm »

Spoiler is your friend.  Also code blocks, you've got a fair amount of cool looking faces there.

thistleknot

  • Bay Watcher
  • Escaped Normalized Spreadsheet Berserker
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #823 on: March 09, 2012, 12:42:36 pm »

Spoiler is your friend.  Also code blocks, you've got a fair amount of cool looking faces there.

yeah, the smileys are x.8 for some reason.  I don't know how to use spoilers.  I guess I could quote someone, and see how it shows up.

Rumrusher

  • Bay Watcher
  • current project : searching...
    • View Profile
Re: DFHack 0.34.05 r1
« Reply #824 on: March 09, 2012, 12:46:45 pm »

I made a weighted formula for close combat dwarfs for dwarf therapist.  I was hoping I could somehow learn how dwarfexport gets these attribute values (i.e. memory address locations) and plug them into this formula so I can create a sortable list.

I'm hoping I can create a script that exports these values to notepad or something.  I've posted it on dwarf therapist in hopes that they might catch on and import it as well, there's talk on Dwarf Therapist, as well as Dwarven Guidance Counselor of getting such things to work.  DGC wants to use dfhack as well.

The formula consists of:
Spoiler (click to show/hide)
you are better off using the Code function.
it's easy it's the # button, and to use it just highlight the long series of code and hit that button, same goes for spoiling it.
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
Pages: 1 ... 53 54 [55] 56 57 ... 373