v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Difference between revisions of "User:Dukederek"

From Dwarf Fortress Wiki
Jump to navigation Jump to search
Line 72: Line 72:
 
Send d<br>
 
Send d<br>
 
Send {NumpadAdd}<br>
 
Send {NumpadAdd}<br>
Send d<br>
 
        Send {NumpadAdd}<br>
 
 
Send d<br>
 
Send d<br>
 
Send {right}<br>
 
Send {right}<br>

Revision as of 20:45, 21 January 2008

Dump Macro

I have written a dump macro for AutoHotKey which works something like the designation tools in the actual DF interface. The current limitation is that it only works if you start at the top left of the group of tiles you wish to dump and finish at the bottom right.

I have mapped it to "ctrl-return" so that it can be left running when not needed and not interfere with any other commands in DF.

To use.

  • Go to the top leftmost square you want to dump using the k "look around" button
  • Press "ctrl-return"
  • Using w a s d, move the yellow cross to the bottom rightmost square of things you wish to dump. To cancel press q
  • press k

The limitations are that only the first three items on each tile's list are set to be dumped. Also, it seems non-trivial to map this to the arrow keys rather than w a s d but that's not so bad right?

Here is the code, for those not in the know install autohotkey, paste the text below into a file named "blockdump.ahk" or something, double click the file so there is a green and white "H" icon in your system tray.


Code Below:

^return::
x = 0
y = 0
IfWinActive Dwarf Fortress
{
Loop
{
Input, keypress, B, {esc} , w,a,s,d,k,q
if keypress = w
{
y := --y
Send {up}
continue
}
else if keypress = s
{
y := ++y
Send {down}
continue
}
else if keypress = a
{
x := --x
Send {left}
continue
}
else if keypress = d
{
x := ++x
Send {right}
continue
}
else if keypress = k
{
break
}
else if keypress = q
{
Return
}
}
SetKeyDelay 1
Send {left %x%}
Send {up %y%}
x := x + 1
y := y + 1

Loop %y%
{
Loop %x%
{
Send d
Send {NumpadAdd}
Send d
Send {right}
}
Send {left %x%}
Send {down}
}
Loop %y%
{
Send {up}
}
}
else
return