summaryrefslogtreecommitdiff
path: root/src/map/npc.c
diff options
context:
space:
mode:
authorLance <Lance@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-04-01 09:37:50 +0000
committerLance <Lance@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-04-01 09:37:50 +0000
commit74a30ea8d414cec9fba211298c72b2a686b0582a (patch)
treec8c111060aad9e80949fd07d77104c1c6747a299 /src/map/npc.c
parenta41884fbb032359e4f0bfcdaee50acb749ed8862 (diff)
downloadhercules-74a30ea8d414cec9fba211298c72b2a686b0582a.tar.gz
hercules-74a30ea8d414cec9fba211298c72b2a686b0582a.tar.bz2
hercules-74a30ea8d414cec9fba211298c72b2a686b0582a.tar.xz
hercules-74a30ea8d414cec9fba211298c72b2a686b0582a.zip
Fixed the dynamic shop system memory allocation and id_db problem. Added sample script.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5842 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/npc.c')
-rw-r--r--src/map/npc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/map/npc.c b/src/map/npc.c
index d1a35ff61..eaed2bdee 100644
--- a/src/map/npc.c
+++ b/src/map/npc.c
@@ -2766,14 +2766,14 @@ int do_init_npc(void)
return 0;
}
// [Lance]
- int npc_changename(const char *name, const char *newname, short look){
+int npc_changename(const char *name, const char *newname, short look){
struct npc_data *nd= (struct npc_data *) strdb_remove(npcname_db,(unsigned char*)name);
if (nd==NULL)
return 0;
npc_enable(name,0);
strcpy(nd->name,newname);
nd->class_ = look;
- strdb_put(npcname_db,nd->name,nd);
npc_enable(newname,1);
return 0;
}
+