DFHack / dfhack

Memory hacking library for Dwarf Fortress and a set of tools that use it
Other
1.86k stars 468 forks source link

zone enumerates nicknames on assign #1709

Closed ajs closed 3 years ago

ajs commented 3 years ago

As you can see here:

image

the zone command set nicknames for all of my animals that are numbers. Here is what I did:

Select the first zone with "i" and then, in the console:

[DFHack]# zone set
Target building type: pen/pasture or pit.
Current building set to #10471
[DFHack]# zone assign all own not egglayer not grazer not race DOG not race CAT tame
No building id specified. Will use #10471
Process all units.
Filter: 'own civilization'
Filter: 'not egglayer'
Filter: 'not grazer'
Filter: 'not race of DOG'
Filter: 'not race of CAT'
Filter: 'tame'
Default filter for assign: 'not merchant'; use 'merchant' filter to override.
Matched creatures: 25
Processed creatures: 25

Then repeat this for the other two pens with:

[DFHack]# zone assign all own egglayer not grazer not race DOG not race CAT tame
...
Matched creatures: 13
Processed creatures: 13

and

[DFHack]# zone assign all own not egglayer grazer not race DOG not race CAT tame
...
Matched creatures: 49
Processed creatures: 49

Seems like it should have worked, but all of my creatures are where they started (not the pens I assigned them to) and are now nicknamed with integers.

ajs commented 3 years ago

Also note that I brought this up on reddit but have not yet gotten any feedback there.

I'm running LNP on Windows: PeridexisErrant's Starter Pack 0.47.04-r10

lethosor commented 3 years ago

What version of DFHack are you using? Looks like that pack has 0.47.04-r3 - for future reference, that's a bit more relevant on our end.

lethosor commented 3 years ago

Ah, I think I found an issue with #1652 that would cause this. Working on a fix.

lethosor commented 3 years ago

Thanks for the report! Turned out to be a simple fix. It'll be in 0.47.04-r4. If you want a fixed plugin that works with r3, you can get it from https://buildmaster.lubar.me/executions/execution-in-progress?executionId=598020 when it's done (or the latest automated build from https://dfhack.org/builds/ if that link doesn't work by the time you see it). In your case, you would want to download "Windows64.zip", then extract zone.plug.dll from it and overwrite the existing file of the same name in hack/plugins with the new one.

ajs commented 3 years ago

Wow, thanks @lethosor that was amazingly fast!