summaryrefslogtreecommitdiff
path: root/src/map/npc.c
diff options
context:
space:
mode:
authorcelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-22 16:31:56 +0000
committercelest <celest@54d463be-8e91-2dee-dedb-b68131a5f0ec>2005-03-22 16:31:56 +0000
commitb5735b90f5ec847a89acd80509e8ba2ce23a3905 (patch)
treec784ba41982fe5370eee9245d9fe65063b389328 /src/map/npc.c
parente52e5e17df12881d87065106a96ed48a9d302555 (diff)
downloadhercules-b5735b90f5ec847a89acd80509e8ba2ce23a3905.tar.gz
hercules-b5735b90f5ec847a89acd80509e8ba2ce23a3905.tar.bz2
hercules-b5735b90f5ec847a89acd80509e8ba2ce23a3905.tar.xz
hercules-b5735b90f5ec847a89acd80509e8ba2ce23a3905.zip
Check changelog ^^
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1267 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/npc.c')
-rw-r--r--src/map/npc.c19
1 files changed, 8 insertions, 11 deletions
diff --git a/src/map/npc.c b/src/map/npc.c
index 018ceae01..eb3f33ac5 100644
--- a/src/map/npc.c
+++ b/src/map/npc.c
@@ -1106,7 +1106,7 @@ int npc_buylist(struct map_session_data *sd,int n,unsigned short *item_list)
if (sd->status.skill[MC_DISCOUNT].flag != 0)
skill = sd->status.skill[MC_DISCOUNT].flag - 2;
if (skill > 0) {
- z = z * (double)skill * (double)battle_config.shop_exp/100.;
+ z = z * (double)skill * (double)battle_config.shop_exp/10000.;
if (z < 1)
z = 1;
pc_gainexp(sd,0,(int)z);
@@ -1166,7 +1166,7 @@ int npc_selllist(struct map_session_data *sd,int n,unsigned short *item_list)
if (sd->status.skill[MC_OVERCHARGE].flag != 0)
skill = sd->status.skill[MC_OVERCHARGE].flag - 2;
if (skill > 0) {
- z = z * (double)skill * (double)battle_config.shop_exp/100.;
+ z = z * (double)skill * (double)battle_config.shop_exp/10000.;
if (z < 1)
z = 1;
pc_gainexp(sd,0,(int)z);
@@ -2094,16 +2094,13 @@ int npc_parse_mob(char *w1,char *w2,char *w3,char *w4)
md->bl.x=x;
md->bl.y=y;
- if(sscanf(w3,"%[^,],%d",mobname,&level) > 1) {
- if(strcmp(mobname,"--en--")==0)
- memcpy(md->name,mob_db[class_].name,24);
- else if(strcmp(mobname,"--ja--")==0)
- memcpy(md->name,mob_db[class_].jname,24);
+ if(sscanf(w3,"%[^,],%d",mobname,&level) > 1)
md->level=level;
- }
-
- else
- memcpy(md->name,w3,24);
+ if(strcmp(mobname,"--en--")==0)
+ memcpy(md->name,mob_db[class_].name,24);
+ else if(strcmp(mobname,"--ja--")==0)
+ memcpy(md->name,mob_db[class_].jname,24);
+ else memcpy(md->name,mobname,24);
md->n = i;
md->base_class = md->class_ = class_;