Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 295 296 [297] 298 299 ... 373

Author Topic: DFHack 0.34.11 r3  (Read 1455994 times)

ag

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4440 on: August 26, 2013, 09:42:50 am »

The tweak is the same thing as the fix, only coded in C++ and set up to run every time the crashed code is about to be called. Falconne can probably build it for you ;)

How do you make that save crash?
Logged

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: DFHack 0.34.11 r3
« Reply #4441 on: August 26, 2013, 10:31:11 am »

You dont have to do anything but wait. It takes a few minutes, but my netbook is slow. If you keep it at 150FPS (if your machine can handle that) it shouldnt take long.

Ok, thanks. I have the crashfix included in the current download, I'll see that I can get a compiled C++ version in the next update. :)
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4442 on: August 26, 2013, 10:50:04 am »

Yeah, that was the only other thing I could think of. Maybe I will just wait on hybrid classes until more functionality is added to the interactions and syndromes. With 24 non-hybrid classes that should be good enough for now. I wish CE_DISPLAY_NAME and CE_DISPLAY_TILE were more functional
Logged

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: DFHack 0.34.11 r3
« Reply #4443 on: August 26, 2013, 10:55:23 am »

Can you get the display tile to work on civ-members at all? I only got either no effect, or a flickering tile.
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Roses

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4444 on: August 26, 2013, 11:04:20 am »

Can you get the display tile to work on civ-members at all? I only got either no effect, or a flickering tile.

I never got it to work, I think creature graphics overrides it maybe?
Logged

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: DFHack 0.34.11 r3
« Reply #4445 on: August 26, 2013, 11:13:47 am »

Same here. The sprites overwrite the display_tile, but the flash_tile works. the problem is that the flask_tile frequency does not accept a 0. I wanted to to 0 for the default tile and 99999 for the flash tile... but even then it flickers every tick. But it displays the alternative tile.

I also found a way with nobles, because you can make as many profession sprites as you like... but you have tons of nobles then. ^^
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

fricy

  • Bay Watcher
  • [DFHACK:ZEALOT]
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4446 on: August 27, 2013, 03:47:08 am »

Question: The spatter_add plugin is loaded when dfhack finds the string SPATTER_ADD_ in the raws. Correct? Any other strings that activate the plugin?

ag

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4447 on: August 27, 2013, 05:22:04 am »

You dont have to do anything but wait. It takes a few minutes, but my netbook is slow. If you keep it at 150FPS (if your machine can handle that) it shouldnt take long.

I ran it a couple of times. What seems to happen is that almost immediately a siege comes, and eventually everybody (or almost everybody) dies.
Logged

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: DFHack 0.34.11 r3
« Reply #4448 on: August 27, 2013, 07:51:42 am »

Mh... I can try to run the save again and give you more info. Sorry if I wasted your time with it. Maybe I can reproduce the crash again and quicksave a few seconds before it.

EDIT: Could someone please add a timer into this? its the slayrace.rb script, which has the command "slayrace creature-name magma", which drops magma on top of creatures. It would be really useful if that magma-flow would stop after a certain amount of ingame ticks (or even RL seconds). I want to make a magma-spawning creature with it. It works, but the creature never stops to spawn it. ^^

Code: [Select]
# slay all creatures of a given race

# race = name of the race to eradicate, use 'him' to target only the selected creature
# use 'undead' to target all undeads
race = $script_args[0]

# if the 2nd parameter is 'magma', magma rain for the targets instead of instant death
magma = ($script_args[1] == 'magma')

checkunit = lambda { |u|
(u.body.blood_count != 0 or u.body.blood_max == 0) and
not u.flags1.dead and
not u.flags1.caged and not u.flags1.chained and
#not u.flags1.hidden_in_ambush and
not df.map_designation_at(u).hidden
}

slayit = lambda { |u|
if not magma
# just make them drop dead
u.body.blood_count = 0
# some races dont mind having no blood, ensure they are still taken care of.
u.animal.vanish_countdown = 2
else
# it's getting hot around here
# !!WARNING!! do not call on a magma-safe creature
ouh = df.onupdate_register("slayrace ensure #{u.id}", 1) {
if u.flags1.dead
df.onupdate_unregister(ouh)
else
x, y, z = u.pos.x, u.pos.y, u.pos.z
z += 1 while tile = df.map_tile_at(x, y, z+1) and
tile.shape_passableflow and tile.shape_passablelow
df.map_tile_at(x, y, z).spawn_magma(7)
end
}
end
}

all_races = Hash.new(0)

df.world.units.active.map { |u|
if checkunit[u]
if (u.enemy.undead or
    (u.curse.add_tags1.OPPOSED_TO_LIFE and not
     u.curse.rem_tags1.OPPOSED_TO_LIFE))
all_races['Undead'] += 1
else
all_races[u.race_tg.creature_id] += 1
end
end
}

case race
when nil
all_races.sort_by { |race, cnt| [cnt, race] }.each{ |race, cnt| puts " #{race} #{cnt}" }

when 'him'
if him = df.unit_find
slayit[him]
else
puts "Select a target ingame"
end

when /^undead/i
count = 0
df.world.units.active.each { |u|
if (u.enemy.undead or
    (u.curse.add_tags1.OPPOSED_TO_LIFE and not
     u.curse.rem_tags1.OPPOSED_TO_LIFE)) and
   checkunit[u]
slayit[u]
count += 1
end
}
puts "slain #{count} undeads"

else
raw_race = df.match_rawname(race, all_races.keys)
raise 'invalid race' if not raw_race

race_nr = df.world.raws.creatures.all.index { |cr| cr.creature_id == raw_race }

count = 0
df.world.units.active.each { |u|
if u.race == race_nr and checkunit[u]
slayit[u]
count += 1
end
}
puts "slain #{count} #{raw_race}"

end
« Last Edit: August 27, 2013, 11:22:59 am by Meph »
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

Rose

  • Bay Watcher
  • Resident Elf
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4449 on: August 27, 2013, 11:56:53 am »

Question: The spatter_add plugin is loaded when dfhack finds the string SPATTER_ADD_ in the raws. Correct? Any other strings that activate the plugin?

Incorrect. The plugin is always loaded.
Logged

fricy

  • Bay Watcher
  • [DFHACK:ZEALOT]
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4450 on: August 27, 2013, 12:54:39 pm »

Question: The spatter_add plugin is loaded when dfhack finds the string SPATTER_ADD_ in the raws. Correct? Any other strings that activate the plugin?
Incorrect. The plugin is always loaded.

Thx Japa. Hmmm. So the "hooks detected" message in the console is not the plugin loading. Ok.
I'm trying to hunt down a crash on osx that seems to be connected to the add_spatter plugin and masterwork mod v3. At least when I remove the plugin the game doesn't crash.

Here's what I know: I tested the raws of MW mod 2h, and the mod works. However with any version of masterwork v3+ the game crashes at worldgen/load. After ag found the buffer overflow bug, and Meph fixed the reactions I was hoping the the crash would go away, but no. So I started deleting the reactions/interactions/entities from the MW.3.g raws to narrow down a possible faulty reaction. I even replaced the "spatter" string in the language files to make sure it doesn't interferes, eliminated every spatter reaction from the raws, but the game still crashes on worldgen when placing the civs. The crash report blames the spatter_add plugin, even though the spatter string is absent in the raws folder. http://pastebin.com/YcR9CEuP http://pastebin.com/Ppnz7z49

I tested the same "spatterless" 3.g raws on windows, the game seems to work, but I got a couple of crashes, and the lenght of the worldgen seems to be random.
I'm now out of ideas how to proceed, any tips?
« Last Edit: August 27, 2013, 12:58:56 pm by fricy »
Logged

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: DFHack 0.34.11 r3
« Reply #4451 on: August 28, 2013, 06:37:58 am »

Is there a flag for hungry/starving? I have several lua scripts that target a unit and change attributes, like this: "unit.status.current_soul.traits.ANXIETY=1", if I could replace this with hunger YES/NO that would allow me to make stables to feed grazers. Like "unit.status.hunger=0" or so... I initially tried with NO_EAT, but that doesnt work. It adds the tag, but it only suspends the hunger. as soon as NO_EAT runs out, the creature is back to starving.

I only found this on github:
Code: [Select]
// Hunger etc timers

    bool is_adventure = (gamemode && *gamemode == game_mode::ADVENTURE);
...
 
996
997
998
999
        rating, is_adventure, unit->counters2.hunger_timer,
        75000, 75000, 172800, 1209600, 2592000
    );
    if (is_adventure && unit->counters2.sleepiness_timer >= 846000)



EDIT: For Ag, or whoever wants to try their luck:

Reproduceable Crash Save

Save crashes after about 15 seconds.

Errorlog shows these:
*** Error(s) found in the file "data/save/crash v3g/raw/objects/creature_random_rc.txt"
CREATURE_1UIHEAXII_RC:Body Token Recognized But Could Not Connect: 3TOES_FQ_REG
CREATURE_1OUGEUAAM_RC:Attack SCRATCH seems to have correct format but could not find proper BPs in any caste, so not added
CREATURE_1VXHUFWOM_RC:Attack BITE seems to have correct format but could not find proper BPs in any caste, so not added
CREATURE_1FZQUUEJA_RC Color Mod Ending With (BLACK,1) Was Not Used
CREATURE_1LBXMNTFA_RC:Attack CLAW seems to have correct format but could not find proper BPs in any caste, so not added
Unrecognized Caste Token in Body Transformation Effect: creature X a lot
Unrecognized Inorganic Token: WARPSTONE_SOLID X a lot.

The first 5 are from random creatures from Talvienos random creature generator. The unrecognized creatures are from kobold mode, because they are removed when you play dwarves. The warpstone is missing because the person is playing with "Harder Mining:Off", which removes this harmfull stone. None of these cause crashes.

I did "unload all" on dfhack and burrowed all the dwarves, so its neither a dfhack plugin (I hope), nor a job that is finished and that creates some kind of game-breaking item. It his however the 4th crash I get that crashes in autumn, with no traders on the map. I strongly suspect that the caravan brings either invalid items or materials that crash the game. I checked the embark selection for dwarves for any weird entries, but all looks fine. Is there a way to check what kinds of items/materials a civ has access to?
« Last Edit: August 28, 2013, 06:53:01 am by Meph »
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

ag

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4452 on: August 28, 2013, 10:32:43 am »

Nope, no crashing for me - neither with dfhack, nor in a fully vanilla copy of DF, both windows and linux.

You can check if it crashes for you in a fresh original copy, and if  not, see what changes to the options and files make things start breaking.
Logged

Meph

  • Bay Watcher
    • View Profile
    • worldbicyclist
Re: DFHack 0.34.11 r3
« Reply #4453 on: August 28, 2013, 10:58:00 am »

Interesting. I loaded it 4 times, and it crashed 4 times, no matter what I did. So it is system dependant. Did a caravan arrive in your game?  If yes, could you upload the save with the caravan on the map? I would really like to check what kind of items their carry.

I have Win7 on my netbook. He has Win7 as well.

Adding the save to a fresh DF copy makes no sense, because all the raw-modding would be ported over. If it does not crash for you with my patched exe, then it has nothing to do with the exe itself. The Settings.exe does only modify the base-raws, the set that DF uses to make a new world, it does not influence a save. In general, I dont update saves with new raws...

But thats good news, in a way. Thanks for the effort. :)
Logged
::: ☼Meph Tileset☼☼Map Tileset☼- 32x graphic sets with TWBT :::
::: ☼MASTERWORK DF☼ - A comprehensive mod pack now on Patreon - 250.000+ downloads and counting :::
::: WorldBicyclist.com - Follow my bike tours around the world - 148 countries visited :::

ag

  • Bay Watcher
    • View Profile
Re: DFHack 0.34.11 r3
« Reply #4454 on: August 28, 2013, 11:13:27 am »

Well, adding the save to a fresh copy is what I do, since I have no others. It's either fully fresh copy, or the same with my usual graphics pack and development build of dfhack installed. And if by any chance it doesn't crash in a fresh copy for you too, then you can start from that to figure out what specific difference between fresh and non-fresh copy affects it.

Re operating system, I tested it on linux, linux+wine and a Win XP VM.
Logged
Pages: 1 ... 295 296 [297] 298 299 ... 373