- Added battle config settings agi_penalty_target and vit_penalty_target, they define which object types will get vit/flee reductions when multi-targetted and defaults to only players (battle/battle.conf)
git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@7774 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
parent
5b8eac3bc4
commit
e5b4eaaea0
@ -4,6 +4,9 @@ AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO
|
|||||||
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
|
||||||
|
|
||||||
2006/07/20
|
2006/07/20
|
||||||
|
* Added battle config settings agi_penalty_target and vit_penalty_target,
|
||||||
|
they define which object types will get vit/flee reductions when
|
||||||
|
multi-targetted and defaults to only players (battle/battle.conf) [Skotlex]
|
||||||
* Added the dummy intravision case for the changeoption packet 0x229
|
* Added the dummy intravision case for the changeoption packet 0x229
|
||||||
[Skotlex]
|
[Skotlex]
|
||||||
* Corrected Fog of Wall so that all targetted offensive skills (not only
|
* Corrected Fog of Wall so that all targetted offensive skills (not only
|
||||||
|
@ -72,6 +72,10 @@ max_hitrate: 100
|
|||||||
// 2 = agi_penalty_num is reduced from FLEE as an exact amount
|
// 2 = agi_penalty_num is reduced from FLEE as an exact amount
|
||||||
agi_penalty_type: 1
|
agi_penalty_type: 1
|
||||||
|
|
||||||
|
// When agi penalty is enabled, to whom it should apply to? (Note 4)
|
||||||
|
// By default, only players get the penalty.
|
||||||
|
agi_penalty_target: 1
|
||||||
|
|
||||||
// Amount of enemies required to be targetting player before FLEE begins to be penalized
|
// Amount of enemies required to be targetting player before FLEE begins to be penalized
|
||||||
agi_penalty_count: 3
|
agi_penalty_count: 3
|
||||||
|
|
||||||
@ -84,7 +88,11 @@ agi_penalty_num: 10
|
|||||||
// 2 = vit_penalty_num is reduced from FLEE as an exact amount
|
// 2 = vit_penalty_num is reduced from FLEE as an exact amount
|
||||||
vit_penalty_type: 1
|
vit_penalty_type: 1
|
||||||
|
|
||||||
// Amount of enemies required to be targetting player before VIT defense begins to be penalized
|
// When vit penalty is enabled, to whom it should apply to? (Note 4)
|
||||||
|
// By default, only players get the penalty.
|
||||||
|
vit_penalty_target: 1
|
||||||
|
|
||||||
|
// Amount of enemies required to be targetting player before defense begins to be penalized
|
||||||
vit_penalty_count: 3
|
vit_penalty_count: 3
|
||||||
|
|
||||||
// Amount of VIT defense penalized per each attacking monster more than vit_penalty_count
|
// Amount of VIT defense penalized per each attacking monster more than vit_penalty_count
|
||||||
|
@ -1043,7 +1043,8 @@ static struct Damage battle_calc_weapon_attack(
|
|||||||
flee = tstatus->flee,
|
flee = tstatus->flee,
|
||||||
hitrate=80; //Default hitrate
|
hitrate=80; //Default hitrate
|
||||||
|
|
||||||
if(battle_config.agi_penalty_type)
|
if(battle_config.agi_penalty_type &&
|
||||||
|
battle_config.agi_penalty_target&target->type)
|
||||||
{
|
{
|
||||||
unsigned char target_count; //256 max targets should be a sane max
|
unsigned char target_count; //256 max targets should be a sane max
|
||||||
target_count = unit_counttargeted(target,battle_config.agi_penalty_count_lv);
|
target_count = unit_counttargeted(target,battle_config.agi_penalty_count_lv);
|
||||||
@ -1626,7 +1627,8 @@ static struct Damage battle_calc_weapon_attack(
|
|||||||
short vit_def;
|
short vit_def;
|
||||||
signed char def1 = (signed char)status_get_def(target); //Don't use tstatus->def1 due to skill timer reductions.
|
signed char def1 = (signed char)status_get_def(target); //Don't use tstatus->def1 due to skill timer reductions.
|
||||||
short def2 = (short)tstatus->def2;
|
short def2 = (short)tstatus->def2;
|
||||||
if(battle_config.vit_penalty_type)
|
if(battle_config.vit_penalty_type &&
|
||||||
|
battle_config.vit_penalty_target&target->type)
|
||||||
{
|
{
|
||||||
unsigned char target_count; //256 max targets should be a sane max
|
unsigned char target_count; //256 max targets should be a sane max
|
||||||
target_count = unit_counttargeted(target,battle_config.vit_penalty_count_lv);
|
target_count = unit_counttargeted(target,battle_config.vit_penalty_count_lv);
|
||||||
@ -2582,7 +2584,8 @@ struct Damage battle_calc_misc_attack(
|
|||||||
flee = tstatus->flee,
|
flee = tstatus->flee,
|
||||||
hitrate=80; //Default hitrate
|
hitrate=80; //Default hitrate
|
||||||
|
|
||||||
if(battle_config.agi_penalty_type)
|
if(battle_config.agi_penalty_type &&
|
||||||
|
battle_config.agi_penalty_target&target->type)
|
||||||
{
|
{
|
||||||
unsigned char target_count; //256 max targets should be a sane max
|
unsigned char target_count; //256 max targets should be a sane max
|
||||||
target_count = unit_counttargeted(target,battle_config.agi_penalty_count_lv);
|
target_count = unit_counttargeted(target,battle_config.agi_penalty_count_lv);
|
||||||
@ -3450,10 +3453,12 @@ static const struct battle_data_short {
|
|||||||
{ "auto_counter_type", &battle_config.auto_counter_type },
|
{ "auto_counter_type", &battle_config.auto_counter_type },
|
||||||
{ "min_hitrate", &battle_config.min_hitrate },
|
{ "min_hitrate", &battle_config.min_hitrate },
|
||||||
{ "max_hitrate", &battle_config.max_hitrate },
|
{ "max_hitrate", &battle_config.max_hitrate },
|
||||||
|
{ "agi_penalty_target", &battle_config.agi_penalty_target },
|
||||||
{ "agi_penalty_type", &battle_config.agi_penalty_type },
|
{ "agi_penalty_type", &battle_config.agi_penalty_type },
|
||||||
{ "agi_penalty_count", &battle_config.agi_penalty_count },
|
{ "agi_penalty_count", &battle_config.agi_penalty_count },
|
||||||
{ "agi_penalty_num", &battle_config.agi_penalty_num },
|
{ "agi_penalty_num", &battle_config.agi_penalty_num },
|
||||||
{ "agi_penalty_count_lv", &battle_config.agi_penalty_count_lv },
|
{ "agi_penalty_count_lv", &battle_config.agi_penalty_count_lv },
|
||||||
|
{ "vit_penalty_target", &battle_config.vit_penalty_target },
|
||||||
{ "vit_penalty_type", &battle_config.vit_penalty_type },
|
{ "vit_penalty_type", &battle_config.vit_penalty_type },
|
||||||
{ "vit_penalty_count", &battle_config.vit_penalty_count },
|
{ "vit_penalty_count", &battle_config.vit_penalty_count },
|
||||||
{ "vit_penalty_num", &battle_config.vit_penalty_num },
|
{ "vit_penalty_num", &battle_config.vit_penalty_num },
|
||||||
@ -3857,10 +3862,12 @@ void battle_set_defaults() {
|
|||||||
battle_config.auto_counter_type = BL_ALL;
|
battle_config.auto_counter_type = BL_ALL;
|
||||||
battle_config.min_hitrate = 5;
|
battle_config.min_hitrate = 5;
|
||||||
battle_config.max_hitrate = 100;
|
battle_config.max_hitrate = 100;
|
||||||
|
battle_config.agi_penalty_target = BL_PC;
|
||||||
battle_config.agi_penalty_type = 1;
|
battle_config.agi_penalty_type = 1;
|
||||||
battle_config.agi_penalty_count = 3;
|
battle_config.agi_penalty_count = 3;
|
||||||
battle_config.agi_penalty_num = 10;
|
battle_config.agi_penalty_num = 10;
|
||||||
battle_config.agi_penalty_count_lv = ATK_FLEE;
|
battle_config.agi_penalty_count_lv = ATK_FLEE;
|
||||||
|
battle_config.vit_penalty_target = BL_PC;
|
||||||
battle_config.vit_penalty_type = 1;
|
battle_config.vit_penalty_type = 1;
|
||||||
battle_config.vit_penalty_count = 3;
|
battle_config.vit_penalty_count = 3;
|
||||||
battle_config.vit_penalty_num = 5;
|
battle_config.vit_penalty_num = 5;
|
||||||
|
@ -228,9 +228,11 @@ extern struct Battle_Config {
|
|||||||
unsigned short auto_counter_type;
|
unsigned short auto_counter_type;
|
||||||
unsigned short min_hitrate; //[Skotlex]
|
unsigned short min_hitrate; //[Skotlex]
|
||||||
unsigned short max_hitrate; //[Skotlex]
|
unsigned short max_hitrate; //[Skotlex]
|
||||||
|
unsigned short agi_penalty_target;
|
||||||
unsigned short agi_penalty_type;
|
unsigned short agi_penalty_type;
|
||||||
unsigned short agi_penalty_count;
|
unsigned short agi_penalty_count;
|
||||||
unsigned short agi_penalty_num;
|
unsigned short agi_penalty_num;
|
||||||
|
unsigned short vit_penalty_target;
|
||||||
unsigned short vit_penalty_type;
|
unsigned short vit_penalty_type;
|
||||||
unsigned short vit_penalty_count;
|
unsigned short vit_penalty_count;
|
||||||
unsigned short vit_penalty_num;
|
unsigned short vit_penalty_num;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user