OpenGothic
OpenGothic copied to clipboard
Rework `canSense` and `canSee` functions
I reworked some functions based on testing:
- active perceptions are only perceived if npc has
SENSE_SMELLorSENSE_SEEandcanSeereturns true,SENSE_HEARdoes nothing - passive perceptions only care for perc range and ignore senses and
canSee -
canSeeonly cares for senses range -
npc_getnexttargetdoesn't need line of sight.
This fixes Lares not stopping if guiding the player and shattered golem not attacking. To keep sneaking working while opening a chest walkbit is now used instead of bodystate for sneak mode testing.