Describe the bug
When isnpc($n) is used in a mprog, it is responding to a NPC as though it were a PC.
I noticed this because the following error came up:
//(world) Obj 21909, com 1, line 8: Mptransfer - No such person.
//(world) Obj 21909, com 1, line 10: Mpforce - No such victim.
the mprog used by obj 21909 is not supposed to do anything for a npc , only a pc.
To Reproduce
Steps to reproduce the behavior:
I added the follow with opedit to:
_Object: slot machine Vnum: 21913.
1>all_greetprog 100
if isnpc($n)
say isnpc thinks $n is a NPC
else
say isnpc thinks $n is a PC
endif
When a NPC walks into the room the following then occured:
a slot machine says 'isnpc thinks waitress is a PC'
Expected behavior
isnpc($n) should recognize that a NPC is a NPC and not a PC....
Additional context
I noticed this behaviour on both object progs and mob progs.
Describe the bug When isnpc($n) is used in a mprog, it is responding to a NPC as though it were a PC.
I noticed this because the following error came up: //(world) Obj 21909, com 1, line 8: Mptransfer - No such person. //(world) Obj 21909, com 1, line 10: Mpforce - No such victim.
To Reproduce Steps to reproduce the behavior: I added the follow with opedit to: _Object: slot machine Vnum: 21913.
1>all_greetprog 100 if isnpc($n) say isnpc thinks $n is a NPC else say isnpc thinks $n is a PC endif
When a NPC walks into the room the following then occured: a slot machine says 'isnpc thinks waitress is a PC'
Expected behavior isnpc($n) should recognize that a NPC is a NPC and not a PC....
Additional context I noticed this behaviour on both object progs and mob progs.