Added renewal behavior to safety wall (exclusive to remode)
- Safety Wall now possesses a lifetime equal to 3 times the health of the caster, when the wall absorbs this much damage, the wall is removed and any remaining damage is dealt to the player. git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@15554 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
99917b3183
commit
4e118878dd
@ -386,10 +386,23 @@ int battle_calc_damage(struct block_list *src,struct block_list *bl,struct Damag
|
|||||||
{
|
{
|
||||||
struct skill_unit_group* group = skill_id2group(sc->data[SC_SAFETYWALL]->val3);
|
struct skill_unit_group* group = skill_id2group(sc->data[SC_SAFETYWALL]->val3);
|
||||||
if (group) {
|
if (group) {
|
||||||
|
/**
|
||||||
|
* in RE, SW possesses a lifetime equal to 3 times the caster's health
|
||||||
|
**/
|
||||||
|
#if REMODE
|
||||||
|
if ( ( group->val2 - damage) > 0 ) {
|
||||||
|
group->val2 -= damage;
|
||||||
|
d->dmg_lv = ATK_BLOCK;
|
||||||
|
return 0;
|
||||||
|
} else
|
||||||
|
damage -= group->val2;
|
||||||
|
skill_delunitgroup(group);
|
||||||
|
#else
|
||||||
if (--group->val2<=0)
|
if (--group->val2<=0)
|
||||||
skill_delunitgroup(group);
|
skill_delunitgroup(group);
|
||||||
d->dmg_lv = ATK_BLOCK;
|
d->dmg_lv = ATK_BLOCK;
|
||||||
return 0;
|
return 0;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
status_change_end(bl, SC_SAFETYWALL, INVALID_TIMER);
|
status_change_end(bl, SC_SAFETYWALL, INVALID_TIMER);
|
||||||
}
|
}
|
||||||
|
@ -8850,10 +8850,16 @@ struct skill_unit_group* skill_unitsetting (struct block_list *src, short skilli
|
|||||||
status = status_get_status_data(src);
|
status = status_get_status_data(src);
|
||||||
sc = status_get_sc(src); // for traps, firewall and fogwall - celest
|
sc = status_get_sc(src); // for traps, firewall and fogwall - celest
|
||||||
|
|
||||||
switch( skillid )
|
switch( skillid ) {
|
||||||
{
|
|
||||||
case MG_SAFETYWALL:
|
case MG_SAFETYWALL:
|
||||||
val2=skilllv+1;
|
#if REMODE
|
||||||
|
/**
|
||||||
|
* According to data provided in RE, SW life is equal to 3 times caster's health
|
||||||
|
**/
|
||||||
|
val2 = status_get_max_hp(src) * 3;
|
||||||
|
#else
|
||||||
|
val2 = skilllv+1;
|
||||||
|
#endif
|
||||||
break;
|
break;
|
||||||
case MG_FIREWALL:
|
case MG_FIREWALL:
|
||||||
if(sc && sc->data[SC_VIOLENTGALE])
|
if(sc && sc->data[SC_VIOLENTGALE])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user