diff options
author | Lupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2005-02-23 22:49:21 +0000 |
---|---|---|
committer | Lupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2005-02-23 22:49:21 +0000 |
commit | ad81f62be42d1f1e6ef14266d442603a68714c94 (patch) | |
tree | 7a735f6d862e73fab565c6f7468ff49f06391fe4 /src/map/pc.c | |
parent | 125ff2ca6b79b278576f7ddbbd6ac99526b7a852 (diff) | |
download | hercules-ad81f62be42d1f1e6ef14266d442603a68714c94.tar.gz hercules-ad81f62be42d1f1e6ef14266d442603a68714c94.tar.bz2 hercules-ad81f62be42d1f1e6ef14266d442603a68714c94.tar.xz hercules-ad81f62be42d1f1e6ef14266d442603a68714c94.zip |
mob db exp reading fix
mobs item drops rate fix
mob spawn once shows normal log
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/branches/stable@1170 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r-- | src/map/pc.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/map/pc.c b/src/map/pc.c index 20f5d8854..3110726d2 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -2768,7 +2768,7 @@ int pc_show_steal(struct block_list *bl,va_list ap) int pc_steal_item(struct map_session_data *sd,struct block_list *bl) { if(sd != NULL && bl != NULL && bl->type == BL_MOB) { - int i,skill,rate,itemid,flag, count; + int i,skill,itemid,flag, count; struct mob_data *md; md=(struct mob_data *)bl; if(!md->state.steal_flag && mob_db[md->class_].mexp <= 0 && !(mob_db[md->class_].mode&0x20) && @@ -2789,10 +2789,8 @@ int pc_steal_item(struct map_session_data *sd,struct block_list *bl) if(itemid > 0 && itemdb_type(itemid) != 6) { - rate = (mob_db[md->class_].dropitem[i].p / battle_config.item_rate_common * 100 * skill)/100; - rate += sd->add_steal_rate; - - if(rand()%10000 < rate) + //fixed rate. From Freya [Lupus] + if (rand() % 10000 < ((mob_db[md->class_].dropitem[i].p * skill) / 100 + sd->add_steal_rate)) { struct item tmp_item; memset(&tmp_item,0,sizeof(tmp_item)); |