|
@@ -6412,7 +6412,10 @@ static unsigned short status_calc_str(struct block_list *bl, status_change *sc,
|
|
|
str += sc->getSCE(SC_ALMIGHTY)->val1;
|
|
|
if (sc->getSCE(SC_ULTIMATECOOK))
|
|
|
str += sc->getSCE(SC_ULTIMATECOOK)->val1;
|
|
|
+ if (sc->getSCE(SC_ALL_STAT_DOWN))
|
|
|
+ str -= sc->getSCE(SC_ALL_STAT_DOWN)->val2;
|
|
|
|
|
|
+ //TODO: Stat points should be able to be decreased below 0
|
|
|
return (unsigned short)cap_value(str,0,USHRT_MAX);
|
|
|
}
|
|
|
|
|
@@ -6496,7 +6499,10 @@ static unsigned short status_calc_agi(struct block_list *bl, status_change *sc,
|
|
|
agi += sc->getSCE(SC_ALMIGHTY)->val1;
|
|
|
if (sc->getSCE(SC_ULTIMATECOOK))
|
|
|
agi += sc->getSCE(SC_ULTIMATECOOK)->val1;
|
|
|
+ if (sc->getSCE(SC_ALL_STAT_DOWN))
|
|
|
+ agi -= sc->getSCE(SC_ALL_STAT_DOWN)->val2;
|
|
|
|
|
|
+ //TODO: Stat points should be able to be decreased below 0
|
|
|
return (unsigned short)cap_value(agi,0,USHRT_MAX);
|
|
|
}
|
|
|
|
|
@@ -6572,7 +6578,10 @@ static unsigned short status_calc_vit(struct block_list *bl, status_change *sc,
|
|
|
vit += sc->getSCE(SC_ULTIMATECOOK)->val1;
|
|
|
if (sc->getSCE(SC_CUP_OF_BOZA))
|
|
|
vit += 10;
|
|
|
+ if (sc->getSCE(SC_ALL_STAT_DOWN))
|
|
|
+ vit -= sc->getSCE(SC_ALL_STAT_DOWN)->val2;
|
|
|
|
|
|
+ //TODO: Stat points should be able to be decreased below 0
|
|
|
return (unsigned short)cap_value(vit,0,USHRT_MAX);
|
|
|
}
|
|
|
|
|
@@ -6661,7 +6670,10 @@ static unsigned short status_calc_int(struct block_list *bl, status_change *sc,
|
|
|
int_ += sc->getSCE(SC_ALMIGHTY)->val1;
|
|
|
if (sc->getSCE(SC_ULTIMATECOOK))
|
|
|
int_ += sc->getSCE(SC_ULTIMATECOOK)->val1;
|
|
|
+ if (sc->getSCE(SC_ALL_STAT_DOWN))
|
|
|
+ int_ -= sc->getSCE(SC_ALL_STAT_DOWN)->val2;
|
|
|
|
|
|
+ //TODO: Stat points should be able to be decreased below 0
|
|
|
return (unsigned short)cap_value(int_,0,USHRT_MAX);
|
|
|
}
|
|
|
|
|
@@ -6747,7 +6759,10 @@ static unsigned short status_calc_dex(struct block_list *bl, status_change *sc,
|
|
|
dex += sc->getSCE(SC_ALMIGHTY)->val1;
|
|
|
if (sc->getSCE(SC_ULTIMATECOOK))
|
|
|
dex += sc->getSCE(SC_ULTIMATECOOK)->val1;
|
|
|
+ if (sc->getSCE(SC_ALL_STAT_DOWN))
|
|
|
+ dex -= sc->getSCE(SC_ALL_STAT_DOWN)->val2;
|
|
|
|
|
|
+ //TODO: Stat points should be able to be decreased below 0
|
|
|
return (unsigned short)cap_value(dex,0,USHRT_MAX);
|
|
|
}
|
|
|
|
|
@@ -6821,7 +6836,10 @@ static unsigned short status_calc_luk(struct block_list *bl, status_change *sc,
|
|
|
luk += sc->getSCE(SC_ULTIMATECOOK)->val1;
|
|
|
if (sc->getSCE(SC_MYSTICPOWDER))
|
|
|
luk += 10;
|
|
|
+ if (sc->getSCE(SC_ALL_STAT_DOWN))
|
|
|
+ luk -= sc->getSCE(SC_ALL_STAT_DOWN)->val2;
|
|
|
|
|
|
+ //TODO: Stat points should be able to be decreased below 0
|
|
|
return (unsigned short)cap_value(luk,0,USHRT_MAX);
|
|
|
}
|
|
|
|
|
@@ -10895,6 +10913,12 @@ int status_change_start(struct block_list* src, struct block_list* bl,enum sc_ty
|
|
|
tick_time = status_get_sc_interval(type);
|
|
|
val4 = tick - tick_time; // Remaining time
|
|
|
break;
|
|
|
+ case SC_ALL_STAT_DOWN:
|
|
|
+ val2 = 20 * val1;
|
|
|
+ if( val1 < skill_get_max( NPC_ALL_STAT_DOWN ) ){
|
|
|
+ val2 -= 10;
|
|
|
+ }
|
|
|
+ break;
|
|
|
case SC_BOSSMAPINFO:
|
|
|
if( sd != NULL ) {
|
|
|
struct mob_data *boss_md = map_getmob_boss(bl->m); // Search for Boss on this Map
|