diff options
author | Haru <haru@dotalux.com> | 2019-11-17 17:43:09 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-11-17 17:43:09 +0100 |
commit | f91cbd5d1f9fc8492d64be8ef402b89e405c807c (patch) | |
tree | 1621775ac912b6f49a6d07184883803453246af6 /src/map/status.c | |
parent | 608603ac66cc0acc8eb016e0a26675e0d067fcbe (diff) | |
parent | 3489894765b41f9b802187efc1c566c225aa74b8 (diff) | |
download | hercules-f91cbd5d1f9fc8492d64be8ef402b89e405c807c.tar.gz hercules-f91cbd5d1f9fc8492d64be8ef402b89e405c807c.tar.bz2 hercules-f91cbd5d1f9fc8492d64be8ef402b89e405c807c.tar.xz hercules-f91cbd5d1f9fc8492d64be8ef402b89e405c807c.zip |
Merge pull request #2570 from Asheraf/scconfnoboss
Dehardcode status effect boss resistance
Diffstat (limited to 'src/map/status.c')
-rw-r--r-- | src/map/status.c | 52 |
1 files changed, 4 insertions, 48 deletions
diff --git a/src/map/status.c b/src/map/status.c index d2c67b84e..c513c0a9a 100644 --- a/src/map/status.c +++ b/src/map/status.c @@ -10581,55 +10581,10 @@ static bool status_is_boss_resist_sc(enum sc_type type) { if (type >= SC_COMMON_MIN && type <= SC_COMMON_MAX) return true; - switch (type) { - case SC_BLESSING: - case SC_DEC_AGI: - case SC_PROVOKE: - case SC_COMA: - case SC_GRAVITATION: - case SC_NJ_SUITON: - case SC_RICHMANKIM: - case SC_ROKISWEIL: - case SC_FOGWALL: - case SC_FROSTMISTY: - case SC_BURNING: - case SC_MARSHOFABYSS: - case SC_ADORAMUS: - case SC_NEEDLE_OF_PARALYZE: - case SC_DEEP_SLEEP: - case SC_COLD: - - // Exploit prevention - kRO Fix - case SC_PYREXIA: - case SC_DEATHHURT: - case SC_TOXIN: - case SC_PARALYSE: - case SC_VENOMBLEED: - case SC_MAGICMUSHROOM: - case SC_OBLIVIONCURSE: - case SC_LEECHESEND: - - // Ranger Effects - case SC_WUGBITE: - case SC_ELECTRICSHOCKER: - case SC_MAGNETICFIELD: - // Masquerades - case SC__ENERVATION: - case SC__GROOMY: - case SC__LAZINESS: - case SC__UNLUCKY: - case SC__WEAKNESS: - case SC__IGNORANCE: + if (status->get_sc_type(type) & SC_NO_BOSS) + return true; - // Other Effects - case SC_VACUUM_EXTREME: - case SC_NETHERWORLD: - case SC_FRESHSHRIMP: - case SC_SV_ROOTTWIST: - case SC_BITESCAR: - return true; - } return false; } @@ -13498,7 +13453,8 @@ static bool status_read_scdb_libconfig_sub_flag(struct config_setting_t *it, int { "Buff", SC_BUFF }, { "Debuff", SC_DEBUFF }, { "NoMadoReset", SC_MADO_NO_RESET }, - { "NoAllReset", SC_NO_CLEAR } + { "NoAllReset", SC_NO_CLEAR }, + { "NoBoss", SC_NO_BOSS }, }; ARR_FIND(0, ARRAYLENGTH(flags), j, strcmpi(flag, flags[j].name) == 0); |