Extend the item identification a bit to count unidentifiable items and handle icons, demihumans and monsters.

This commit is contained in:
Ottermandias 2022-06-01 18:04:11 +02:00
parent 1ad7787e4c
commit 06deddcd8a
7 changed files with 714 additions and 672 deletions

View file

@ -437,7 +437,11 @@ public partial class ModCollection
}
else if( !data.Item1.Contains( modPath.Mod ) )
{
_changedItems[ name ] = ( data.Item1.Append( modPath.Mod ), obj );
_changedItems[ name ] = ( data.Item1.Append( modPath.Mod ), obj is int x && data.Item2 is int y ? x + y : obj);
}
else if (obj is int x && data.Item2 is int y)
{
_changedItems[name] = (data.Item1, x + y);
}
}
}