Skip to content

Instantly share code, notes, and snippets.

@EldrickWT
EldrickWT / dfhacklazymulti.txt
Created August 21, 2014 08:01
Some lazy lines for running mutiple DFHack commands v0.40.0x
Say you want to run multiple commands at once... or you at having the darnedest time making your command prompt/terminal obey. Here's some quick tips.
:lua dfhack.run_command "createitem HELM:ITEM_HELM_HOOD CREATURE:SPIDER_CAVE_GIANT:SILK 2" dfhack.run_command "createitem HELM:ITEM_HELM_HELM INORGANIC:STEEL 1" dfhack.run_command "regrass"
multicmd createitem HELM:ITEM_HELM_HOOD CREATURE:SPIDER_CAVE_GIANT:SILK 2; createitem HELM:ITEM_HELM_HELM INORGANIC:STEEL 1; regrass
Also there's the external tool "dfhack-run" (which'll even allow the help messages to run... 'dfhack-run ?' or the command list 'dfhack-run ls -a'). You'll need to0 put the commands into a batchfile (.bat on windows) or a file with execution parameters for osx/linux (chmod +x).
Just like with lua or ruby you'll need to select any targets before you run dfhack-run.
@EldrickWT
EldrickWT / zapalltagstesting.txt
Last active August 29, 2015 14:04
Zapalltags Testing for DF v0.40.06
The c_v piece that just worked to blast a vanilla install.
[CREATURE_VARIATION:CRASH]
[CV_REMOVE_TAG:CURIOUSBEAST_EATER]
[CV_REMOVE_TAG:CURIOUSBEAST_GUZZLER]
[CV_REMOVE_TAG:CURIOUSBEAST_ITEM]
[CV_REMOVE_TAG:DESCRIPTION]
[CV_REMOVE_TAG:MATERIAL]
[CV_REMOVE_TAG:MATERIAL_TEMPLATE
[CV_REMOVE_TAG:MELTING_POINT]
@EldrickWT
EldrickWT / git bash bits...for dfhack
Created July 21, 2014 05:35
If you're using the git bash command prompt...
Some of this you're likely already passed but... it's late and my brain is demanding I try to be a tad thorough
change to your dfhack directory... For Example
cd /p/DFHack-40.04
it should show (Master) on the end like so:
Cackling@Bogeyman-PC /p/DFHack-40.04 (Master)
#
cd library/xml
@EldrickWT
EldrickWT / civviesplosion.cpp
Last active December 14, 2015 13:09
civviesplosion.cpp For DFHack r3... Add "DFHACK_PLUGIN(civviesplosion civviesplosion.cpp)" to CMakeLists.txt. Any friendly unit targetted is a reference point to that unit's species -if there's a 'female'- having pregnancies. AS IT IS FIGHTING ME ON CURSOR POSITIONING -note the debug lines- I've given up on this C++ variant and have converted it…
// Civvie( Ex)plosion based on catsplosion
// By Zhentar , Further modified by dark_rabite, peterix, belal
// This work of evil makes Civilians (aka Dwarves) pregnant
// and due within 2 in-game hours...
// for 34.11
#include <iostream>
#include <cstdlib>
#include <assert.h>
#include <climits>