Try / OpenGothic

Reimplementation of Gothic 2 Notr
MIT License
1.17k stars 85 forks source link

Npc runtime corner cases #656

Open Try opened 4 months ago

Try commented 4 months ago

As touched breathy in https://github.com/Try/OpenGothic/pull/653

Here current assumption, that true-guild must be in !isMonster() range to enable inventory.

thokkat commented 4 months ago

maybe it's related to npc having some builtin bones, such as ZS_SWORD/ZS_RIGHTHAND ?

Seems like the right idea. Npc_HasEquippedMeleeWeapon returns always true but weapon is only visible if ZS_SWORD is present like for skeletons or zombies. But the latter can't draw that weapon because animation is missing.

Goblin lacks ZS_SWORD like other monsters. In script Npc_SetToFightMode is used to fake 1h mode. Damage is purely determined by strength. Skeletons even have their strength reduced by weapon damage to behave the same.