diff options
author | Jedzkie <jedzkie13@rocketmail.com> | 2015-12-13 22:44:51 +0800 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2015-12-13 16:17:19 +0100 |
commit | 6476db2cd11bab086c903297f4efcb5ec0a1962f (patch) | |
tree | 091ec3b8b8823dbd442a2a308ebefb733ad6b7c3 /src | |
parent | 3b1df6196b38c95140e43bd462888d3d570821a3 (diff) | |
download | hercules-6476db2cd11bab086c903297f4efcb5ec0a1962f.tar.gz hercules-6476db2cd11bab086c903297f4efcb5ec0a1962f.tar.bz2 hercules-6476db2cd11bab086c903297f4efcb5ec0a1962f.tar.xz hercules-6476db2cd11bab086c903297f4efcb5ec0a1962f.zip |
Fix SC_STOMACHACHE to its official behavior.
Diffstat (limited to 'src')
-rw-r--r-- | src/map/status.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/map/status.c b/src/map/status.c index da2892f98..951615fb2 100644 --- a/src/map/status.c +++ b/src/map/status.c @@ -5416,7 +5416,7 @@ unsigned short status_calc_speed(struct block_list *bl, struct status_change *sc if( sc->data[SC_MELON_BOMB] ) val = max( val, sc->data[SC_MELON_BOMB]->val1 ); if (sc->data[SC_STOMACHACHE]) - val = max(val, 50); + val = max(val, sc->data[SC_STOMACHACHE]->val2); if( sc->data[SC_MARSHOFABYSS] ) // It stacks to other statuses so always put this at the end. val = max( 50, val + 10 * sc->data[SC_MARSHOFABYSS]->val1 ); @@ -9089,7 +9089,7 @@ int status_change_start(struct block_list *src, struct block_list *bl, enum sc_t val1 = 15; break; case SC_STOMACHACHE: - val2 = 8; // SP consume. + val3 = 8; // SP consume. val4 = tick / 10000; tick_time = 10000; // [GodLesZ] tick time break; @@ -11429,10 +11429,10 @@ int status_change_timer(int tid, int64 tick, int id, intptr_t data) { break; case SC_STOMACHACHE: - if( --(sce->val4) > 0 ) { - status->charge(bl,0,sce->val2); // Reduce 8 every 10 seconds. - if( sd && !pc_issit(sd) ) { // Force to sit every 10 seconds. - pc_stop_walking(sd, STOPWALKING_FLAG_FIXPOS|STOPWALKING_FLAG_NEXTCELL); + if (--(sce->val4) > 0) { + status->charge(bl, 0, sce->val3); // Reduce 8 every 10 seconds. + if (sd && !pc_issit(sd)) { // Force to sit every 10 seconds. + pc_stop_walking(sd, STOPWALKING_FLAG_FIXPOS | STOPWALKING_FLAG_NEXTCELL); pc_stop_attack(sd); pc_setsit(sd); clif->sitting(bl); |