Showing posts tagged #DFHack - Show all

On Dwarf Fortress 0.43.05 support

May 16, 2017

The first stable DFHack version for Dwarf Fortress 0.43.05 has now been released (DFHack 0.43.05-r1), so expect Dwarf Fortress Remote to get support for this version soon.

The major change in Dwarf Fortress 0.43.05 is that it is now a 64bit application. 32bit versions are available too, however only 64bit version will be supported by DF Remote. Installation on Linux will now be simpler, as there's no need to install 32bit libraries for DF to work anymore.

July 19, 2016
I've updated my DFHack repos with support for DF 0.43.05 for Windows (64-bit) - pronvit/dfhack and pronvit/df-structures. There's a binary package available for those who wants to help testing plugins and all the functions. As with the OS X version, main plugins seem to work, but I expect some data structures to be incorrect. Several global addresses are also missing for Windows version.

Status of 64-bit DFHack

July 18, 2016
Recently I spent couple days helping DFHack team with support for the new 64-bit Dwarf Fortress version in DFHack. Of course, I was primarily interested in the OS X platform. There were several things that needed to be done in this case: Scripts to find globals There is number of scripts in jjyg/df-misc repo that need to be run on new binaries to extract addresses of global variables and vtables, and other stuff. The author is away, and I don't have any Ruby knowledge, so I decided to write my own scripts for Hopper. They are now available in mifki/df-hopper-scripts, couple of them even support Windows (and Linux support should be easy to do). Update Lua to 5.3 and make sure DFHack builds for 64-bit We needed to update Lua from 5.2 to 5.3 to support 64-bit integer numbers (in particular, memory addresses). Also I had to bunch of int32_t variables to intptr_t. Other than this, there were no major difficulties with DFHack. Lethosor fixed an issue with vararg functions that suddenly started to crash on 64-bit. Update DF structure definitions long type is used in the DF graphics code, so those structures needed to be updated. But that was easy. While the big problem is that in many places, when we don't know the meaning of a field in some structure, we simply use int32_t type for it. However, some of this fields are actually pointers, and while this wasn't a problem on 32-bit, now all the pointers changed size, and a lot of data structures became incorrect. On the bright side, now we can better understand what are pointers and what are integers in DF structures. It took long time to find such fields in world, world_data and some other structures, but in the end I got a working 64-bit DFHack with most of the plugins (that I've tried) working. Current status Repos with 64-bit fixes (look for 64-bit branches): pronvit/dfhack, pronvit/df-structures, pronvit/scripts. The last one has an updated devel/find-offsets script to find almost all of the required global addresses. I don't have any more time to work on this (need to release DF Remote with support for DF 0.43.03 as soon as possible), and what needs to be done now is just further testing of all plugins to make sure all data structures are correct. I don't know how much time this is going to take and who is working on it now.