-Fix bugreport:7298 where exp affected by level_penalty wasn't affecting self but next party member as well.
-Follow up r17161 (fix windows undefined type, bugreport:7305 git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@17162 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
9d93ffa2d0
commit
a79985a0c8
@ -910,6 +910,7 @@ int party_exp_share(struct party_data* p, struct block_list* src, unsigned int b
|
||||
{
|
||||
struct map_session_data* sd[MAX_PARTY];
|
||||
unsigned int i, c;
|
||||
uint32 base_exp_bonus, job_exp_bonus;
|
||||
|
||||
nullpo_ret(p);
|
||||
|
||||
@ -937,12 +938,15 @@ int party_exp_share(struct party_data* p, struct block_list* src, unsigned int b
|
||||
zeny = (unsigned int) cap_value(zeny * bonus/100, INT_MIN, INT_MAX);
|
||||
}
|
||||
|
||||
base_exp_bonus = base_exp;
|
||||
job_exp_bonus = job_exp;
|
||||
|
||||
for (i = 0; i < c; i++) {
|
||||
#ifdef RENEWAL_EXP
|
||||
if( !(src && src->type == BL_MOB && ((TBL_MOB*)src)->db->mexp) ){
|
||||
int rate = pc_level_penalty_mod(sd[i], (TBL_MOB*)src, 1);
|
||||
base_exp = (unsigned int)cap_value(base_exp * rate / 100, 1, UINT_MAX);
|
||||
job_exp = (unsigned int)cap_value(job_exp * rate / 100, 1, UINT_MAX);
|
||||
base_exp = (unsigned int)cap_value(base_exp_bonus * rate / 100, 1, UINT_MAX);
|
||||
job_exp = (unsigned int)cap_value(job_exp_bonus * rate / 100, 1, UINT_MAX);
|
||||
}
|
||||
#endif
|
||||
pc_gainexp(sd[i], src, base_exp, job_exp, false);
|
||||
|
@ -3707,7 +3707,7 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl, uint
|
||||
short x, y, i = 2; // Move 2 cells for Issen(from target)
|
||||
struct block_list *mbl = bl;
|
||||
short dir = 0;
|
||||
|
||||
|
||||
skill_attack(BF_WEAPON,src,src,bl,skill_id,skill_lv,tick,flag);
|
||||
|
||||
if( skill_id == MO_EXTREMITYFIST )
|
||||
@ -3721,14 +3721,14 @@ int skill_castend_damage_id (struct block_list* src, struct block_list *bl, uint
|
||||
sc_start(src,SC_EXTREMITYFIST2,100,skill_lv,skill_get_time(skill_id,skill_lv));
|
||||
#endif
|
||||
}else
|
||||
status_set_hp(src,
|
||||
status_set_hp(src,
|
||||
#ifdef RENEWAL
|
||||
max(status_get_max_hp(src)/100, 1)
|
||||
#else
|
||||
1
|
||||
#endif
|
||||
, 0);
|
||||
|
||||
|
||||
dir = map_calc_dir(src,bl->x,bl->y);
|
||||
if( dir > 0 && dir < 4) x = -i;
|
||||
else if( dir > 4 ) x = i;
|
||||
@ -7863,8 +7863,8 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, ui
|
||||
skill_blockpc_start(sd,skill_id,4000);
|
||||
|
||||
if( !(tsc && tsc->data[type]) ){
|
||||
i = sc_start2(bl,type,rate,skill_lv,src->id,(src == bl)?5000:(bl->type == BL_PC)?skill_get_time(skill_id,skill_lv):skill_get_time2(skill_id, skill_lv));
|
||||
clif_skill_nodamage(src,bl,skill_id,skill_lv,i);
|
||||
i = sc_start2(bl,type,rate,skill_lv,src->id,(src == bl)?5000:(bl->type == BL_PC)?skill_get_time(skill_id,skill_lv):skill_get_time2(skill_id, skill_lv));
|
||||
clif_skill_nodamage(src,bl,skill_id,skill_lv,i);
|
||||
if( !i )
|
||||
clif_skill_fail(sd,skill_id,USESKILL_FAIL_LEVEL,0);
|
||||
}
|
||||
@ -12439,7 +12439,7 @@ int skill_check_condition_castbegin(struct map_session_data* sd, uint16 skill_id
|
||||
struct status_change *sc;
|
||||
struct skill_condition require;
|
||||
int i;
|
||||
uint inf2;
|
||||
uint32 inf2;
|
||||
|
||||
nullpo_ret(sd);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user