Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 171 172 [173] 174 175 ... 373

Author Topic: DFHack 0.34.11 r3  (Read 1457029 times)

falsefaith

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2580 on: December 03, 2012, 12:24:39 pm »

I'm trying to build dfhack on osx and ran into this error:

[ 73%] Building CXX object plugins/CMakeFiles/automaterial.dir/automaterial.cpp.o
/Users/williamreichelt/dfhack/plugins/automaterial.cpp: In function 'bool move_material_to_top(MaterialDescriptor&)':
/Users/williamreichelt/dfhack/plugins/automaterial.cpp:220:49: error: invalid initialization of non-const reference of type 'MaterialDescriptor&' from an rvalue of type 'MaterialDescriptor'
/Users/williamreichelt/dfhack/plugins/automaterial.cpp:153:13: error: in passing argument 1 of 'void set_last_moved_material(MaterialDescriptor&)'
make[2]: *** [plugins/CMakeFiles/automaterial.dir/automaterial.cpp.o] Error 1
make[1]: *** [plugins/CMakeFiles/automaterial.dir/all] Error 2
make: *** [all] Error 2
Logged

ag

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2581 on: December 03, 2012, 12:47:01 pm »

/Users/williamreichelt/dfhack/plugins/automaterial.cpp:220:49: error: invalid initialization of non-const reference of type 'MaterialDescriptor&' from an rvalue of type 'MaterialDescriptor'
/Users/williamreichelt/dfhack/plugins/automaterial.cpp:153:13: error: in passing argument 1 of 'void set_last_moved_material(MaterialDescriptor&)'

https://github.com/angavrilov/dfhack/commit/e7905a5cff2b6174d92527ab6bbdd8358b98b877#L6L140
Logged

falsefaith

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2582 on: December 03, 2012, 01:03:39 pm »

Logged

falconne

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2583 on: December 03, 2012, 01:53:52 pm »

https://github.com/angavrilov/dfhack/commit/e7905a5cff2b6174d92527ab6bbdd8358b98b877#L6L140

I'm not sure what to do with that...all this technical stuff is not my area of expertise.

This is to do with my plugin, not base dfhack. I'll help you out when I get back from work.
Logged
Utility plugins for DFHack, for improving Dwarf Fortress' user interface.

Urist Da Vinci

  • Bay Watcher
  • [NATURAL_SKILL: ENGINEER:4]
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2584 on: December 03, 2012, 04:19:37 pm »


Typical ghost data https://github.com/angavrilov/df-structures/blob/master/df.units.xml#L867
Code: [Select]
type                     = 9
unk_2                    = 9
unk_4                    = 5
unk_8                    = 113
unk_pos                  = <coord: 0x11c77644>
unk_14                   = 403200
unk_18                   = 0
unk_1c                   = 0
unk_20                   = 4510
unk_24                   = 4533
unk_28                   = 145

Verified type changes the displayed ghost type.

unk_4 is the ghost's "mission". Most of the time it is -1. When a ghost is on the move and going to do something, it has another value. Known values:
Code: [Select]
0  X has been scared to death by the G
1  G paralyzes X / G makes X convulse and retch / G stuns X / G causes a spell of dizziness in X
2  G batters X
3  X is throwing a tantrum, possessed by G
4  ?
5  <victim thought "haunted by dead"
6  <victim thought "tormented by dead" or "tormented in nightmares by dead"
7+ ?


unk_8 is the id of the current (if the ghost is inbound) or most recent victim of the ghost. For example, my test dwarves were 113, 114, 115, 116, 117, 118, 119. I set unk_8 to 119 and unk_4 to 0 on a restless haunt, and it immediately flew over to scare the targeted dwarf to death. It then resumed its normal haunting (on a counter of some sort, the mission is set to 5 and the new victim is chosen).

I don't know what the others do, but unk_pos may be static at -30000,-30000,-30000 while there may be another coord in the data afterwards. Unk_14 changes often, but only when the ghost is moving. Unk_20 and Unk_24 were very close but slightly different for two dwarves that were crushed by the same drawbridge.

Warmist

  • Bay Watcher
  • Master of unfinished jobs
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2585 on: December 03, 2012, 04:32:49 pm »

some research on advmode to fortmode switching:
this script does just that:
https://gist.github.com/4198190
todo: add units to positions so you could appoint squads etc...

ag

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2586 on: December 04, 2012, 02:43:25 am »

unk_4 is the ghost's "mission". Most of the time it is -1. When a ghost is on the move and going to do something, it has another value. Known values:

unk_8 is the id of the current (if the ghost is inbound) or most recent victim of the ghost. For example, my test dwarves were 113, 114, 115, 116, 117, 118, 119. I set unk_8 to 119 and unk_4 to 0 on a restless haunt, and it immediately flew over to scare the targeted dwarf to death. It then resumed its normal haunting (on a counter of some sort, the mission is set to 5 and the new victim is chosen).

I don't know what the others do, but unk_pos may be static at -30000,-30000,-30000 while there may be another coord in the data afterwards. Unk_14 changes often, but only when the ghost is moving. Unk_20 and Unk_24 were very close but slightly different for two dwarves that were crushed by the same drawbridge.

Added: https://github.com/angavrilov/df-structures/commit/784e72cc441a7602af4a4acc559d898ed675cf3b
Logged

thistleknot

  • Bay Watcher
  • Escaped Normalized Spreadsheet Berserker
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2587 on: December 06, 2012, 03:12:17 am »

can't build latest iteration of dfhack

C:\Games\dfdev\dfhack\pre\dfhack\build>generate-MSVC-all.bat

C:\Games\dfdev\dfhack\pre\dfhack\build>IF EXIST DF_PATH.txt SET /P _DF_PATH= 0<D
F_PATH.txt

C:\Games\dfdev\dfhack\pre\dfhack\build>IF NOT EXIST DF_PATH.txt SET _DF_PATH=C:\
Games\dfdev\dfhack\pre\dfhack\build\DF

C:\Games\dfdev\dfhack\pre\dfhack\build>mkdir VC2010
A subdirectory or file VC2010 already exists.

C:\Games\dfdev\dfhack\pre\dfhack\build>cd VC2010

C:\Games\dfdev\dfhack\pre\dfhack\build\VC2010>echo generating a build folder
generating a build folder

C:\Games\dfdev\dfhack\pre\dfhack\build\VC2010>cmake ..\.. -G"Visual Studio 10" -
DCMAKE_INSTALL_PREFIX="C:\Games\dfdev\dfhack\pre\df_34_11_win" -DBUILD_DEVEL=1 -
DBUILD_DEV_PLUGINS=1 -DBUILD_DF2MC=1 -DBUILD_DFUSION=1 -DBUILD_STONESENSE=1 -DBU
ILD_SERVER=1
-- The C compiler identification is unknown
-- The CXX compiler identification is unknown
CMake Error at depends/clsocket/CMakeLists.txt:50 (MESSAGE):
  Using unknown WIN32 compiler...  NOT.  Please add to build system.

however, my generate.bat file works on a prior version...

thistleknot

  • Bay Watcher
  • Escaped Normalized Spreadsheet Berserker
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2588 on: December 06, 2012, 11:17:47 am »

can someone post new instructions to build ag's version of dfhack...

I followed the instructions last night to no avail, to jump onto the freenode dfhack irc channel to find out peterix is outdated, that I need to do these witchcraft commands to pull the ag's build and work from it.

Urist Da Vinci

  • Bay Watcher
  • [NATURAL_SKILL: ENGINEER:4]
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2589 on: December 08, 2012, 02:06:32 am »

Using this lua code:
Code: [Select]
local race

for k,v in pairs(df.global.world.populations) do
if (df.global.world.populations[k].type==1) and (df.global.world.populations[k].race==430) then
print(v)
race = df.global.world.populations[k].race
print(df.global.world.raws.creatures.all[race].creature_id)
print(df.global.world.populations[k].quantity)
print(" ")

end
end
I have been able to track the decreasing population of fish in a surface stream. In particular, I had a test embark where only mussels were extracted from the stream. You get results like this:
Code: [Select]
<local_population: 0x040f1748>
MUSSEL
298

<local_population: 0x040f37e0>
MUSSEL
311

<local_population: 0x040fdd40>
MUSSEL
306  --------- this one decreases by 3 if someone removed mussel[3] from the stream

<local_population: 0x04100468>
MUSSEL
366

<local_population: 0x04110eb0>
MUSSEL
349

<local_population: 0x041135d8>
MUSSEL
436

Now I found that I could accelerate the arrival of "There is nothing to catch in the river" by reducing the quantity, or forestall it by increasing the quantity. However once there were no mussels left, the area became unfishable even if I set the population high again. Unfishable= you see zero fishing tiles when painting the fishing zone. The unfishable thing only applies to the one embark tile that everyone was fishing in, but not other parts of the map.

When looking at cave fish (race=510 in vanilla 0.34.11), there is a population of 1-2 cave fish, which can be seen teleporting around the underground lake. Fishing in the underground lake gets the "nothing to catch" message, without catching that one fish and without making the area unfishable. Increasing the cave fish populations using dfhack doesn't allow fisherdwarves to actually catch anything, but greatly increases the number of fish that can be seen teleporting around the underground lake.


Therefore each embark tile (those 48*48*Z areas of the map) or perhaps the river features have some kind of flag that informs the game that it has been fished out.
Unrelatedly, cave fishing doesn't behave the same way as river fishing, and something is causing cave fish populations to be very low despite what the raw files indicate.

If I multiply the cave fish pops in the raw files by 100, and generate a new world, some of the quantities in the list outputted by my lua code are between 90-110, while others are still 1. However I still got the "nothing to catch" message when fishing in several cavern locations, despite the visible teleporting cave fish.

MoloMowChow

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2590 on: December 08, 2012, 02:18:08 am »

so I'm using advtools metal-detector, but what do I type to specify a specific type?
Logged

Flare

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2591 on: December 08, 2012, 02:27:15 am »

Is there a hack that shows which columns of tiles goes right down to a magma source that is uninterrupted by empty space?
Logged

MasterShizzle

  • Bay Watcher
  • Constantly in a fey mood
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2592 on: December 08, 2012, 03:01:47 am »

Is there a hack that shows which columns of tiles goes right down to a magma source that is uninterrupted by empty space?
You can always pause the game and use "reveal all", scroll down to the caverns and find a solid column, designate it to be dug, and then use "unreveal" to go back to what it was. It won't affect feature discovery, so you won't have cave moss in your fort if you haven't yet breached caverns and you won't be able to build magma workshops until your dwarves actually see magma.
Logged
Boss is throwing a tantrum!
MasterShizzle cancels Play Dwarf Fortress: interrupted by Boss

Minecraft's fine, your computer just sucks.

Flare

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2593 on: December 08, 2012, 03:48:15 am »

Actually, I just meant finding the solid column. When I play with the default 3 cavern layers, finding a sufficiently sized column for whatever I'm doing tends to be quite hard since said column of tiles have to climb through 3 caverns unobstructed by empty space.
Logged

WillowLuman

  • Bay Watcher
  • They/Them Life is weird
    • View Profile
Re: DFHack 0.34.11 r2
« Reply #2594 on: December 08, 2012, 04:12:06 am »

How would I resurrect a dead adventure mode companion?
Logged
Dwarf Souls: Prepare to Mine
Keep Me Safe - A Girl and Her Computer (Illustrated Game)
Darkest Garden - Illustrated game. - What mysteries lie in the abandoned dark?
Pages: 1 ... 171 172 [173] 174 175 ... 373