Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 7 8 [9] 10 11 ... 373

Author Topic: DFHack 0.34.11 r3  (Read 1456531 times)

Qmarx

  • Bay Watcher
  • "?"
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #120 on: September 09, 2011, 02:41:52 pm »

Fair enough.  I might as well also comment that reloading the stonesense plugin causes the whole thing to hang, including dwarf fortress and the console window.

It's happened every time I've tried it, but I've only tried it three times, so it's entirely possible that it's just a coincidence.
Logged

Rose

  • Bay Watcher
  • Resident Elf
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #121 on: September 09, 2011, 02:46:01 pm »

The main issue is that the person that needs to fix it is a total dumbass that doesn't know what he's doing.

Really, you'd have better luck from a trained monkey.
Logged

lordnincompoop

  • Bay Watcher
  • Allusionist
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #122 on: September 09, 2011, 06:48:45 pm »

Love the new tools. Keep up the good work!

Also, would auto-designation of spheres be a possible feature? 3d shapes would be of great help for, say, mining.
Logged

Greiger

  • Bay Watcher
  • Reptilian Illuminati member. Keep it secret.
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #123 on: September 09, 2011, 09:04:11 pm »

Really, you'd have better luck from a trained monkey.

Now now Japa, you are doing a fine job, and there are some really stupid trained monkeys out there.  I think I work with some wearing human suits.

As for the crashing DF thing, did you try DFUnstuck to try to get DF running again?  Most (all?) DFHack based tools actually suspend the Dwarf Fortress process so that values don't change while it does it's thing.  When a DFHack program fails it often cannot tell Dwarf Fortress to start running again.   DFUnstuck's only purpose is to tell the Dwarf Fortress process to start running again.
Logged
Disclaimer: Not responsible for dwarven deaths from the use or misuse of this post.
Quote
I don't need friends!! I've got knives!!!

Rose

  • Bay Watcher
  • Resident Elf
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #124 on: September 09, 2011, 09:25:03 pm »

You have outdated info.

DFunstuck only works for the old DFhack.

the new one works completely differently.
Logged

Greiger

  • Bay Watcher
  • Reptilian Illuminati member. Keep it secret.
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #125 on: September 10, 2011, 09:06:28 am »

Ah.  Well I tried.

I blame society.
Logged
Disclaimer: Not responsible for dwarven deaths from the use or misuse of this post.
Quote
I don't need friends!! I've got knives!!!

peterix

  • Bay Watcher
    • View Profile
    • Dethware
Re: DFHack 0.31.25 r6 (current)
« Reply #126 on: September 11, 2011, 04:08:28 am »

Is there a way to use DFHack to change the cook/brew settings for a material, as normally controlled by the Status->Kitchen screen in DF?  I've looked for it, but not found it.  Assuming that DFHack didn't have that feature, I tried to use Cheat Engine to see what happens when I toggle those settings, but I couldn't work out what was going on - it didn't look like simple bit flags were involved.  Any help would be much appreciated.
Well, it doesn't do it. It's never so easy - it's probably a single bit in some bit field squirelled away somewhere...
When I try to run stonesense from the dfhack window, the stonesense window pops up.  It creates an image of the current DF window just fine, but after that stonesense doesn't refresh, and trying to close it results in DF crashing.
Hmm.. haven't seen that problem before.
I might as well also comment that reloading the stonesense plugin causes the whole thing to hang, including dwarf fortress and the console window.
It's happened every time I've tried it, but I've only tried it three times, so it's entirely possible that it's just a coincidence.
I thought I fixed that. It was consistently causing crashes before. What OS is that? And how many CPU cores do you have? Are you sure you're running the latest version of DFHack?
Also, would auto-designation of spheres be a possible feature? 3d shapes would be of great help for, say, mining.
Yes :)

Quietust

  • Bay Watcher
  • Does not suffer fools gladly
    • View Profile
    • QMT Productions
Re: DFHack 0.31.25 r6 (current)
« Reply #127 on: September 11, 2011, 11:21:11 am »

The following 5 vectors appear to be used for cook/brew exclusions:
0x014F0BB4 (int16) - item type (e.g. MEAT, SEEDS, PLANT, DRINK - see here for numeric IDs)
0x014F0BC4 (int16) - item subtype (generally -1)
0x014F0BD4 (int16) - material (19-218 for creature materials, 419-618 for plant materials)
0x014F0BE4 (int32) - submaterial (the creature/plant ID)
0x014F0BF4 (int8) - type (1 = do not cook, 2 = do not brew)
« Last Edit: September 11, 2011, 11:25:28 am by Quietust »
Logged
P.S. If you don't get this note, let me know and I'll write you another.
It's amazing how dwarves can make a stack of bones completely waterproof and magmaproof.
It's amazing how they can make an entire floodgate out of the bones of 2 cats.

Twobeard

  • Bay Watcher
  • Servant of the Beard
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #128 on: September 13, 2011, 08:20:57 am »

Once i get my new machine in this is totally going into action. Thanks again for all your hard work. You are a beardy beardy dwarf.
Logged
A leg of ham, a jug of beer and thou besides me, whistling in the darkness.

Rumrusher

  • Bay Watcher
  • current project : searching...
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #129 on: September 14, 2011, 10:09:18 pm »

so does this mean we can finally cook and brew sentient meats now and or use their bones and limbs for crafting?
Logged
I thought I would I had never hear my daughter's escapades from some boy...
DAMN YOU RUMRUSHER!!!!!!!!
"body swapping and YOU!"
Adventure in baby making!Adv Homes

Quietust

  • Bay Watcher
  • Does not suffer fools gladly
    • View Profile
    • QMT Productions
Re: DFHack 0.31.25 r6 (current)
« Reply #130 on: September 15, 2011, 09:52:27 am »

so does this mean we can finally cook and brew sentient meats now and or use their bones and limbs for crafting?
And how exactly would you expect to be able to do that?
Logged
P.S. If you don't get this note, let me know and I'll write you another.
It's amazing how dwarves can make a stack of bones completely waterproof and magmaproof.
It's amazing how they can make an entire floodgate out of the bones of 2 cats.

Rumrusher

  • Bay Watcher
  • current project : searching...
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #131 on: September 16, 2011, 04:50:41 am »

oh yeah well you could just slap tame and slaughter(both creature flags) on a friendly/citizen and watch them get drag to the butcher workshop.
My only gripe was doing so led to unused material and rotten meat left to waste I don't think this is even connected to ethics and just hardcoded into the game.

oh and before I forget here's the Git Dfusion codes for race change by wounds and type of race so that one could set up either a zombie mod with infections that convert or magical items that change the user into a wizard and grant magical spells.

Code: [Select]
function tools.lycanressurecttest()
RaceTable=RaceTable or BuildNameTable() --slow.If loaded don't load again
--repeat --remove the "--" if you want this to run while you play
local trgs=selecthuman()
for k,v in pairs(trgs) do
--indx=GetCreatureAtPos(v)
--indx=engine.peek(v,ptr_creature.ID)
--local trgs=selectwolf()
--for t,z in pairs(trgs) do
id2=RaceTable["WIZARD"] -- this is the race the victim will turn into
engine.poke(v,ptr_Creature.race,id2)
print("Infected:"..k) --counts how many turned left in for the player to see if any one converted or not.
v2=engine.peek(v,ptr_Creature.hurt1)
for i=0,v2:size()-1 do
v2:setval(i,0)
end
v2=engine.peek(v,ptr_Creature.hurt2)
v2.type=DWORD
for i=0,v2:size()-1 do
v2:setval(i,0)
end

engine.peek(v,ptr_Creature.civ)
engine.poke(v,ptr_Creature.civ,-1) --for wizard or magical spell caster race transformations remove this and the line above it to prevent hostile demi gods
engine.poke(v,ptr_Creature.bloodlvl,60000) --give blood
engine.poke(v,ptr_Creature.bleedlvl,24) --stop some bleeding...
--end
end
--until k==100 --remove the "--" if you want this to run while you play
end
function selecthuman() -- this will create a list of creatures who been hurt a curtain way and have the same race.
  local retvec={} --return vector (or a list)
  myoff=offsets.getEx("AdvCreatureVec")
  RaceTable=RaceTable or BuildNameTable()
  vector=engine.peek(myoff,ptr_vector) --standart start
  for i=0,vector:size()-1 do --check all creatures
     local off
     off=vector:getval(i)
     local id=engine.peek(off,ptr_Creature.race)
     local v2=engine.peek(off,ptr_Creature.hurt1)
ra=RaceTable["KEEPER"] --genesis
ra2=RaceTable["HUMAN"] --normal
     if id==ra or id==ra2 and v2:getval(12)>=1 and v2:getval(8)==0 then -- this checks if the race match ra or ra2 and checks their body parts to see if they aren't dented in the right upper arm and still have their heads
        table.insert(retvec,off)--... add it to return vector
     end
  end
  return retvec --return the "return vector" :)
end

function tools.Hurtselected() --this baby is used for modders to test which body part they want to effect the victim and to see if the code above works out.
    --repeat
myoff=offsets.getEx("AdvCreatureVec")
vector=engine.peek(myoff,ptr_vector)
indx=GetCreatureAtPos(getxyz())
if indx<0 then return end
--print(string.format("%x",vector:getval(indx)))
v2=engine.peek(vector:getval(indx),ptr_Creature.hurt1)
v3=engine.peek(vector:getval(indx),ptr_Creature.hurt2)
v3.type=DWORD
print("select body part 0=upperbody,1=lowerbody,2=head,3=right front leg,4=left front leg,5=")
r=io.stdin:read()
t=r*4
print("select infliction")
d=io.stdin:read()
v2:setval(t,d)
v3:setval(r,d) --remove zero-th limb or something... same with hurt2
end

tools.menu:add("?harm part?",tools.Hurtselected)
tools.menu:add("?nonsave animal morph?",tools.lycanressurecttest)
Logged
I thought I would I had never hear my daughter's escapades from some boy...
DAMN YOU RUMRUSHER!!!!!!!!
"body swapping and YOU!"
Adventure in baby making!Adv Homes

toasteur

  • Bay Watcher
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #132 on: September 26, 2011, 02:43:07 pm »

quick question about the qtplug test:

is it possible to make it work under vs2010?

i managed to compile everything else in the solution except this which is the one i would like to make it work, if i wish one day to try to make therapist work with dfhack.

i got opengl, i got qt for visual and the configure seems to have everything it needs, but still it seems sdl is registered nowhere and i have the following problems:
   1   IntelliSense: namespace "SDL" has no member "Mutex"   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   21   13   qtplug
   2   IntelliSense: namespace "SDL" has no member "Thread"   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   23   13   qtplug
   3   IntelliSense: identifier "SDL_CreateMutex" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   34   22   qtplug
   4   IntelliSense: identifier "SDL_mutexP" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   47   5   qtplug
   5   IntelliSense: identifier "SDL_CreateThread" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   51   20   qtplug
   6   IntelliSense: identifier "SDL_mutexV" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   57   5   qtplug
   7   IntelliSense: identifier "SDL_mutexP" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   68   5   qtplug
   8   IntelliSense: identifier "SDL_mutexV" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   70   5   qtplug

any chance SDL was a global register on you dev machine and then as it's not on mine, it can't find the sdl namespace?

also, i can be considered a complete noob in c++ as i didn't touch it in year, and since dev in c# .NET, where referencing libraries is as easy as pointing to a reference dll in the project. no linking, no .h, no mysterious compiler choice in .NET, so i'm quite lost here if i have to manually configure the project which i assume is cmake role  :-[
Logged

peterix

  • Bay Watcher
    • View Profile
    • Dethware
Re: DFHack 0.31.25 r6 (current)
« Reply #133 on: September 26, 2011, 04:24:36 pm »

quick question about the qtplug test:

is it possible to make it work under vs2010?

i managed to compile everything else in the solution except this which is the one i would like to make it work, if i wish one day to try to make therapist work with dfhack.

i got opengl, i got qt for visual and the configure seems to have everything it needs, but still it seems sdl is registered nowhere and i have the following problems:
   1   IntelliSense: namespace "SDL" has no member "Mutex"   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   21   13   qtplug
   2   IntelliSense: namespace "SDL" has no member "Thread"   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   23   13   qtplug
   3   IntelliSense: identifier "SDL_CreateMutex" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   34   22   qtplug
   4   IntelliSense: identifier "SDL_mutexP" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   47   5   qtplug
   5   IntelliSense: identifier "SDL_CreateThread" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   51   20   qtplug
   6   IntelliSense: identifier "SDL_mutexV" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   57   5   qtplug
   7   IntelliSense: identifier "SDL_mutexP" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   68   5   qtplug
   8   IntelliSense: identifier "SDL_mutexV" is undefined   e:\_sources\dfhack_r2\plugins\qtplug\qtplug.cpp   70   5   qtplug

any chance SDL was a global register on you dev machine and then as it's not on mine, it can't find the sdl namespace?

also, i can be considered a complete noob in c++ as i didn't touch it in year, and since dev in c# .NET, where referencing libraries is as easy as pointing to a reference dll in the project. no linking, no .h, no mysterious compiler choice in .NET, so i'm quite lost here if i have to manually configure the project which i assume is cmake role  :-[
Hmm... what? It works only in MSVC 10.

  • First, get cmake.
  • Second, run the batch script in 'build' and let it generate things for you and present you with a nice GUI with options. Use the generated solutions and project files.
  • Third, Qt has some ugly limitations. You can only have a single QApplication object in a process. More than one, you'll get mystery crashes. This is why I abandoned that idea. It is possible to have a global QApplication, and share an event thread between plugins... but that's pure black magic. It is also possible to have a single plugin (yes, just one) using Qt. I'd rather find a toolkit that allows more without any singletons, globals or shared event threads. Or just not put GUIs into DF ;)
  • I'm assuming you have the MSVC 10 Qt. Last I checked, the most up-to-date binary release was for older MSVC versions. This is important. If you don't have it, you'll have to compile Qt yourself - that is, if you want to mess with Qt inside DF, which isn't very programmer friendly at all. Mixing two MSVC runtimes in a process is IMHO NOT a good idea, especially when dealing with memory hacking and when things have to be binary compatible at raw memory level.
  • It's possible the Qt plugin stuff doesn't work anymore - I haven't compiled it in ages. References to the SDL locking functions suggest as much.

So, I'll look into it. Stop by in #dfhack on freenode if you want to talk in real-time :)

toasteur

  • Bay Watcher
    • View Profile
Re: DFHack 0.31.25 r6 (current)
« Reply #134 on: September 26, 2011, 04:41:50 pm »

thanks for the answer.

if you say it's not such a good idea, i'll take your word for it.  :D

i will get back to my first idea which is to make a gui in c# .net and then in a first attempt use files in folders to communicate between my gui and a dfhack plugin running in a thread like stonesense or dfusion waiting for files to process.
since communications between the 2 programs should be scarse and spaced in time because a dwarf management tool is not so intensive as a stonesense, it should be a viable mean of communication for a start.

later, some kind of client/server data exchange service should allow for more "industrial" communications, but i'm not there yet and as much as i could implement it quickly in c#, i'm not so confident for the c++ part  :(, especially since i only dev web applications where communicating by webservices is only as hard as putting some attribute on class methods and letting visuall studio do al the work of creating the technical wires for both server and client...
Logged
Pages: 1 ... 7 8 [9] 10 11 ... 373