summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
authorzephyrus <zephyrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-08-31 11:00:32 +0000
committerzephyrus <zephyrus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-08-31 11:00:32 +0000
commitf1f46c5b4ba04d590ff2ffbf28d84c3888ff3399 (patch)
treecf810be091ac06dbbc9dc2320d051051fec5a7f0 /src/map
parentb880ddcc752e3ceb0d79b80c24304ceef7339732 (diff)
downloadhercules-f1f46c5b4ba04d590ff2ffbf28d84c3888ff3399.tar.gz
hercules-f1f46c5b4ba04d590ff2ffbf28d84c3888ff3399.tar.bz2
hercules-f1f46c5b4ba04d590ff2ffbf28d84c3888ff3399.tar.xz
hercules-f1f46c5b4ba04d590ff2ffbf28d84c3888ff3399.zip
- Limitations to WoE SE Treasures (no steal, drop rates, no class change).
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@13156 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map')
-rw-r--r--src/map/mob.c12
-rw-r--r--src/map/pc.c9
2 files changed, 11 insertions, 10 deletions
diff --git a/src/map/mob.c b/src/map/mob.c
index 755063da8..141fc697b 100644
--- a/src/map/mob.c
+++ b/src/map/mob.c
@@ -2449,23 +2449,23 @@ int mob_class_change (struct mob_data *md, int class_)
nullpo_retr(0, md);
- if (md->bl.prev == NULL)
+ if( md->bl.prev == NULL )
return 0;
//Disable class changing for some targets...
if (md->guardian_data)
return 0; //Guardians/Emperium
- if (md->class_ >= 1324 && md->class_ <= 1363)
+ if( (md->class_ >= 1324 && md->class_ <= 1363) || (md->class_ >= 1938 && md->class_ <= 1946) )
return 0; //Treasure Boxes
- if (md->special_state.ai > 1)
+ if( md->special_state.ai > 1 )
return 0; //Marine Spheres and Floras.
- if (mob_is_clone(md->class_))
+ if( mob_is_clone(md->class_) )
return 0; //Clones
- if (md->class_ == class_)
+ if( md->class_ == class_ )
return 0; //Nothing to change.
hp_rate = get_percentage(md->status.hp, md->status.max_hp);
@@ -3445,7 +3445,7 @@ static bool mob_parse_dbrow(char** str)
}
type = itemdb_type(db->dropitem[i].nameid);
rate = atoi(str[k+1]);
- if (class_ >= 1324 && class_ <= 1363)
+ if( (class_ >= 1324 && class_ <= 1363) || (class_ >= 1938 && class_ <= 1946) )
{ //Treasure box drop rates [Skotlex]
rate_adjust = battle_config.item_rate_treasure;
ratemin = battle_config.item_drop_treasure_min;
diff --git a/src/map/pc.c b/src/map/pc.c
index fe49e1473..0c8af18d3 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -3388,8 +3388,9 @@ int pc_steal_item(struct map_session_data *sd,struct block_list *bl, int lv)
sd_status= status_get_status_data(&sd->bl);
md_status= status_get_status_data(bl);
- if(md->master_id || md_status->mode&MD_BOSS ||
- (md->class_>=1324 && md->class_<1364) || // prevent stealing from treasure boxes [Valaris]
+ if( md->master_id || md_status->mode&MD_BOSS ||
+ (md->class_ >= 1324 && md->class_ < 1364) || // Treasure Boxes WoE
+ (md->class_ >= 1938 && md->class_ < 1946) || // Treasure Boxes WoE SE
map[bl->m].flag.nomobloot || // check noloot map flag [Lorky]
(battle_config.skill_steal_max_tries && //Reached limit of steal attempts. [Lupus]
md->state.steal_flag++ >= battle_config.skill_steal_max_tries)
@@ -3460,10 +3461,10 @@ int pc_steal_coin(struct map_session_data *sd,struct block_list *target)
return 0;
md = (TBL_MOB*)target;
- if(md->state.steal_coin_flag || md->sc.data[SC_STONE] || md->sc.data[SC_FREEZE])
+ if( md->state.steal_coin_flag || md->sc.data[SC_STONE] || md->sc.data[SC_FREEZE] )
return 0;
- if (md->class_>=1324 && md->class_<1364)
+ if( (md->class_ >= 1324 && md->class_ < 1364) || (md->class_ >= 1938 && md->class_ < 1946) )
return 0;
skill = pc_checkskill(sd,RG_STEALCOIN)*10;