@ Harem Rose
yeah die is the command in dfhack to kill dwarf fortress takes a minute sometimes, you can't be in any menus or it just hangs.
nah stderr.log is a full list of "errors" in the last game session that was pushed by DFHack. Its readable in txt, so you don't have to make images of the dfhack console, as most of what it has going on is shown in stderr.log. makes it easier to just copy and paste errors, instead of screenshot. Its rewritten every time dfhack reloads.
@ boltgun:
OMG I hate this issue... we break this thing every 6 months, lol.
so I was going through corrupt I came across the mo.xxxx commands and I added these lines around it:
if unit.race == df.global.ui.race_id and debug then print('it should run make_citizen prior to exiting make_own') end
mo.make_own(unit)
if debug then print('we made it past make_own') end
if unit.race == df.global.ui.race_id and debug then print('it should of already ran make_citizen') end
mo.make_citizen(unit)
if debug then print('we made it past make_citizen') end
The interesting result is that the only line that printed was:
we made it past make_own
which is interesting to me as this line is in make_own:
if unit.race == df.global.ui.race_id then
followed by a call to make_citizen.... so I ran code to see what the two are at that point, so I changed the earlier code to:
if unit.race == df.global.ui.race_id and debug then print('it should run make_citizen prior to exiting make_own')
elseif debug then print('unit.race: '..df.global.world.raws.creatures.all[df.global.ui.race_id].creature_id..", df.global.ui.race_id: "..df.global.world.raws.creatures.all[df.global.ui.race_id].creature_id) end
to see what those 2 races are at that point... which I thought should be both SUCCUBUS... which they are and they are not...
as you can see in 2 different lines I have it pulling the numbers and the creature_id... and in both they are succubus, but they are different numbers....
that's more confusing then ever....
in makeown.lua they seem to have the confidence that the 2 should have the same number... but since they don't that's an error in makeown. it should be checking all the way down to the creature_id.... but the other end is why is SUCCUBUS in 2 creature_ids... I've checked a couple of times there is only one succubus definition in the folder. I can only think that its picking up something else like the entity file being labeled SUCCUBUS... I tried a few other variables and either hit error or got the same answer on that one.... so I'm not sure what it is doing or why... but I returned to the previous issue of anon....
I couldn't find out what they was from the dfhack github, etc.... so I first tried the script without the anon lines and... hit more errors... this time inside of corrupt.lua
here's the lines to change all related to the relations.....
function clearMerchant(unit)
local draggee
-- Free the draggee as well and makeown + tame it
if -1 ~= unit.relationship_ids.draggee_id then
dragee = utils.binsearch(df.global.world.units.active, unit.relationship_ids.draggee_id, 'id')
if dragee then
mo.make_own(dragee)
dragee.relationship_ids.dragger_id = -1
dragee.flags1.tame = true
dragee.training_level = df.animal_training_level.Domesticated
end
end
unit.relationship_ids.draggee_id = -1
unit.relationship_ids.rider_mount_id = -1
unit.relationship_ids.mount_type = 0
unit.flags1.rider = 0
end
-- Take the creature out of its cage
function clearCage(unit)
local cage = dfhack.units.getContainer(unit)
if -1 ~= cage then
teleport.teleport(unit, xyz2pos(dfhack.units.getPosition(unit)))
end
unit.flags1.caged = false
end
-- Takes down any hostility flags that mo didn't handle
function clearHostile(unit)
unit.population_id = popId
unit.cultural_identity = -1
unit.flags1.marauder = false
unit.flags1.active_invader = false
unit.flags1.hidden_in_ambush = false
unit.flags1.hidden_ambusher = false
unit.flags1.invades = false
unit.flags1.coward = false
unit.flags1.invader_origin = false
unit.flags2.underworld = false
unit.flags2.visitor_uninvited = false
unit.flags2.visitor = false
unit.flags2.resident = false
unit.flags2.calculated_nerves = false
unit.flags2.calculated_bodyparts = false
unit.invasion_id = -1
--It acts like these 2 don't exist....
--if unit.relationship_ids.group_leader then unit.relationship_ids.group_leader = -1 end
--if unit.relationship_ids.last_attacker then unit.relationship_ids.last_attacker = -1 end
unit.flags3.body_part_relsize_computed = false
unit.flags3.body_temp_in_range = true
unit.flags3.size_modifier_computed = false
unit.flags3.compute_health = true
unit.flags3.weight_computed = false
unit.counters.soldier_mood_countdown = -1
unit.counters.death_cause = -1
unit.animal.population.region_x = -1
unit.animal.population.region_y = -1
unit.animal.population.unk_28 = -1
unit.animal.population.population_idx = -1
unit.animal.population.depth = -1
unit.counters.soldier_mood_countdown = -1
unit.counters.death_cause = -1
-- weird, unknown territory
unit.enemy.anon_4 = -1
unit.enemy.anon_5 = -1
unit.enemy.anon_6 = -1
--unit.enemy.anon_7 = 0
--unit.status2.unk_7c0 = -1
--unit.enemy.unk_v40_2_count = 11
--unit.unk_100 = 3
end
and that got me past several more errors....
but I already see that the issue with ids earlier is coming back to bite... I've got it to a "friendly tame elephant in a cage...." as best I can describe it... It crashed on something in the merchant removal script... which will probably have to be trashed. I think all the errors are because its not switching the race for some reason I think its something to do with those ID difference or its not getting the caste call or race call correctly, currently its a succubus war elephant which doesn't make sense.....
I've got to get to RL for a bit, I'll look into it later.