diff --git a/COMPILE.rst b/COMPILE.rst index 175060060..273871142 100644 --- a/COMPILE.rst +++ b/COMPILE.rst @@ -64,18 +64,31 @@ For the code generation parts, you'll need perl and XML::LibXML. You can install * open a cmd.exe window and run "cpan XML::LibXML" (obviously without the quotes). This can take a while to complete. * Same with "cpan XML::LibXSLT". +If you already have a different version of perl (for example the one from cygwin), you can run into some trouble. Either remove the other perl install from PATH, or install libxml and libxslt for it instead. Strawberry perl works though and has all the required packages. + Build ===== -Open the ``build`` folder and double click the batch script there. This will eventually open -a cmake GUI window. Here, set CMAKE_INSTALL_PREFIX to your DF folder and set up any other -options you're interested in. Hit configure and generate, close the GUI. +There are several different batch files in the ``build`` folder along with a script that's used for picking the DF path. + +First, run set_df_path.vbs and point the dialog that pops up at your DF folder that you want to use for development. +Next, run one of the scripts with ``generate`` prefix. These create the MSVC solution file(s): + +* ``all`` will create a solution with everything enabled (and the kitchen sink). +* ``gui`` will pop up the cmake gui and let you pick and choose what to build. This is probably what you want most of the time. Set the options you are interested in, then hit configure, then generate. More options can appear after the configure step. +* ``minimal`` will create a minimal solution with just the bare necessities - the main library and standard plugins. -This crates a folder under build/ that contains the solution files for MSVC. +Then you can either open the solution with MSVC or use one of the msbuild scripts: -When you open the solution, make sure you never use the Debug builds. Those aren't +* Scripts with ``build`` prefix will only build. +* Scripts with ``install`` prefix will build DFHack and install it to the previously selected DF path. +* Scripts with ``package`` prefix will build and create a .zip package of DFHack. + +When you open the solution in MSVC, make sure you never use the Debug builds. Those aren't binary-compatible with DF. If you try to use a debug build with DF, you'll only get crashes. So pick either Release or RelWithDebInfo build and build the INSTALL target. +The ``debug`` scripts actually do RelWithDebInfo builds. + =========== Build types @@ -154,6 +167,7 @@ Good windows tools include: Good linux tools: +* angavrilov's df-structures gui (visit us on IRC for details). * edb (Evan's Debugger) * IDA Pro running under wine. * Some of the tools residing in the ``legacy`` dfhack branch. diff --git a/Compile.html b/Compile.html index 35e4ff3e6..c6d7226d2 100644 --- a/Compile.html +++ b/Compile.html @@ -391,15 +391,27 @@ Grab it from Microsoft's site.
If you already have a different version of perl (for example the one from cygwin), you can run into some trouble. Either remove the other perl install from PATH, or install libxml and libxslt for it instead. Strawberry perl works though and has all the required packages.
Open the build folder and double click the batch script there. This will eventually open -a cmake GUI window. Here, set CMAKE_INSTALL_PREFIX to your DF folder and set up any other -options you're interested in. Hit configure and generate, close the GUI.
-This crates a folder under build/ that contains the solution files for MSVC.
-When you open the solution, make sure you never use the Debug builds. Those aren't +
There are several different batch files in the build folder along with a script that's used for picking the DF path.
+First, run set_df_path.vbs and point the dialog that pops up at your DF folder that you want to use for development. +Next, run one of the scripts with generate prefix. These create the MSVC solution file(s):
+Then you can either open the solution with MSVC or use one of the msbuild scripts:
+When you open the solution in MSVC, make sure you never use the Debug builds. Those aren't binary-compatible with DF. If you try to use a debug build with DF, you'll only get crashes. So pick either Release or RelWithDebInfo build and build the INSTALL target.
+The debug scripts actually do RelWithDebInfo builds.
Good linux tools:
DFHack is a Dwarf Fortress memory access library and a set of basic tools that use it. Tools come in the form of plugins or (not yet) external tools. It is an attempt to unite the various ways tools @@ -326,96 +326,121 @@ access DF memory and allow for easier development of new tools.
Contents
The project is currently hosted on github, for both source and binaries at http://github.com/peterix/dfhack
Releases can be downloaded from here: https://github.com/peterix/dfhack/downloads
All new releases are announced in the bay12 thread: http://tinyurl.com/dfhack-ng
DFHack works on Windows XP, Vista, 7 or any modern Linux distribution. OSX is not supported due to lack of developers with a Mac.
Currently, only the 31.25 version is supported. If you need DFHack @@ -440,7 +465,7 @@ for older versions, look for older releases.
It is possible to use the Windows DFHack under wine/OSX.
Installing DFhack involves copying files into your DF folder. Copy the files from a release archive so that:
@@ -456,17 +481,11 @@ Copy the files from a release archive so that:-- On Linux, Remove the DFHack files.
If it refuses to load, check the stderr.log file created in your DF folder.
+The stonesense plugin might require some additional libraries on Linux.
+If any of the plugins or dfhack itself refuses to load, check the stderr.log file created in your DF folder.
DFHack basically extends what DF can do with something similar to a quake console. On Windows, this is a separate command line window. On linux, the terminal used to launch the dfhack script is taken over (so, make sure you start from a terminal). Basic interaction with dfhack involves entering commands into the console. For some basic instroduction, use the 'help' command. To list all possible commands, use the 'ls' command. Many commands have their own help or detailed description. You can use 'command help' or 'command ?' to show that.
@@ -476,38 +495,55 @@ Some commands can't be used from hotkeys - this includes interactive commands liMost of the commands come from plugins. Those reside in 'DF/plugins/'.
First, don't panic :) Second, dfhack keeps a few log files in DF's folder - stderr.log and stdout.log. You can look at those and possibly find out what's happening. If you found a bug, you can either report it in the bay12 DFHack thread, the issues tracker on github, contact me (peterix@gmail.com) or visit the #dfhack IRC channel on freenode.
Almost all the commands have a 'help'/'?' option that will give you further help without having to look at this document.
Automated item dumping tool. All loose items on the floor marked -for dumping are insta-dumped to the position of the in-game cursor.
-Cursor must be placed on a floor tile. Instadumped items may not -show up in the cursor description list until you save/reload.
+This utility lets you quickly move all items designated to be dumped. +Items are instantly moved to the cursor position, the dump flag is unset, +and the forbid flag is set, as if it had been dumped normally. +Be aware that any active dump item tasks still point at the item.
+Cursor must be placed on a floor tile so the items can be dumped there.
Destroy items marked for dumping under cursor. Identical to autodump destroy-here, but intended for use as keybinding.
+Destroy the selected item. The item may be selected in the 'k' list, or inside a container. If called again before the game is resumed, cancels destroy.
+Cleans all the splatter that get scattered all over the map, items and creatures. In an old fortress, this can significantly reduce FPS lag. It can also spoil your !!FUN!!, so think before you use it.
cleanowned scattered X : This will confiscate rotten and dropped food, garbage on the floors and any worn items with 'X' damage and above.
+Allows listing all the vermin colonies on the map and optionally turning them into honey bee colonies.
'filltraffic H' - When used in a room with doors, it will set traffic to HIGH in just that room.
Set traffic designations for every single tile of the map (useful for resetting traffic designations).
-'filltraffic N' - Set traffic to 'normal' for all tiles.
+'alltraffic N' - Set traffic to 'normal' for all tiles.
Removes invalid references to mineral inclusions and restores missing ones. Use this if you broke your embark with tools like tiletypes.
+Since DF v0.31.1 merchants no longer bring wagons due to a bug. This command re-enables them for all appropriate civilizations.
+A tool for checking how many tiles contain flowing liquids. If you suspect that your magma sea leaks into HFS, you can use this tool to be sure without revealing the map.
This tool allows plant gathering and tree cutting by RAW ID. Specify the types of trees to cut down and/or shrubs to gather by their plant names, separated by spaces.
-all: | Scan the whole map, as if it was revealed. | +
---|---|
value: | Show material value in the output. Most useful for gems. | +
hell: | Show the Z range of HFS tubes. Implies 'all'. | +
If called during the embark selection screen, displays an estimate of layer stone availability. +If the 'all' option is specified, also estimates veins. The estimate is computed either +for 1 embark tile of the blinking biome, or for all tiles of the embark rectangle.
+Regrows all surface grass, restoring outdoor plant growth for pre-0.31.19 worlds.
+Allows renaming various things.
+rename squad <index> "name": | |
---|---|
Rename squad by index to 'name'. | +|
rename hotkey <index> "name": | |
Rename hotkey by index. This allows assigning longer commands to the DF hotkeys. | +|
rename unit "nickname": | |
Rename a unit/creature highlighted in the DF user interface. | +|
rename unit-profession "custom profession": | |
Change proffession name of the highlighted unit/creature. | +
This reveals the map. By default, HFS will remain hidden so that the demons don't spawn. You can use 'reveal hell' to reveal everything. With hell revealed, you won't be able to unpause until you hide the map again. If you really want to unpause with hell revealed, use 'reveal demons'.
This command will hide the whole map and then reveal all the tiles that have a path to the in-game cursor.
Tool for turning cooking of seeds and plants on/off depending on how much you have of them.
See 'seedwatch help' for detailed description.
Shows items needed for current strange mood.
+Copies the parameters of the currently highlighted stockpile to the custom stockpile settings. Basically a way to copy stockpiles easily.
+An isometric visualizer that runs in a second window. This requires working graphics acceleration and at least a dual core CPU (otherwise it will slow down DF).
All the data resides in the 'stonesense' directory. For detailed instructions, see stonesense/README.txt
Compatible with Windows > XP SP3 and most modern Linux distributions.
@@ -845,39 +996,43 @@ This is nice for digging under rivers. http://df.magmawiki.com/index.php/Utility:Stonesense/Content_repositoryCan be used for painting map tiles and is a interactive command, much like liquids. You can paint tiles by their properties - shape, general material and a few others (paint). You can also paint only over tiles that match a set of properties (filter)
For more details, see the 'help' command while using this.
Fills all the adamantine veins again. Veins that were empty will be filled in too, but might still trigger a demon invasion (this is a known bug).
Designates a whole vein for digging. Requires an active in-game cursor placed over a vein tile. With the 'x' option, it will traverse z-levels (putting stairs between the same-material tiles).
This command can be used for exploratory mining.
See: http://df.magmawiki.com/index.php/DF2010:Exploratory_mining
There are two variables that can be set: pattern and filter.
diag5: | diagonals separated by 5 tiles |
---|---|
diag5r: | diag5 rotated 90 degrees | +
ladder: | A 'ladder' pattern |
ladderr: | ladder rotated 90 degrees | +
clear: | Just remove all dig designations |
cross: | A cross, exactly in the middle of the map. | @@ -886,7 +1041,7 @@ You can also paint only over tiles that match a set of properties (filter)