- Spring cleaning of various source files

- Removed unused src/map/config/Skills/Mage_Classes.h file

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@15837 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
epoque11 2012-04-09 22:56:59 +00:00
parent fb6262a990
commit 34e7f045b7
22 changed files with 239 additions and 276 deletions

View File

@ -41,7 +41,7 @@ MAP_H = map.h chrif.h clif.h pc.h status.h npc.h \
log.h mail.h date.h unit.h homunculus.h mercenary.h quest.h instance.h mapreg.h \ log.h mail.h date.h unit.h homunculus.h mercenary.h quest.h instance.h mapreg.h \
buyingstore.h searchstore.h duel.h pc_groups.h \ buyingstore.h searchstore.h duel.h pc_groups.h \
config/Core.h config/Renewal.h config/Secure.h config/Data/Const.h \ config/Core.h config/Renewal.h config/Secure.h config/Data/Const.h \
config/Skills/General.h config/Skills/Mage_Classes.h config/Skills/Swordsman_Classes.h config/Skills/General.h config/Skills/Swordsman_Classes.h
HAVE_MYSQL=@HAVE_MYSQL@ HAVE_MYSQL=@HAVE_MYSQL@
ifeq ($(HAVE_MYSQL),yes) ifeq ($(HAVE_MYSQL),yes)

View File

@ -389,7 +389,7 @@ int battle_calc_damage(struct block_list *src,struct block_list *bl,struct Damag
/** /**
* in RE, SW possesses a lifetime equal to 3 times the caster's health * in RE, SW possesses a lifetime equal to 3 times the caster's health
**/ **/
#if REMODE #ifdef RENEWAL
if ( ( group->val2 - damage) > 0 ) { if ( ( group->val2 - damage) > 0 ) {
group->val2 -= damage; group->val2 -= damage;
d->dmg_lv = ATK_BLOCK; d->dmg_lv = ATK_BLOCK;
@ -593,7 +593,7 @@ int battle_calc_damage(struct block_list *src,struct block_list *bl,struct Damag
/** /**
* In renewal steel body reduces all incoming damage by 1/10 * In renewal steel body reduces all incoming damage by 1/10
**/ **/
#if REMODE #ifdef RENEWAL
if( sc->data[SC_STEELBODY] ) { if( sc->data[SC_STEELBODY] ) {
damage = damage > 10 ? damage / 10 : 1; damage = damage > 10 ? damage / 10 : 1;
} }
@ -820,7 +820,7 @@ int battle_calc_gvg_damage(struct block_list *src,struct block_list *bl,int dama
if(class_ == MOBID_EMPERIUM && flag&BF_SKILL) { if(class_ == MOBID_EMPERIUM && flag&BF_SKILL) {
//Skill immunity. //Skill immunity.
switch (skill_num) { switch (skill_num) {
#if isOFF(REMODE) #ifndef RENEWAL
case MO_TRIPLEATTACK: case MO_TRIPLEATTACK:
#endif #endif
case HW_GRAVITATION: case HW_GRAVITATION:
@ -925,7 +925,7 @@ int battle_addmastery(struct map_session_data *sd,struct block_list *target,int
switch(weapon) switch(weapon)
{ {
case W_1HSWORD: case W_1HSWORD:
#if REMODE #ifdef RENEWAL
if((skill = pc_checkskill(sd,AM_AXEMASTERY)) > 0) if((skill = pc_checkskill(sd,AM_AXEMASTERY)) > 0)
damage += (skill * 3); damage += (skill * 3);
#endif #endif
@ -934,7 +934,7 @@ int battle_addmastery(struct map_session_data *sd,struct block_list *target,int
damage += (skill * 4); damage += (skill * 4);
break; break;
case W_2HSWORD: case W_2HSWORD:
#if REMODE #ifdef RENEWAL
if((skill = pc_checkskill(sd,AM_AXEMASTERY)) > 0) if((skill = pc_checkskill(sd,AM_AXEMASTERY)) > 0)
damage += (skill * 3); damage += (skill * 3);
#endif #endif
@ -1241,7 +1241,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo
//Since these do not consume ammo, they need to be explicitly set as arrow attacks. //Since these do not consume ammo, they need to be explicitly set as arrow attacks.
flag.arrow = 1; flag.arrow = 1;
break; break;
#if isOFF(REMODE) #ifndef RENEWAL
case PA_SHIELDCHAIN: case PA_SHIELDCHAIN:
case CR_SHIELDBOOMERANG: case CR_SHIELDBOOMERANG:
#endif #endif
@ -1423,7 +1423,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo
{ //Hit/Flee calculation { //Hit/Flee calculation
short short
flee = tstatus->flee, flee = tstatus->flee,
#if REMODE #ifdef RENEWAL
hitrate = 0; //Default hitrate hitrate = 0; //Default hitrate
#else #else
hitrate = 80; //Default hitrate hitrate = 80; //Default hitrate
@ -1661,7 +1661,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo
break; break;
case AC_SHOWER: case AC_SHOWER:
case MA_SHOWER: case MA_SHOWER:
#if REMODE #ifdef RENEWAL
skillratio += 50+10*skill_lv; skillratio += 50+10*skill_lv;
#else #else
skillratio += -25+5*skill_lv; skillratio += -25+5*skill_lv;
@ -1768,7 +1768,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo
case CR_HOLYCROSS: case CR_HOLYCROSS:
{ {
int ratio = 35*skill_lv; int ratio = 35*skill_lv;
#if REMODE #ifdef RENEWAL
if(sd && sd->status.weapon == W_2HSPEAR) if(sd && sd->status.weapon == W_2HSPEAR)
ratio *= 2; ratio *= 2;
#endif #endif
@ -2290,17 +2290,15 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo
if (sc) { if (sc) {
if(sc->data[SC_TRUESIGHT]) if(sc->data[SC_TRUESIGHT])
ATK_ADDRATE(2*sc->data[SC_TRUESIGHT]->val1); ATK_ADDRATE(2*sc->data[SC_TRUESIGHT]->val1);
#if RE_EDP == 0 #ifndef RENEWAL_EDP
/** // renewal EDP doesn't affect your final damage but your atk and weapon atk
* In RE EDP doesn't affect your final damage but your atk and weapon atk
**/
if(sc->data[SC_EDP] && if(sc->data[SC_EDP] &&
skill_num != ASC_BREAKER && skill_num != ASC_BREAKER &&
skill_num != ASC_METEORASSAULT && skill_num != ASC_METEORASSAULT &&
skill_num != AS_SPLASHER && skill_num != AS_SPLASHER &&
skill_num != AS_VENOMKNIFE) skill_num != AS_VENOMKNIFE)
ATK_ADDRATE(sc->data[SC_EDP]->val3); ATK_ADDRATE(sc->data[SC_EDP]->val3);
#endif #endif
} }
switch (skill_num) { switch (skill_num) {
@ -2436,7 +2434,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo
vit_def += def1*battle_config.weapon_defense_type; vit_def += def1*battle_config.weapon_defense_type;
def1 = 0; def1 = 0;
} }
#if REMODE #ifdef RENEWAL
/** /**
* In Renewal 100% damage reduction is 900 DEF * In Renewal 100% damage reduction is 900 DEF
* Formula: (1+(900-def1)/9)% * Formula: (1+(900-def1)/9)%
@ -2546,7 +2544,7 @@ static struct Damage battle_calc_weapon_attack(struct block_list *src,struct blo
wd.damage2 += battle_attr_fix(src, target, damage, sc->data[SC_WATK_ELEMENT]->val1, tstatus->def_ele, tstatus->ele_lv); wd.damage2 += battle_attr_fix(src, target, damage, sc->data[SC_WATK_ELEMENT]->val1, tstatus->def_ele, tstatus->ele_lv);
} }
} }
#if REMODE #ifdef RENEWAL
/** /**
* In RE Shield Bommerang takes weapon element only for damage calculation, * In RE Shield Bommerang takes weapon element only for damage calculation,
* - resist calculation is always against neutral * - resist calculation is always against neutral
@ -3036,7 +3034,7 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list
break; break;
default: default:
{ {
#if REMODE //Renewal MATK Appliance according to doddler (?title=Renewal_Changes#Upgrade_MATK) #ifdef RENEWAL //Renewal MATK Appliance according to doddler (?title=Renewal_Changes#Upgrade_MATK)
/** /**
* min: (weaponMATK+upgradeMATK) * 2 + 1.5 * statusMATK * min: (weaponMATK+upgradeMATK) * 2 + 1.5 * statusMATK
* max: [weaponMATK+upgradeMATK+(wMatk*wLvl)/10] * 2 + 1.5 * statusMATK * max: [weaponMATK+upgradeMATK+(wMatk*wLvl)/10] * 2 + 1.5 * statusMATK
@ -3074,7 +3072,7 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list
/** /**
* in Renewal Thunder Storm boost is 100% (in pre-re, 80%) * in Renewal Thunder Storm boost is 100% (in pre-re, 80%)
**/ **/
#if isOFF(REMODE) #ifndef RENEWAL
case MG_THUNDERSTORM: case MG_THUNDERSTORM:
skillratio -= 20; skillratio -= 20;
break; break;
@ -3138,7 +3136,7 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list
case NJ_RAIGEKISAI: case NJ_RAIGEKISAI:
skillratio += 60 + 40*skill_lv; skillratio += 60 + 40*skill_lv;
break; break;
#if REMODE #ifdef RENEWAL
case NJ_HUUJIN: case NJ_HUUJIN:
skillratio += 50; skillratio += 50;
break; break;
@ -3374,7 +3372,7 @@ struct Damage battle_calc_magic_attack(struct block_list *src,struct block_list
//mdef2-= mdef2* i/100; //mdef2-= mdef2* i/100;
} }
} }
#if REMODE #ifdef RENEWAL
/** /**
* RE MDEF Reduction (from doddler:?title=Renewal_Changes#MDEF) * RE MDEF Reduction (from doddler:?title=Renewal_Changes#MDEF)
* Damage from magic = Magic Attack * 111.5/(111.5+eMDEF) * Damage from magic = Magic Attack * 111.5/(111.5+eMDEF)
@ -3548,7 +3546,7 @@ struct Damage battle_calc_misc_attack(struct block_list *src,struct block_list *
switch( skill_num ) switch( skill_num )
{ {
#if REMODE #ifdef RENEWAL
case HT_LANDMINE: case HT_LANDMINE:
case MA_LANDMINE: case MA_LANDMINE:
case HT_BLASTMINE: case HT_BLASTMINE:
@ -3698,7 +3696,7 @@ struct Damage battle_calc_misc_attack(struct block_list *src,struct block_list *
else { else {
short short
flee = tstatus->flee, flee = tstatus->flee,
#if REMODE #ifdef RENEWAL
hitrate = 0; //Default hitrate hitrate = 0; //Default hitrate
#else #else
hitrate = 80; //Default hitrate hitrate = 80; //Default hitrate

View File

@ -1,5 +1,8 @@
#ifndef _RRCONFIGS_ // Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
#define _RRCONFIGS_ // For more information, see LICENCE in the main folder
#ifndef _CONFIG_CORE_H_
#define _CONFIG_CORE_H_
/** /**
* rAthena configuration file (http://rathena.org) * rAthena configuration file (http://rathena.org)
* For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/ * For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/
@ -32,7 +35,5 @@
* Constants come last; so they process anything that could've been modified in early includes * Constants come last; so they process anything that could've been modified in early includes
**/ **/
#include "./Data/Const.h" #include "./Data/Const.h"
/**
* End of File #endif // _CONFIG_CORE_H_
**/
#endif

View File

@ -1,5 +1,8 @@
// Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
// For more information, see LICENCE in the main folder
#ifndef _RRCONFIGS_CONST_ #ifndef _RRCONFIGS_CONST_
#define _RRCONFIGS_CONST_ #define _RRCONFIGS_CONST_
/** /**
* rAthena configuration file (http://rathena.org) * rAthena configuration file (http://rathena.org)
* For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/ * For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/
@ -12,13 +15,13 @@
/** /**
* "Constants" * "Constants"
**/ **/
#if RECASTING #ifdef RENEWAL_CAST
#if REMODE == 0 #ifndef RENEWAL
#error RECASTING requires REMODE enabled #error RENEWAL_CAST requires RENEWAL enabled
#endif #endif
#define CONST_CASTRATE_SCALE RECASTING_VMIN #define CONST_CASTRATE_SCALE RENEWAL_CAST_VMIN
/** /**
* Cast Rate Formula: (DEX x 2)+INT * Cast Rate Formula: (DEX x 2)+INT
**/ **/
@ -31,8 +34,6 @@
#define CONST_CASTRATE_CALC (status_get_dex(bl)) #define CONST_CASTRATE_CALC (status_get_dex(bl))
#endif #endif
#define isOFF(def) (def == 0)
/** /**
* "Sane Checks" to save you from compiling with cool bugs * "Sane Checks" to save you from compiling with cool bugs
**/ **/
@ -46,7 +47,7 @@
/** /**
* Path within the /db folder to (non-)renewal specific db files * Path within the /db folder to (non-)renewal specific db files
**/ **/
#if REMODE #ifdef RENEWAL
#define DBPATH "re/" #define DBPATH "re/"
#else #else
#define DBPATH "pre-re/" #define DBPATH "pre-re/"
@ -55,7 +56,7 @@
/** /**
* DefType * DefType
**/ **/
#if REMODE #ifdef RENEWAL
typedef short defType; typedef short defType;
#define DEFTYPE_MIN SHRT_MIN #define DEFTYPE_MIN SHRT_MIN
#define DEFTYPE_MAX SHRT_MAX #define DEFTYPE_MAX SHRT_MAX

View File

@ -1,5 +1,8 @@
#ifndef _RRCONFIGS_RE_ // Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
#define _RRCONFIGS_RE_ // For more information, see LICENCE in the main folder
#ifndef _CONFIG_RENEWAL_H_
#define _CONFIG_RENEWAL_H_
/** /**
* rAthena configuration file (http://rathena.org) * rAthena configuration file (http://rathena.org)
* For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/ * For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/
@ -9,51 +12,44 @@
* @INFO: This file holds general-purpose renewal settings, for class-specific ones check /src/map/config/Skills folder * @INFO: This file holds general-purpose renewal settings, for class-specific ones check /src/map/config/Skills folder
**/ **/
/** /// game renewal server mode
* Game Server Mode /// (disable by commenting the line)
* @values: 1 or 0 ///
* 1 : renewal support, such as renewal-exclusive formulas /// leave this line to enable renewal specific support such as renewal formulas
* -> Note some features may be enabled/disabled at this file despite this setting being ON #define RENEWAL
* 0 : renewal support disabled, use original formulas
**/
#define REMODE 1
/** /// renewal cast time
* Renewal Cast Time /// (disable by commenting the line)
* @values: 1 (enabled) or 0 (disabled) ///
* 1 : Cast Time is decreased by DEX*2+INT, 20% of the cast time is not reduced by stats, /// leave this line to enable renewal casting time algorithms
* - for example, on a skill whose cast time is 10s, only 8s may be reduced. other 2s are /// cast time is decreased by DEX * 2 + INT while 20% of the cast time is not reduced by stats.
* - part of a "fixed cast time" that is only reduced by special items and skills (such as /// example:
* - Arch Bishop's Sacrament skill). /// on a skill whos cast time is 10s, only 8s may be reduced. the other 2s are part of a
* 0 : the old cast time method, influenced by dex, items and skills. /// "fixed cast time" which can only be reduced by specialist items and skills
**/ #define RENEWAL_CAST
#define RECASTING 1
/** /// renewal drop rate algorithms
* Renewal Drop Rate Modifier /// (disable by commenting the line)
* @values: 1 (enabled) or 0 (disabled) ///
* - When enabled a modifier based on difference between the player and the monster level is applied, /// leave this line to enable renewal item drop rate algorithms
* - based on the http://irowiki.org/wiki/Drop_System#Level_Factor table /// while enabled a special modified based on the difference between the player and monster level is applied
**/ /// based on the http://irowiki.org/wiki/Drop_System#Level_Factor table
#define RE_DROP_MOD 1 #define RENEWAL_DROP
/** /// renewal cast time variable cast requirement
* Renewal Cast Time : Variable-Free ///
* - Value required for no variable cast time with stats. /// this is the value required for no variable cast-time with stats.
* - Formula: (casterDex x 2) + (casterInt) /// formula: (DEX * 2) + INT
* Default: 530 /// default: 530
**/ #define RENEWAL_CAST_VMIN 530
#define RECASTING_VMIN 530
/** /// renewal enchant deadly poison algorithm
* Renewal Enchant Deadly Poison Change ///
* - In RE EDP no longer increases final damage by 400%. /// leave this line to enable the renewed EDP algorithm
* - it increases your weapon atk and your stat atk /// under renewal mode:
* - it doesn't affect grimtooth /// - damage is NOT increased by 400%
**/ /// - it does NOT affect grimtooth
#define RE_EDP 1 /// - weapon and status ATK are increased
#define RENEWAL_EDP
/** #endif // _CONFIG_RENEWAL_H_
* End of File
**/
#endif

View File

@ -1,5 +1,8 @@
#ifndef _RRCONFIGS_SECURE_ // Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
#define _RRCONFIGS_SECURE_ // For more information, see LICENCE in the main folder
#ifndef _CONFIG_SECURE_H_
#define _CONFIG_SECURE_H_
/** /**
* rAthena configuration file (http://rathena.org) * rAthena configuration file (http://rathena.org)
* For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/ * For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/
@ -27,8 +30,4 @@
**/ **/
#define SECURE_NPCTIMEOUT_INTERVAL 1 #define SECURE_NPCTIMEOUT_INTERVAL 1
#endif // _CONFIG_SECURE_H_
/**
* End of File
**/
#endif

View File

@ -1,5 +1,8 @@
#ifndef _RRCONFIGS_SKILLS_GENERAL_ // Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
#define _RRCONFIGS_SKILLS_GENERAL_ // For more information, see LICENCE in the main folder
#ifndef _CONFIG_GENERAL_H_
#define _CONFIG_GENERAL_H_
/** /**
* rAthena configuration file (http://rathena.org) * rAthena configuration file (http://rathena.org)
* For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/ * For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/
@ -18,4 +21,5 @@
**/ **/
#include "Mage_Classes.h" #include "Mage_Classes.h"
#include "Swordsman_Classes.h" #include "Swordsman_Classes.h"
#endif
#endif // _CONFIG_GENERAL_H_

View File

@ -1,11 +0,0 @@
#ifndef _RRCONFIGS_SKILLS_MAGE_
#define _RRCONFIGS_SKILLS_MAGE_
/**
* rAthena configuration file (http://rathena.org)
* For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/
**/
/**
* No settings past this point
**/
#endif

View File

@ -1,17 +1,16 @@
#ifndef _RRCONFIGS_SKILLS_SWORDS_ // Copyright (c) rAthena Dev Teams - Licensed under GNU GPL
#define _RRCONFIGS_SKILLS_SWORDS_ // For more information, see LICENCE in the main folder
#ifndef _CONFIG_SKILLS_SWORDS_H_
#define _CONFIG_SKILLS_SWORDS_H_
/** /**
* rAthena configuration file (http://rathena.org) * rAthena configuration file (http://rathena.org)
* For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/ * For detailed guidance on these check http://rathena.org/wiki/SRC/map/config/
**/ **/
/** /// rune knight
* (Rune Knight) the maximum rune items a character may have of the same type ///
* Default: 20 /// maximum number of runes that a rune knight character can carry at any given time
**/ /// default: 20
#define MAX_RUNE 20 #define MAX_RUNE 20
/** #endif // _CONFIG_SKILLS_SWORDS_H_
* No settings past this point
**/
#endif

View File

@ -799,7 +799,7 @@ static bool itemdb_parse_dbrow(char** str, const char* source, int line, int scr
id->value_buy, id->value_sell, nameid, id->jname); id->value_buy, id->value_sell, nameid, id->jname);
id->weight = atoi(str[6]); id->weight = atoi(str[6]);
#if REMODE #ifdef RENEWAL
itemdb_re_split_atoi(str[7],&id->atk,&id->matk); itemdb_re_split_atoi(str[7],&id->atk,&id->matk);
#else #else
id->atk = atoi(str[7]); id->atk = atoi(str[7]);
@ -985,7 +985,7 @@ static int itemdb_readdb(void)
*======================================*/ *======================================*/
static int itemdb_read_sqldb(void) static int itemdb_read_sqldb(void)
{ {
#if REMODE #ifdef RENEWAL
const char* item_db_name[] = { item_db_db, item_db_re_db, item_db2_db }; const char* item_db_name[] = { item_db_db, item_db_re_db, item_db2_db };
#else #else
const char* item_db_name[] = { item_db_db, item_db2_db }; const char* item_db_name[] = { item_db_db, item_db2_db };

View File

@ -106,7 +106,7 @@ struct item_data {
int elv; int elv;
int wlv; int wlv;
int view_id; int view_id;
#if REMODE #ifdef RENEWAL
int matk;//[RRInd] -- used in RE for matk int matk;//[RRInd] -- used in RE for matk
#endif #endif

View File

@ -3833,7 +3833,7 @@ int do_init(int argc, char *argv[])
} }
map_config_read(MAP_CONF_NAME); map_config_read(MAP_CONF_NAME);
#if REMODE #ifdef RENEWAL
/** /**
* to make pre-re conflict safe * to make pre-re conflict safe
**/ **/

View File

@ -2188,7 +2188,7 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type)
if(base_exp || job_exp) if(base_exp || job_exp)
{ {
if( md->dmglog[i].flag != MDLF_PET || battle_config.pet_attack_exp_to_master ) { if( md->dmglog[i].flag != MDLF_PET || battle_config.pet_attack_exp_to_master ) {
#if REMODE #ifdef RENEWAL
if(!md->db->mexp) if(!md->db->mexp)
party_renewal_exp_mod(&base_exp,&job_exp,tmpsd[i]->status.base_level,md->level); party_renewal_exp_mod(&base_exp,&job_exp,tmpsd[i]->status.base_level,md->level);
#endif #endif
@ -2215,7 +2215,7 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type)
struct item_drop *ditem; struct item_drop *ditem;
struct item_data* it = NULL; struct item_data* it = NULL;
int drop_rate; int drop_rate;
#if RE_DROP_MOD #ifdef RENEWAL_DROP
int drop_modifier = mvp_sd ? party_renewal_drop_mod(mvp_sd->status.base_level - md->level) : int drop_modifier = mvp_sd ? party_renewal_drop_mod(mvp_sd->status.base_level - md->level) :
second_sd ? party_renewal_drop_mod(second_sd->status.base_level - md->level) : second_sd ? party_renewal_drop_mod(second_sd->status.base_level - md->level) :
third_sd ? party_renewal_drop_mod(third_sd->status.base_level - md->level) : 100; third_sd ? party_renewal_drop_mod(third_sd->status.base_level - md->level) : 100;
@ -2261,7 +2261,7 @@ int mob_dead(struct mob_data *md, struct block_list *src, int type)
// Increase drop rate if user has SC_ITEMBOOST // Increase drop rate if user has SC_ITEMBOOST
if (sd && sd->sc.data[SC_ITEMBOOST]) // now rig the drop rate to never be over 90% unless it is originally >90%. if (sd && sd->sc.data[SC_ITEMBOOST]) // now rig the drop rate to never be over 90% unless it is originally >90%.
drop_rate = max(drop_rate,cap_value((int)(0.5+drop_rate*(sd->sc.data[SC_ITEMBOOST]->val1)/100.),0,9000)); drop_rate = max(drop_rate,cap_value((int)(0.5+drop_rate*(sd->sc.data[SC_ITEMBOOST]->val1)/100.),0,9000));
#if RE_DROP_MOD #ifdef RENEWAL_DROP
if(drop_modifier != 100 && !md->db->mexp) if(drop_modifier != 100 && !md->db->mexp)
drop_rate = drop_rate * drop_modifier / 100; drop_rate = drop_rate * drop_modifier / 100;
#endif #endif

View File

@ -904,7 +904,7 @@ int party_send_xy_clear(struct party_data *p)
} }
return 0; return 0;
} }
#if RE_DROP_MOD #ifdef RENEWAL_DROP
/** /**
* Renewal Drop Modifier * Renewal Drop Modifier
**/ **/
@ -926,7 +926,7 @@ int party_renewal_drop_mod(int diff) {
return 50; return 50;
} }
#endif #endif
#if REMODE #ifdef RENEWAL
/** /**
* Renewal Experience Earning Mode * Renewal Experience Earning Mode
**/ **/
@ -961,7 +961,7 @@ int party_exp_share(struct party_data* p, struct block_list* src, unsigned int b
{ {
struct map_session_data* sd[MAX_PARTY]; struct map_session_data* sd[MAX_PARTY];
unsigned int i, c; unsigned int i, c;
#if REMODE #ifdef RENEWAL
int src_lvl = status_get_lv(src); int src_lvl = status_get_lv(src);
#endif #endif
nullpo_ret(p); nullpo_ret(p);
@ -991,7 +991,7 @@ int party_exp_share(struct party_data* p, struct block_list* src, unsigned int b
} }
for (i = 0; i < c; i++) { for (i = 0; i < c; i++) {
#if REMODE #ifdef RENEWAL
party_renewal_exp_mod(&base_exp,&job_exp,sd[i]->status.base_level,src_lvl); party_renewal_exp_mod(&base_exp,&job_exp,sd[i]->status.base_level,src_lvl);
#endif #endif
pc_gainexp(sd[i], src, base_exp, job_exp, false); pc_gainexp(sd[i], src, base_exp, job_exp, false);

View File

@ -92,10 +92,10 @@ void party_booking_update(struct map_session_data *sd, short* job);
void party_booking_search(struct map_session_data *sd, short level, short mapid, short job, unsigned long lastindex, short resultcount); void party_booking_search(struct map_session_data *sd, short level, short mapid, short job, unsigned long lastindex, short resultcount);
bool party_booking_delete(struct map_session_data *sd); bool party_booking_delete(struct map_session_data *sd);
#if REMODE #ifdef RENEWAL
void party_renewal_exp_mod(unsigned int *base_exp, unsigned int *job_exp, int lvl, int moblvl); void party_renewal_exp_mod(unsigned int *base_exp, unsigned int *job_exp, int lvl, int moblvl);
#endif #endif
#if RE_DROP_MOD #ifdef RENEWAL_DROP
int party_renewal_drop_mod(int diff); int party_renewal_drop_mod(int diff);
#endif #endif

View File

@ -2047,11 +2047,11 @@ int pc_bonus(struct map_session_data *sd,int type,int val)
case SP_DEF1: case SP_DEF1:
if(sd->state.lr_flag != 2) { if(sd->state.lr_flag != 2) {
bonus = status->def + val; bonus = status->def + val;
#if REMODE #ifdef RENEWAL
status->def = cap_value(bonus, SHRT_MIN, SHRT_MAX); status->def = cap_value(bonus, SHRT_MIN, SHRT_MAX);
#else #else
status->def = cap_value(bonus, CHAR_MIN, CHAR_MAX); status->def = cap_value(bonus, CHAR_MIN, CHAR_MAX);
#endif #endif
} }
break; break;
case SP_DEF2: case SP_DEF2:
@ -2063,11 +2063,11 @@ int pc_bonus(struct map_session_data *sd,int type,int val)
case SP_MDEF1: case SP_MDEF1:
if(sd->state.lr_flag != 2) { if(sd->state.lr_flag != 2) {
bonus = status->mdef + val; bonus = status->mdef + val;
#if REMODE #ifdef RENEWAL
status->mdef = cap_value(bonus, SHRT_MIN, SHRT_MAX); status->mdef = cap_value(bonus, SHRT_MIN, SHRT_MAX);
#else #else
status->mdef = cap_value(bonus, CHAR_MIN, CHAR_MAX); status->mdef = cap_value(bonus, CHAR_MIN, CHAR_MAX);
#endif #endif
if( sd->state.lr_flag == 3 ) {//Shield, used for royal guard if( sd->state.lr_flag == 3 ) {//Shield, used for royal guard
sd->shieldmdef += bonus; sd->shieldmdef += bonus;
} }
@ -5487,7 +5487,7 @@ int pc_need_status_point(struct map_session_data* sd, int type, int val)
swap(low, high); swap(low, high);
for ( ; low < high; low++ ) for ( ; low < high; low++ )
#if REMODE //Renewal Stat Cost Formula #ifdef RENEWAL // renewal status point cost formula
sp += (low < 100) ? (2 + (low - 1) / 10) : (16 + 4 * ((low - 100) / 5)); sp += (low < 100) ? (2 + (low - 1) / 10) : (16 + 4 * ((low - 100) / 5));
#else #else
sp += ( 1 + (low + 9) / 10 ); sp += ( 1 + (low + 9) / 10 );

View File

@ -653,7 +653,7 @@ enum e_pc_permission {
) )
// clientside atk display macros (values to the left/right of the "+") // clientside atk display macros (values to the left/right of the "+")
#if REMODE #ifdef RENEWAL
#define pc_leftside_atk(sd) ((sd)->battle_status.batk) #define pc_leftside_atk(sd) ((sd)->battle_status.batk)
#define pc_rightside_atk(sd) ((sd)->battle_status.rhw.atk + (sd)->battle_status.lhw.atk + (sd)->battle_status.rhw.atk2 + (sd)->battle_status.lhw.atk2) #define pc_rightside_atk(sd) ((sd)->battle_status.rhw.atk + (sd)->battle_status.lhw.atk + (sd)->battle_status.rhw.atk2 + (sd)->battle_status.lhw.atk2)
#else #else

View File

@ -44,7 +44,7 @@ struct pet_bonus {
unsigned short type; //bStr, bVit? unsigned short type; //bStr, bVit?
unsigned short val; //Qty unsigned short val; //Qty
unsigned short duration; //in secs unsigned short duration; //in secs
unsigned short delay; //Time before recasting (secs) unsigned short delay; //Time before RENEWAL_CAST (secs)
int timer; int timer;
}; };

View File

@ -217,7 +217,7 @@ int skill_get_unit_bl_target( int id ) { skill_get (skill_db[id].unit_target&
int skill_get_unit_flag( int id ) { skill_get (skill_db[id].unit_flag, id, 1); } int skill_get_unit_flag( int id ) { skill_get (skill_db[id].unit_flag, id, 1); }
int skill_get_unit_layout_type( int id ,int lv ){ skill_get (skill_db[id].unit_layout_type[lv-1], id, lv); } int skill_get_unit_layout_type( int id ,int lv ){ skill_get (skill_db[id].unit_layout_type[lv-1], id, lv); }
int skill_get_cooldown( int id ,int lv ) { skill_get (skill_db[id].cooldown[lv-1], id, lv); } int skill_get_cooldown( int id ,int lv ) { skill_get (skill_db[id].cooldown[lv-1], id, lv); }
#if RECASTING #ifdef RENEWAL_CAST
int skill_get_fixed_cast( int id ,int lv ){ skill_get (skill_db[id].fixed_cast[lv-1], id, lv); } int skill_get_fixed_cast( int id ,int lv ){ skill_get (skill_db[id].fixed_cast[lv-1], id, lv); }
#endif #endif
int skill_tree_get_max(int id, int b_class) int skill_tree_get_max(int id, int b_class)
@ -377,7 +377,7 @@ int skill_calc_heal(struct block_list *src, struct block_list *target, int skill
default: default:
if (skill_lv >= battle_config.max_heal_lv) if (skill_lv >= battle_config.max_heal_lv)
return battle_config.max_heal; return battle_config.max_heal;
#if REMODE #ifdef RENEWAL
/** /**
* Renewal Heal Formula (from Doddler) * Renewal Heal Formula (from Doddler)
* TODO: whats that( 1+ %Modifier / 100 ) ? currently using 'x1' (100/100) until found out * TODO: whats that( 1+ %Modifier / 100 ) ? currently using 'x1' (100/100) until found out
@ -839,7 +839,7 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int
/** /**
* Storm Gust counter was dropped in renewal * Storm Gust counter was dropped in renewal
**/ **/
#if REMODE #ifdef RENEWAL
sc_start(bl,SC_FREEZE,65-(5*skilllv),skilllv,skill_get_time2(skillid,skilllv)); sc_start(bl,SC_FREEZE,65-(5*skilllv),skilllv,skill_get_time2(skillid,skilllv));
#else #else
//Tharis pointed out that this is normal freeze chance with a base of 300% //Tharis pointed out that this is normal freeze chance with a base of 300%
@ -6451,7 +6451,7 @@ int skill_castend_nodamage_id (struct block_list *src, struct block_list *bl, in
/** /**
* Renewal dropped the 3/4 hp requirement * Renewal dropped the 3/4 hp requirement
**/ **/
#if isOFF(REMODE) #ifndef RENEWAL
|| tstatus-> hp > tstatus->max_hp*3/4 || tstatus-> hp > tstatus->max_hp*3/4
#endif #endif
) { ) {
@ -9442,7 +9442,7 @@ struct skill_unit_group* skill_unitsetting (struct block_list *src, short skilli
switch( skillid ) { switch( skillid ) {
case MG_SAFETYWALL: case MG_SAFETYWALL:
#if REMODE #ifdef RENEWAL
/** /**
* According to data provided in RE, SW life is equal to 3 times caster's health * According to data provided in RE, SW life is equal to 3 times caster's health
**/ **/
@ -10111,7 +10111,7 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
{ {
int heal = skill_calc_heal(ss,bl,sg->skill_id,sg->skill_lv,true); int heal = skill_calc_heal(ss,bl,sg->skill_id,sg->skill_lv,true);
struct mob_data *md = BL_CAST(BL_MOB, bl); struct mob_data *md = BL_CAST(BL_MOB, bl);
#if REMODE #ifdef RENEWAL
if( md && md->class_ == MOBID_EMPERIUM ) if( md && md->class_ == MOBID_EMPERIUM )
break; break;
#endif #endif
@ -10186,7 +10186,7 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
/** /**
* The storm gust counter was dropped in renewal * The storm gust counter was dropped in renewal
**/ **/
#if isOFF(REMODE) #ifndef RENEWAL
case WZ_STORMGUST: //SG counter does not reset per stormgust. IE: One hit from a SG and two hits from another will freeze you. case WZ_STORMGUST: //SG counter does not reset per stormgust. IE: One hit from a SG and two hits from another will freeze you.
if (tsc) if (tsc)
tsc->sg_counter++; //SG hit counter. tsc->sg_counter++; //SG hit counter.
@ -10306,7 +10306,7 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns
case UNT_APPLEIDUN: //Apple of Idun [Skotlex] case UNT_APPLEIDUN: //Apple of Idun [Skotlex]
{ {
int heal; int heal;
#if REMODE #ifdef RENEWAL
struct mob_data *md = BL_CAST(BL_MOB, bl); struct mob_data *md = BL_CAST(BL_MOB, bl);
if( md && md->class_ == MOBID_EMPERIUM ) if( md && md->class_ == MOBID_EMPERIUM )
break; break;
@ -12141,7 +12141,7 @@ int skill_castfix (struct block_list *bl, int skill_id, int skill_lv)
*------------------------------------------*/ *------------------------------------------*/
int skill_castfix_sc (struct block_list *bl, int time, int skill_id, int skill_lv) { int skill_castfix_sc (struct block_list *bl, int time, int skill_id, int skill_lv) {
struct status_change *sc = status_get_sc(bl); struct status_change *sc = status_get_sc(bl);
#if RECASTING #ifdef RENEWAL_CAST
int fixed = skill_get_fixed_cast(skill_id, skill_lv); int fixed = skill_get_fixed_cast(skill_id, skill_lv);
if( !fixed ) { if( !fixed ) {
fixed = skill_get_cast(skill_id, skill_lv); fixed = skill_get_cast(skill_id, skill_lv);
@ -12162,7 +12162,7 @@ int skill_castfix_sc (struct block_list *bl, int time, int skill_id, int skill_l
} }
if (sc->data[SC_POEMBRAGI]) if (sc->data[SC_POEMBRAGI])
time -= time * sc->data[SC_POEMBRAGI]->val2 / 100; time -= time * sc->data[SC_POEMBRAGI]->val2 / 100;
#if RECASTING #ifdef RENEWAL_CAST
if( sc->data[SC__LAZINESS] ) if( sc->data[SC__LAZINESS] )
fixed += fixed * sc->data[SC__LAZINESS]->val2 / 100; fixed += fixed * sc->data[SC__LAZINESS]->val2 / 100;
/** /**
@ -12172,7 +12172,7 @@ int skill_castfix_sc (struct block_list *bl, int time, int skill_id, int skill_l
fixed -= fixed * sc->data[SC_SECRAMENT]->val2 / 100; fixed -= fixed * sc->data[SC_SECRAMENT]->val2 / 100;
#endif #endif
} }
#if RECASTING #ifdef RENEWAL_CAST
/** /**
* WL_RADIUS decreases 10/15/20% fixed cast time from warlock skills * WL_RADIUS decreases 10/15/20% fixed cast time from warlock skills
**/ **/
@ -15558,7 +15558,7 @@ static bool skill_parse_row_castdb(char* split[], int columns, int current)
skill_split_atoi(split[4],skill_db[i].upkeep_time); skill_split_atoi(split[4],skill_db[i].upkeep_time);
skill_split_atoi(split[5],skill_db[i].upkeep_time2); skill_split_atoi(split[5],skill_db[i].upkeep_time2);
skill_split_atoi(split[6],skill_db[i].cooldown); skill_split_atoi(split[6],skill_db[i].cooldown);
#if RECASTING #ifdef RENEWAL_CAST
skill_split_atoi(split[7],skill_db[i].fixed_cast); skill_split_atoi(split[7],skill_db[i].fixed_cast);
#endif #endif
return true; return true;

View File

@ -94,7 +94,7 @@ struct s_skill_db {
int range[MAX_SKILL_LEVEL],hit,inf,element[MAX_SKILL_LEVEL],nk,splash[MAX_SKILL_LEVEL],max; int range[MAX_SKILL_LEVEL],hit,inf,element[MAX_SKILL_LEVEL],nk,splash[MAX_SKILL_LEVEL],max;
int num[MAX_SKILL_LEVEL]; int num[MAX_SKILL_LEVEL];
int cast[MAX_SKILL_LEVEL],walkdelay[MAX_SKILL_LEVEL],delay[MAX_SKILL_LEVEL]; int cast[MAX_SKILL_LEVEL],walkdelay[MAX_SKILL_LEVEL],delay[MAX_SKILL_LEVEL];
#if RECASTING #ifdef RENEWAL_CAST
int fixed_cast[MAX_SKILL_LEVEL]; int fixed_cast[MAX_SKILL_LEVEL];
#endif #endif
int upkeep_time[MAX_SKILL_LEVEL],upkeep_time2[MAX_SKILL_LEVEL],cooldown[MAX_SKILL_LEVEL]; int upkeep_time[MAX_SKILL_LEVEL],upkeep_time2[MAX_SKILL_LEVEL],cooldown[MAX_SKILL_LEVEL];

View File

@ -63,7 +63,7 @@ static struct {
static int atkmods[3][MAX_WEAPON_TYPE]; // •<>ŠíATKƒTƒCƒY<C692>C<EFBFBD>³(size_fix.txt) static int atkmods[3][MAX_WEAPON_TYPE]; // •<>ŠíATKƒTƒCƒY<C692>C<EFBFBD>³(size_fix.txt)
static char job_bonus[CLASS_COUNT][MAX_LEVEL]; static char job_bonus[CLASS_COUNT][MAX_LEVEL];
#if REMODE #ifdef RENEWAL
enum { enum {
SHIELD_ASPD, SHIELD_ASPD,
RE_JOB_DB_MAX, RE_JOB_DB_MAX,
@ -883,10 +883,8 @@ void initChangeTables(void)
StatusChangeFlagTable[SC_DROCERA_HERB_STEAMED] |= SCB_AGI; StatusChangeFlagTable[SC_DROCERA_HERB_STEAMED] |= SCB_AGI;
StatusChangeFlagTable[SC_PUTTI_TAILS_NOODLES] |= SCB_LUK; StatusChangeFlagTable[SC_PUTTI_TAILS_NOODLES] |= SCB_LUK;
#if RE_EDP #ifdef RENEWAL_EDP
/** // renewal EDP increases your atk and weapon atk
* In RE EDP increases your atk and weapon atk
**/
StatusChangeFlagTable[SC_EDP] |= SCB_BATK|SCB_WATK; StatusChangeFlagTable[SC_EDP] |= SCB_BATK|SCB_WATK;
#endif #endif
if( !battle_config.display_hallucination ) //Disable Hallucination. if( !battle_config.display_hallucination ) //Disable Hallucination.
@ -1645,26 +1643,26 @@ int status_base_amotion_pc(struct map_session_data* sd, struct status_data* stat
// raw delay adjustment from bAspd bonus // raw delay adjustment from bAspd bonus
amotion+= sd->aspd_add; amotion+= sd->aspd_add;
#if REMODE
/** #ifdef RENEWAL
* Bearing a shield decreases your ASPD by a fixed value depending on your class
**/
if( sd->status.shield ) if( sd->status.shield )
{// bearing a shield decreases your ASPD by a fixed value depending on your class
amotion += re_job_db[pc_class2idx(sd->status.class_)][SHIELD_ASPD]; amotion += re_job_db[pc_class2idx(sd->status.class_)][SHIELD_ASPD];
/** }
* RE Absolute aspd modifiers
**/ if( sd->sc.count )
if( sd->sc.count ) { {// renewal absolute ASPD modifiers
int i; int i;
if ( sd->sc.data[i=SC_ASPDPOTION3] || if ( sd->sc.data[i=SC_ASPDPOTION3] ||
sd->sc.data[i=SC_ASPDPOTION2] || sd->sc.data[i=SC_ASPDPOTION2] ||
sd->sc.data[i=SC_ASPDPOTION1] || sd->sc.data[i=SC_ASPDPOTION1] ||
sd->sc.data[i=SC_ASPDPOTION0] ) sd->sc.data[i=SC_ASPDPOTION0] )
amotion -= sd->sc.data[i]->val1*10; amotion -= sd->sc.data[i]->val1*10;
if( sd->sc.data[SC_SPEARQUICKEN] ) if( sd->sc.data[SC_SPEARQUICKEN] )
amotion -= 70; amotion -= 70;
} }
#endif #endif
return amotion; return amotion;
} }
@ -1707,24 +1705,24 @@ static unsigned short status_base_atk(const struct block_list *bl, const struct
static inline unsigned short status_base_matk_max(const struct status_data* status) static inline unsigned short status_base_matk_max(const struct status_data* status)
{ {
#if REMODE #ifdef RENEWAL
return status->matk_max;//In RE maximum MATK signs weapon matk, which we store in this var return status->matk_max; // in RE maximum MATK signs weapon matk, which we store in this var
#else //Original Max MATK Formula #else
return status->int_+(status->int_/5)*(status->int_/5); return status->int_+(status->int_/5)*(status->int_/5);
#endif #endif
} }
#if REMODE #ifdef RENEWAL
static inline unsigned short status_base_matk_min(const struct status_data* status, int lvl) static inline unsigned short status_base_matk_min(const struct status_data* status, int lvl)
#else #else
static inline unsigned short status_base_matk_min(const struct status_data* status) static inline unsigned short status_base_matk_min(const struct status_data* status)
#endif #endif
{ {
#if REMODE //Renewal MATK Formula #ifdef RENEWAL
return status->int_+(status->int_/2)+(status->dex/5)+(status->luk/3)+(lvl/4); return status->int_+(status->int_/2)+(status->dex/5)+(status->luk/3)+(lvl/4);
#else //Original Min MATK Formula #else
return status->int_+(status->int_/7)*(status->int_/7); return status->int_+(status->int_/7)*(status->int_/7);
#endif #endif
} }
@ -1737,19 +1735,19 @@ void status_calc_misc(struct block_list *bl, struct status_data *status, int lev
status->hit = status->flee = status->hit = status->flee =
status->def2 = status->mdef2 = status->def2 = status->mdef2 =
status->cri = status->flee2 = 0; status->cri = status->flee2 = 0;
#if REMODE #ifdef RENEWAL
status->matk_min = status_base_matk_min(status, level); status->matk_min = status_base_matk_min(status, level);
#else #else
status->matk_min = status_base_matk_min(status); status->matk_min = status_base_matk_min(status);
#endif #endif
status->matk_max = status_base_matk_max(status); status->matk_max = status_base_matk_max(status);
#if REMODE //Renewal Formulas #ifdef RENEWAL // renewal formulas
status->hit += level + status->dex + status->luk/3 + 175; //base level + ( every 1 dex = +1 hit ) + (every 3 luk = +1 hit) + 175 status->hit += level + status->dex + status->luk/3 + 175; //base level + ( every 1 dex = +1 hit ) + (every 3 luk = +1 hit) + 175
status->flee += level + status->agi + status->luk/5 + 100; //base level + ( every 1 agi = +1 flee ) + (every 5 luk = +1 flee) + 100 status->flee += level + status->agi + status->luk/5 + 100; //base level + ( every 1 agi = +1 flee ) + (every 5 luk = +1 flee) + 100
status->def2 += (int)(((float)level + status->vit)/2 + ((float)status->agi/5)); //base level + (every 2 agi = +1 def) + (every 5 agi = +1 def) status->def2 += (int)(((float)level + status->vit)/2 + ((float)status->agi/5)); //base level + (every 2 agi = +1 def) + (every 5 agi = +1 def)
status->mdef2 += (int)(status->int_ + ((float)level/4) + ((float)status->dex/5) + ((float)status->vit/5)); //(every 4 base level = +1 mdef) + (every 1 int = +1 mdef) + (every 5 dex = +1 mdef) + (every 5 vit = +1 mdef) status->mdef2 += (int)(status->int_ + ((float)level/4) + ((float)status->dex/5) + ((float)status->vit/5)); //(every 4 base level = +1 mdef) + (every 1 int = +1 mdef) + (every 5 dex = +1 mdef) + (every 5 vit = +1 mdef)
#else //Old Formulas #else
status->hit += level + status->dex; status->hit += level + status->dex;
status->flee += level + status->agi; status->flee += level + status->agi;
status->def2 += status->vit; status->def2 += status->vit;
@ -1771,9 +1769,11 @@ void status_calc_misc(struct block_list *bl, struct status_data *status, int lev
status->batk = cap_value(temp, 0, USHRT_MAX); status->batk = cap_value(temp, 0, USHRT_MAX);
} else } else
status->batk = status_base_atk(bl, status); status->batk = status_base_atk(bl, status);
#if REMODE //Renewal ATK Bonus Formula (after atk is calculated)
#ifdef RENEWAL // renewal attack bonus formula
status->batk += (int)((float)status->luk/3 + (float)level/4); //(every 3 luk = + 1ATK) + (every 4 base level = +1 ATK) status->batk += (int)((float)status->luk/3 + (float)level/4); //(every 3 luk = + 1ATK) + (every 4 base level = +1 ATK)
#endif #endif
if (status->cri) if (status->cri)
switch (bl->type) { switch (bl->type) {
case BL_MOB: case BL_MOB:
@ -1932,7 +1932,7 @@ int status_calc_mob_(struct mob_data* md, bool first)
ShowError("status_calc_mob: No castle set at map %s\n", map[md->bl.m].name); ShowError("status_calc_mob: No castle set at map %s\n", map[md->bl.m].name);
else else
if(gc->castle_id < 24 || md->class_ == MOBID_EMPERIUM) { if(gc->castle_id < 24 || md->class_ == MOBID_EMPERIUM) {
#if REMODE #ifdef RENEWAL
status->max_hp += 50 * gc->defense; status->max_hp += 50 * gc->defense;
status->max_sp += 70 * gc->defense; status->max_sp += 70 * gc->defense;
#else #else
@ -2336,22 +2336,20 @@ int status_calc_pc_(struct map_session_data* sd, bool first)
wa->atk += sd->inventory_data[index]->atk; wa->atk += sd->inventory_data[index]->atk;
if ( (r = sd->status.inventory[index].refine) ) if ( (r = sd->status.inventory[index].refine) )
wa->atk2 = refine_info[wlv].bonus[r-1] / 100; wa->atk2 = refine_info[wlv].bonus[r-1] / 100;
#if REMODE
/** #ifdef RENEWAL
* in RE matk_max is used as the weapon's matk. // in renewal max MATK is the weapon MATK
* += is used so that two-wield weapons (in the case of, say, sinx) bonus stack.
**/
status->matk_max += sd->inventory_data[index]->matk; status->matk_max += sd->inventory_data[index]->matk;
/**
* Refine Bonus if( r )
**/ {// renewal magic attack refine bonus
if (r)
status->matk_max += refine_info[wlv].bonus[r-1] / 100; status->matk_max += refine_info[wlv].bonus[r-1] / 100;
/** }
* In RE weapon level is used in several areas, this way we save performance
**/ // record the weapon level for future usage
status->wlv = wlv; status->wlv = wlv;
#endif #endif
//Overrefine bonus. //Overrefine bonus.
if (r) if (r)
wd->overrefine = refine_info[wlv].randombonus_max[r-1] / 100; wd->overrefine = refine_info[wlv].randombonus_max[r-1] / 100;
@ -2413,13 +2411,10 @@ int status_calc_pc_(struct map_session_data* sd, bool first)
status->def += (refinedef+50)/100; status->def += (refinedef+50)/100;
#if REMODE #ifdef RENEWAL
/** // increment the weapon ATK using the MATK max value
* in RE matk_max is used as the weapon's matk. status->matk_max += sd->sp_weapon_matk;
* sp_weapon_matk is 'bonus bWeaponMatk,<boost>' #endif
**/
status->matk_max += sd->sp_weapon_matk;
#endif
//Parse Cards //Parse Cards
for(i=0;i<EQI_MAX-1;i++) { for(i=0;i<EQI_MAX-1;i++) {
@ -2738,16 +2733,15 @@ int status_calc_pc_(struct map_session_data* sd, bool first)
i = status->def * sd->def_rate/100; i = status->def * sd->def_rate/100;
status->def = cap_value(i, DEFTYPE_MIN, DEFTYPE_MAX); status->def = cap_value(i, DEFTYPE_MIN, DEFTYPE_MAX);
} }
#if isOFF(REMODE)
/** #ifndef RENEWAL
* The following setting does not affect Renewal Mode
**/
if (!battle_config.weapon_defense_type && status->def > battle_config.max_def) if (!battle_config.weapon_defense_type && status->def > battle_config.max_def)
{ {
status->def2 += battle_config.over_def_bonus*(status->def -battle_config.max_def); status->def2 += battle_config.over_def_bonus*(status->def -battle_config.max_def);
status->def = (unsigned char)battle_config.max_def; status->def = (unsigned char)battle_config.max_def;
} }
#endif #endif
// ----- EQUIPMENT-MDEF CALCULATION ----- // ----- EQUIPMENT-MDEF CALCULATION -----
// Apply relative modifiers from equipment // Apply relative modifiers from equipment
@ -2757,16 +2751,15 @@ int status_calc_pc_(struct map_session_data* sd, bool first)
i = status->mdef * sd->mdef_rate/100; i = status->mdef * sd->mdef_rate/100;
status->mdef = cap_value(i, DEFTYPE_MIN, DEFTYPE_MAX); status->mdef = cap_value(i, DEFTYPE_MIN, DEFTYPE_MAX);
} }
#if isOFF(REMODE)
/** #ifndef RENEWAL
* The following setting does not affect Renewal Mode
**/
if (!battle_config.magic_defense_type && status->mdef > battle_config.max_def) if (!battle_config.magic_defense_type && status->mdef > battle_config.max_def)
{ {
status->mdef2 += battle_config.over_def_bonus*(status->mdef -battle_config.max_def); status->mdef2 += battle_config.over_def_bonus*(status->mdef -battle_config.max_def);
status->mdef = (signed char)battle_config.max_def; status->mdef = (signed char)battle_config.max_def;
} }
#endif #endif
// ----- ASPD CALCULATION ----- // ----- ASPD CALCULATION -----
// Unlike other stats, ASPD rate modifiers from skills/SCs/items/etc are first all added together, then the final modifier is applied // Unlike other stats, ASPD rate modifiers from skills/SCs/items/etc are first all added together, then the final modifier is applied
@ -3002,12 +2995,11 @@ int status_calc_homunculus_(struct homun_data *hd, bool first)
status->adelay = status->amotion; //It seems adelay = amotion for Homunculus. status->adelay = status->amotion; //It seems adelay = amotion for Homunculus.
status_calc_misc(&hd->bl, status, hom->level); status_calc_misc(&hd->bl, status, hom->level);
#if REMODE
/** #ifdef RENEWAL
* In RE Mode matk_max is used as source of weaponMATK, but homuns don't have it -- so we swap the values here.
**/
status->matk_max = status->matk_min; status->matk_max = status->matk_min;
#endif #endif
status_cpy(&hd->battle_status, status); status_cpy(&hd->battle_status, status);
return 1; return 1;
} }
@ -3470,33 +3462,29 @@ void status_calc_bl_main(struct block_list *bl, /*enum scb_flag*/int flag)
} }
if(flag&SCB_MATK) { if(flag&SCB_MATK) {
//New matk #ifdef RENEWAL
#if REMODE
status->matk_min = status_base_matk_min(status,status_get_lv(bl)); status->matk_min = status_base_matk_min(status,status_get_lv(bl));
/**
* in RE matk_min is used as character's base matk
* sp_base_matk is 'bonus bMatk,<boost>'
**/
if( sd ) if( sd )
status->matk_min += sd->sp_base_matk; status->matk_min += sd->sp_base_matk;
#else #else
status->matk_min = status_base_matk_min(status); status->matk_min = status_base_matk_min(status);
#endif #endif
status->matk_max = status_base_matk_max(status); status->matk_max = status_base_matk_max(status);
if( bl->type&BL_PC && sd->matk_rate != 100 ) if( bl->type&BL_PC && sd->matk_rate != 100 )
{ {
//Bonuses from previous matk //Bonuses from previous matk
#if isOFF(REMODE) //Only changed in non-re [RRInd] #ifndef RENEWAL // only changed in non-renewal [Ind]
status->matk_max = status->matk_max * sd->matk_rate/100; status->matk_max = status->matk_max * sd->matk_rate/100;
#endif #endif
status->matk_min = status->matk_min * sd->matk_rate/100; status->matk_min = status->matk_min * sd->matk_rate/100;
} }
status->matk_min = status_calc_matk(bl, sc, status->matk_min); status->matk_min = status_calc_matk(bl, sc, status->matk_min);
#if isOFF(REMODE) //Only changed in non-re [RRInd]
status->matk_max = status_calc_matk(bl, sc, status->matk_max); #ifndef RENEWAL // only changed in non-renewal [Ind]
#endif status->matk_max = status_calc_matk(bl, sc, status->matk_max);
#endif
if( bl->type&BL_HOM && battle_config.hom_setting&0x20 ) //Hom Min Matk is always the same as Max Matk if( bl->type&BL_HOM && battle_config.hom_setting&0x20 ) //Hom Min Matk is always the same as Max Matk
status->matk_min = status->matk_max; status->matk_min = status->matk_max;
@ -3641,7 +3629,7 @@ void status_calc_bl_(struct block_list* bl, enum scb_flag flag, bool first)
clif_updatestatus(sd,SP_SPEED); clif_updatestatus(sd,SP_SPEED);
if(b_status.batk != status->batk if(b_status.batk != status->batk
#if !REMODE #ifndef RENEWAL
|| b_status.rhw.atk != status->rhw.atk || b_status.lhw.atk != status->lhw.atk || b_status.rhw.atk != status->rhw.atk || b_status.lhw.atk != status->lhw.atk
#endif #endif
) )
@ -3651,8 +3639,8 @@ void status_calc_bl_(struct block_list* bl, enum scb_flag flag, bool first)
clif_updatestatus(sd,SP_DEF1); clif_updatestatus(sd,SP_DEF1);
if(b_status.rhw.atk2 != status->rhw.atk2 || b_status.lhw.atk2 != status->lhw.atk2 if(b_status.rhw.atk2 != status->rhw.atk2 || b_status.lhw.atk2 != status->lhw.atk2
#if REMODE #ifdef RENEWAL
|| b_status.rhw.atk != status->rhw.atk || b_status.lhw.atk != status->lhw.atk || b_status.rhw.atk != status->rhw.atk || b_status.lhw.atk != status->lhw.atk
#endif #endif
) )
clif_updatestatus(sd,SP_ATK2); clif_updatestatus(sd,SP_ATK2);
@ -4064,10 +4052,8 @@ static unsigned short status_calc_batk(struct block_list *bl, struct status_chan
batk += sc->data[SC_FULL_SWING_K]->val1; batk += sc->data[SC_FULL_SWING_K]->val1;
if(sc->data[SC_ODINS_POWER]) if(sc->data[SC_ODINS_POWER])
batk += 70; batk += 70;
#if RE_EDP #ifdef RENEWAL_EDP
/** // renewal EDP increases your base atk by atk x skill level
* in RE EDP increases your base atk by atk x Skill Level.
**/
if( sc->data[SC_EDP] ) if( sc->data[SC_EDP] )
batk = batk * sc->data[SC_EDP]->val1; batk = batk * sc->data[SC_EDP]->val1;
#endif #endif
@ -4142,10 +4128,8 @@ static unsigned short status_calc_watk(struct block_list *bl, struct status_chan
if( sc && sc->data[SC_TIDAL_WEAPON] ) if( sc && sc->data[SC_TIDAL_WEAPON] )
watk += watk * sc->data[SC_TIDAL_WEAPON]->val2 / 100; watk += watk * sc->data[SC_TIDAL_WEAPON]->val2 / 100;
#if RE_EDP #ifdef RENEWAL_EDP
/** // renewal EDP increases your weapon atk by watk x Skill Level - 1
* in RE EDP increases your weapon atk by watk x Skill Level - 1
**/
if( sc->data[SC_EDP] && sc->data[SC_EDP]->val1 > 1 ) if( sc->data[SC_EDP] && sc->data[SC_EDP]->val1 > 1 )
watk = watk * (sc->data[SC_EDP]->val1 - 1); watk = watk * (sc->data[SC_EDP]->val1 - 1);
#endif #endif
@ -4211,7 +4195,7 @@ static signed short status_calc_critical(struct block_list *bl, struct status_ch
critical += 100; critical += 100;
if(sc->data[SC__UNLUCKY]) if(sc->data[SC__UNLUCKY])
critical -= critical * sc->data[SC__UNLUCKY]->val2 / 100; critical -= critical * sc->data[SC__UNLUCKY]->val2 / 100;
#if REMODE #ifdef RENEWAL
if (sc->data[SC_SPEARQUICKEN]) if (sc->data[SC_SPEARQUICKEN])
critical += 3*sc->data[SC_SPEARQUICKEN]->val1*10; critical += 3*sc->data[SC_SPEARQUICKEN]->val1*10;
#endif #endif
@ -4320,7 +4304,7 @@ static signed short status_calc_flee(struct block_list *bl, struct status_change
flee += flee * sc->data[SC_ZEPHYR]->val2 / 100; flee += flee * sc->data[SC_ZEPHYR]->val2 / 100;
if( sc->data[SC_MARSHOFABYSS] ) if( sc->data[SC_MARSHOFABYSS] )
flee -= (9 * sc->data[SC_MARSHOFABYSS]->val3 / 10 + sc->data[SC_MARSHOFABYSS]->val2 / 10) * (bl->type == BL_MOB ? 2 : 1); flee -= (9 * sc->data[SC_MARSHOFABYSS]->val3 / 10 + sc->data[SC_MARSHOFABYSS]->val2 / 10) * (bl->type == BL_MOB ? 2 : 1);
#if REMODE #ifdef RENEWAL
if( sc->data[SC_SPEARQUICKEN] ) if( sc->data[SC_SPEARQUICKEN] )
flee += 2 * sc->data[SC_SPEARQUICKEN]->val1; flee += 2 * sc->data[SC_SPEARQUICKEN]->val1;
#endif #endif
@ -4355,10 +4339,8 @@ static defType status_calc_def(struct block_list *bl, struct status_change *sc,
return 100; return 100;
if(sc->data[SC_KEEPING]) if(sc->data[SC_KEEPING])
return 90; return 90;
/**
* In renewal it no longer provides 90 def #ifndef RENEWAL // does not provide 90 DEF in renewal mode
**/
#if isOFF(REMODE)
if(sc->data[SC_STEELBODY]) if(sc->data[SC_STEELBODY])
return 90; return 90;
#endif #endif
@ -4470,13 +4452,12 @@ static defType status_calc_mdef(struct block_list *bl, struct status_change *sc,
return 0; return 0;
if(sc->data[SC_BARRIER]) if(sc->data[SC_BARRIER])
return 100; return 100;
/**
* In renewal it no longer provides 90 mdef #ifndef RENEWAL // no longer provides 90 MDEF in renewal mode
**/
#if isOFF(REMODE)
if(sc->data[SC_STEELBODY]) if(sc->data[SC_STEELBODY])
return 90; return 90;
#endif #endif
if(sc->data[SC_ARMORCHANGE]) if(sc->data[SC_ARMORCHANGE])
mdef += sc->data[SC_ARMORCHANGE]->val3; mdef += sc->data[SC_ARMORCHANGE]->val3;
if(sc->data[SC_STONE] && sc->opt1 == OPT1_STONE) if(sc->data[SC_STONE] && sc->opt1 == OPT1_STONE)
@ -4703,12 +4684,10 @@ static unsigned short status_calc_speed(struct block_list *bl, struct status_cha
/// Note that the scale of aspd_rate is 1000 = 100%. /// Note that the scale of aspd_rate is 1000 = 100%.
static short status_calc_aspd_rate(struct block_list *bl, struct status_change *sc, int aspd_rate) static short status_calc_aspd_rate(struct block_list *bl, struct status_change *sc, int aspd_rate)
{ {
#if isOFF(REMODE) #ifndef RENEWAL
/**
* this variable is not used unless in non-RE
**/
int i; int i;
#endif #endif
if(!sc || !sc->count) if(!sc || !sc->count)
return cap_value(aspd_rate,0,SHRT_MAX); return cap_value(aspd_rate,0,SHRT_MAX);
@ -4738,7 +4717,7 @@ static short status_calc_aspd_rate(struct block_list *bl, struct status_change *
max < sc->data[SC_ADRENALINE]->val3) max < sc->data[SC_ADRENALINE]->val3)
max = sc->data[SC_ADRENALINE]->val3; max = sc->data[SC_ADRENALINE]->val3;
#if isOFF(REMODE) #ifndef RENEWAL
if(sc->data[SC_SPEARQUICKEN] && if(sc->data[SC_SPEARQUICKEN] &&
max < sc->data[SC_SPEARQUICKEN]->val2) max < sc->data[SC_SPEARQUICKEN]->val2)
max = sc->data[SC_SPEARQUICKEN]->val2; max = sc->data[SC_SPEARQUICKEN]->val2;
@ -4779,16 +4758,15 @@ static short status_calc_aspd_rate(struct block_list *bl, struct status_change *
else if(sc->data[SC_MADNESSCANCEL]) else if(sc->data[SC_MADNESSCANCEL])
aspd_rate -= 200; aspd_rate -= 200;
} }
#if isOFF(REMODE)
/** #ifndef RENEWAL // non-renewal variable ASPD improvement
* in RE they give a fixed boost -- we do so along SERVICE4U in status_base_amotion_pc if( sc->data[i=SC_ASPDPOTION3] ||
**/
if(sc->data[i=SC_ASPDPOTION3] ||
sc->data[i=SC_ASPDPOTION2] || sc->data[i=SC_ASPDPOTION2] ||
sc->data[i=SC_ASPDPOTION1] || sc->data[i=SC_ASPDPOTION1] ||
sc->data[i=SC_ASPDPOTION0]) sc->data[i=SC_ASPDPOTION0] )
aspd_rate -= sc->data[i]->val2; aspd_rate -= sc->data[i]->val2;
#endif #endif
if(sc->data[SC_DONTFORGETME]) if(sc->data[SC_DONTFORGETME])
aspd_rate += 10 * sc->data[SC_DONTFORGETME]->val2; aspd_rate += 10 * sc->data[SC_DONTFORGETME]->val2;
if(sc->data[SC_LONGING]) if(sc->data[SC_LONGING])
@ -6495,24 +6473,24 @@ int status_change_start(struct block_list* bl,enum sc_type type,int rate,int val
break; break;
case SC_VOLCANO: case SC_VOLCANO:
val2 = val1*10; //Watk increase val2 = val1*10; //Watk increase
#if isOFF(REMODE) #ifndef RENEWAL
if (status->def_ele != ELE_FIRE) if (status->def_ele != ELE_FIRE)
val2 = 0; val2 = 0;
#endif #endif
break; break;
case SC_VIOLENTGALE: case SC_VIOLENTGALE:
val2 = val1*3; //Flee increase val2 = val1*3; //Flee increase
#if isOFF(REMODE) #ifndef RENEWAL
if (status->def_ele != ELE_WIND) if (status->def_ele != ELE_WIND)
val2 = 0; val2 = 0;
#endif #endif
break; break;
case SC_DELUGE: case SC_DELUGE:
val2 = deluge_eff[val1-1]; //HP increase val2 = deluge_eff[val1-1]; //HP increase
#if isOFF(REMODE) #ifndef RENEWAL
if(status->def_ele != ELE_WATER) if(status->def_ele != ELE_WATER)
val2 = 0; val2 = 0;
#endif #endif
break; break;
case SC_SUITON: case SC_SUITON:
if (!val2 || (sd && (sd->class_&MAPID_UPPERMASK) == MAPID_NINJA)) { if (!val2 || (sd && (sd->class_&MAPID_UPPERMASK) == MAPID_NINJA)) {
@ -6534,7 +6512,7 @@ int status_change_start(struct block_list* bl,enum sc_type type,int rate,int val
case SC_MERC_QUICKEN: case SC_MERC_QUICKEN:
val2 = 300; val2 = 300;
break; break;
#if isOFF(REMODE) #ifndef RENEWAL
case SC_SPEARQUICKEN: case SC_SPEARQUICKEN:
val2 = 200+10*val1; val2 = 200+10*val1;
break; break;
@ -6556,10 +6534,7 @@ int status_change_start(struct block_list* bl,enum sc_type type,int rate,int val
case SC_EXPLOSIONSPIRITS: case SC_EXPLOSIONSPIRITS:
val2 = 75 + 25*val1; //Cri bonus val2 = 75 + 25*val1; //Cri bonus
break; break;
#if isOFF(REMODE) #ifndef RENEWAL
/**
* Only in non-RE it's var is changed
**/
case SC_ASPDPOTION0: case SC_ASPDPOTION0:
case SC_ASPDPOTION1: case SC_ASPDPOTION1:
case SC_ASPDPOTION2: case SC_ASPDPOTION2:
@ -10047,7 +10022,7 @@ int status_get_refine_chance(enum refine_type wlv, int refine)
* size_fix.txt - size adjustment table for weapons * size_fix.txt - size adjustment table for weapons
* refine_db.txt - refining data table * refine_db.txt - refining data table
*------------------------------------------*/ *------------------------------------------*/
#if REMODE #ifdef RENEWAL
static bool status_readdb_job_re(char* fields[], int columns, int current) { static bool status_readdb_job_re(char* fields[], int columns, int current) {
int idx, class_; int idx, class_;
unsigned int i; unsigned int i;
@ -10066,6 +10041,7 @@ static bool status_readdb_job_re(char* fields[], int columns, int current) {
return true; return true;
} }
#endif #endif
static bool status_readdb_job1(char* fields[], int columns, int current) static bool status_readdb_job1(char* fields[], int columns, int current)
{// Job-specific values (weight, HP, SP, ASPD) {// Job-specific values (weight, HP, SP, ASPD)
int idx, class_; int idx, class_;
@ -10170,7 +10146,7 @@ int status_readdb(void)
memset(hp_coefficient2, 0, sizeof(hp_coefficient2)); memset(hp_coefficient2, 0, sizeof(hp_coefficient2));
memset(sp_coefficient, 0, sizeof(sp_coefficient)); memset(sp_coefficient, 0, sizeof(sp_coefficient));
memset(aspd_base, 0, sizeof(aspd_base)); memset(aspd_base, 0, sizeof(aspd_base));
#if REMODE #ifdef RENEWAL
memset(re_job_db, 0, sizeof(re_job_db)); memset(re_job_db, 0, sizeof(re_job_db));
#endif #endif
// job_db2.txt // job_db2.txt
@ -10198,7 +10174,7 @@ int status_readdb(void)
sv_readdb(db_path, "job_db1.txt", ',', 5+MAX_WEAPON_TYPE, 5+MAX_WEAPON_TYPE, -1, &status_readdb_job1); sv_readdb(db_path, "job_db1.txt", ',', 5+MAX_WEAPON_TYPE, 5+MAX_WEAPON_TYPE, -1, &status_readdb_job1);
sv_readdb(db_path, "job_db2.txt", ',', 1, 1+MAX_LEVEL, -1, &status_readdb_job2); sv_readdb(db_path, "job_db2.txt", ',', 1, 1+MAX_LEVEL, -1, &status_readdb_job2);
sv_readdb(db_path, "size_fix.txt", ',', MAX_WEAPON_TYPE, MAX_WEAPON_TYPE, ARRAYLENGTH(atkmods), &status_readdb_sizefix); sv_readdb(db_path, "size_fix.txt", ',', MAX_WEAPON_TYPE, MAX_WEAPON_TYPE, ARRAYLENGTH(atkmods), &status_readdb_sizefix);
#if REMODE #ifdef RENEWAL
sv_readdb(db_path, DBPATH"job_db_extra.txt", ',', 1+RE_JOB_DB_MAX, 1+RE_JOB_DB_MAX, -1, &status_readdb_job_re); sv_readdb(db_path, DBPATH"job_db_extra.txt", ',', 1+RE_JOB_DB_MAX, 1+RE_JOB_DB_MAX, -1, &status_readdb_job_re);
#endif #endif
sv_readdb(db_path, DBPATH"refine_db.txt", ',', 4+MAX_REFINE, 4+MAX_REFINE, ARRAYLENGTH(refine_info), &status_readdb_refine); sv_readdb(db_path, DBPATH"refine_db.txt", ',', 4+MAX_REFINE, 4+MAX_REFINE, ARRAYLENGTH(refine_info), &status_readdb_refine);

View File

@ -15,10 +15,10 @@ struct status_change;
* Max Refine available to your server * Max Refine available to your server
* Changing this limit requires edits to refine_db.txt * Changing this limit requires edits to refine_db.txt
**/ **/
#if REMODE #ifdef RENEWAL
#define MAX_REFINE 20 # define MAX_REFINE 20
#else #else
#define MAX_REFINE 10 # define MAX_REFINE 10
#endif #endif
enum refine_type { enum refine_type {
@ -1481,7 +1481,7 @@ struct status_data {
unsigned char unsigned char
def_ele, ele_lv, def_ele, ele_lv,
#if REMODE #ifdef RENEWAL
/** /**
* in RE weapon level is used in several areas, keeping it here saves performance * in RE weapon level is used in several areas, keeping it here saves performance
**/ **/
@ -1554,7 +1554,7 @@ struct status_change {
/** /**
* The Storm Gust counter was dropped in renewal * The Storm Gust counter was dropped in renewal
**/ **/
#if isOFF(REMODE) #ifndef RENEWAL
unsigned char sg_counter; //Storm gust counter (previous hits from storm gust) unsigned char sg_counter; //Storm gust counter (previous hits from storm gust)
#endif #endif
struct status_change_entry *data[SC_MAX]; struct status_change_entry *data[SC_MAX];
@ -1630,7 +1630,7 @@ unsigned char status_calc_attack_element(struct block_list *bl, struct status_ch
#define status_get_race(bl) status_get_status_data(bl)->race #define status_get_race(bl) status_get_status_data(bl)->race
#define status_get_size(bl) status_get_status_data(bl)->size #define status_get_size(bl) status_get_status_data(bl)->size
#define status_get_mode(bl) status_get_status_data(bl)->mode #define status_get_mode(bl) status_get_status_data(bl)->mode
#if REMODE #ifdef RENEWAL
/** /**
* in RE weapon level is used in several areas, keeping it here saves performance * in RE weapon level is used in several areas, keeping it here saves performance
**/ **/