|
@@ -2459,35 +2459,33 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type)
|
|
|
drop_rate = 1;
|
|
|
}
|
|
|
|
|
|
- if (!(md->status.mode&MD_FIXED_ITEMDROP)) {
|
|
|
- // change drops depending on monsters size [Valaris]
|
|
|
- if (battle_config.mob_size_influence) {
|
|
|
- if (md->special_state.size == SZ_MEDIUM && drop_rate >= 2)
|
|
|
- drop_rate /= 2;
|
|
|
- else if( md->special_state.size == SZ_BIG)
|
|
|
- drop_rate *= 2;
|
|
|
- }
|
|
|
+ // change drops depending on monsters size [Valaris]
|
|
|
+ if (battle_config.mob_size_influence) {
|
|
|
+ if (md->special_state.size == SZ_MEDIUM && drop_rate >= 2)
|
|
|
+ drop_rate /= 2;
|
|
|
+ else if( md->special_state.size == SZ_BIG)
|
|
|
+ drop_rate *= 2;
|
|
|
+ }
|
|
|
|
|
|
- if (src) {
|
|
|
- //Drops affected by luk as a fixed increase [Valaris]
|
|
|
- if (battle_config.drops_by_luk)
|
|
|
- drop_rate += status_get_luk(src)*battle_config.drops_by_luk/100;
|
|
|
- //Drops affected by luk as a % increase [Skotlex]
|
|
|
- if (battle_config.drops_by_luk2)
|
|
|
- drop_rate += (int)(0.5+drop_rate*status_get_luk(src)*battle_config.drops_by_luk2/10000.);
|
|
|
- }
|
|
|
- if (sd && battle_config.pk_mode &&
|
|
|
- (int)(md->level - sd->status.base_level) >= 20)
|
|
|
- drop_rate = (int)(drop_rate*1.25); // pk_mode increase drops if 20 level difference [Valaris]
|
|
|
-
|
|
|
- // Increase drop rate if user has SC_ITEMBOOST
|
|
|
- if (sd && sd->sc.data[SC_ITEMBOOST]) // now rig the drop rate to never be over 90% unless it is originally >90%.
|
|
|
- drop_rate = max(drop_rate,cap_value((int)(0.5+drop_rate*(sd->sc.data[SC_ITEMBOOST]->val1)/100.),0,9000));
|
|
|
- // Increase item drop rate for VIP.
|
|
|
- if (battle_config.vip_drop_increase && (sd && pc_isvip(sd))) {
|
|
|
- drop_rate += (int)(0.5 + (drop_rate * battle_config.vip_drop_increase) / 100);
|
|
|
- drop_rate = min(drop_rate,10000); //cap it to 100%
|
|
|
- }
|
|
|
+ if (src) {
|
|
|
+ //Drops affected by luk as a fixed increase [Valaris]
|
|
|
+ if (battle_config.drops_by_luk)
|
|
|
+ drop_rate += status_get_luk(src)*battle_config.drops_by_luk/100;
|
|
|
+ //Drops affected by luk as a % increase [Skotlex]
|
|
|
+ if (battle_config.drops_by_luk2)
|
|
|
+ drop_rate += (int)(0.5+drop_rate*status_get_luk(src)*battle_config.drops_by_luk2/10000.);
|
|
|
+ }
|
|
|
+ if (sd && battle_config.pk_mode &&
|
|
|
+ (int)(md->level - sd->status.base_level) >= 20)
|
|
|
+ drop_rate = (int)(drop_rate*1.25); // pk_mode increase drops if 20 level difference [Valaris]
|
|
|
+
|
|
|
+ // Increase drop rate if user has SC_ITEMBOOST
|
|
|
+ if (sd && sd->sc.data[SC_ITEMBOOST]) // now rig the drop rate to never be over 90% unless it is originally >90%.
|
|
|
+ drop_rate = max(drop_rate,cap_value((int)(0.5+drop_rate*(sd->sc.data[SC_ITEMBOOST]->val1)/100.),0,9000));
|
|
|
+ // Increase item drop rate for VIP.
|
|
|
+ if (battle_config.vip_drop_increase && (sd && pc_isvip(sd))) {
|
|
|
+ drop_rate += (int)(0.5 + (drop_rate * battle_config.vip_drop_increase) / 100);
|
|
|
+ drop_rate = min(drop_rate,10000); //cap it to 100%
|
|
|
}
|
|
|
#ifdef RENEWAL_DROP
|
|
|
if( drop_modifier != 100 ) {
|