summaryrefslogtreecommitdiff
path: root/src/emap/npc.c
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-11-07 19:18:06 +0300
committerAndrei Karas <akaras@inbox.ru>2017-11-07 19:18:06 +0300
commit51e1c8fd61d0e8270c7502095c73cf58f8beac62 (patch)
tree5dd4ea8d0f7360660552fe42e49bfe3488fd0233 /src/emap/npc.c
parent1e553c3f7a8d444983ee25c0cefbcb4e00a54305 (diff)
downloadplugin-51e1c8fd61d0e8270c7502095c73cf58f8beac62.tar.gz
plugin-51e1c8fd61d0e8270c7502095c73cf58f8beac62.tar.bz2
plugin-51e1c8fd61d0e8270c7502095c73cf58f8beac62.tar.xz
plugin-51e1c8fd61d0e8270c7502095c73cf58f8beac62.zip
Update from new hercules.s20171129
Removed npc vd recreation because it already fixed in hercules.
Diffstat (limited to 'src/emap/npc.c')
-rw-r--r--src/emap/npc.c14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/emap/npc.c b/src/emap/npc.c
index 0639269..5dee49d 100644
--- a/src/emap/npc.c
+++ b/src/emap/npc.c
@@ -155,6 +155,8 @@ bool enpc_db_checkid_pre(const int *idPtr)
return true;
if (id >= MAX_NPC_CLASS2_START && id < MAX_NPC_CLASS2_END) // Second range
return true;
+ if (pc->db_checkid(id))
+ return true;
// Anything else is invalid
return false;
}
@@ -266,7 +268,6 @@ int enpc_unload_pre(struct npc_data** ndPtr,
{
struct npc_data *nd = *ndPtr;
nullpo_ret(nd);
- aFree(nd->vd);
if (nd->subtype == SCRIPT)
{
if (nd->src_id != 0)
@@ -295,14 +296,3 @@ int enpc_unload_pre(struct npc_data** ndPtr,
}
return 0;
}
-
-struct view_data *enpc_get_viewdata_post(struct view_data *retVal,
- int class_ __attribute__ ((unused)))
-{
- nullpo_retr(NULL, retVal);
-
- struct view_data *vd;
- CREATE(vd, struct view_data, 1);
- memcpy(vd, retVal, sizeof(struct view_data));
- return vd;
-}