diff options
author | Lupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-29 11:16:21 +0000 |
---|---|---|
committer | Lupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-04-29 11:16:21 +0000 |
commit | 35b1cc992905844a59757bed76512ef7fe769d5a (patch) | |
tree | 81a698a6a5b1a3f5d3ecc3102b5f79a40f0caae1 /src/map/battle.c | |
parent | 90c05f50a7ab6140cd1c95b005c4e5456fc42bf2 (diff) | |
download | hercules-35b1cc992905844a59757bed76512ef7fe769d5a.tar.gz hercules-35b1cc992905844a59757bed76512ef7fe769d5a.tar.bz2 hercules-35b1cc992905844a59757bed76512ef7fe769d5a.tar.xz hercules-35b1cc992905844a59757bed76512ef7fe769d5a.zip |
Updated STEAL skill (WIP), added a battle config option: 'skill_steal_max_tries' to set max number of stealing tries. It could help to fix stealing exploit on mobs with few drops
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6367 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/battle.c')
-rw-r--r-- | src/map/battle.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/map/battle.c b/src/map/battle.c index 15dabe24d..408a2fa31 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -3826,6 +3826,7 @@ static const struct battle_data_short { { "pk_min_level", &battle_config.pk_min_level}, // [celest]
{ "skill_steal_type", &battle_config.skill_steal_type}, // [celest]
{ "skill_steal_rate", &battle_config.skill_steal_rate}, // [celest]
+ { "skill_steal_max_tries", &battle_config.skill_steal_max_tries}, // [Lupus]
// { "night_darkness_level", &battle_config.night_darkness_level}, // [celest]
{ "motd_type", &battle_config.motd_type}, // [celest]
{ "allow_atcommand_when_mute", &battle_config.allow_atcommand_when_mute}, // [celest]
@@ -4226,6 +4227,7 @@ void battle_set_defaults() { battle_config.pk_min_level = 55;
battle_config.skill_steal_type = 1;
battle_config.skill_steal_rate = 100;
+ battle_config.skill_steal_max_tries = 256;
// battle_config.night_darkness_level = 9;
battle_config.motd_type = 0;
battle_config.allow_atcommand_when_mute = 0;
@@ -4489,6 +4491,9 @@ void battle_validate_conf() { if (battle_config.sg_miracle_skill_ratio > 10000)
battle_config.sg_miracle_skill_ratio = 10000;
+ if (battle_config.skill_steal_max_tries > 256)
+ battle_config.skill_steal_max_tries = 256;
+
#ifdef CELL_NOSTACK
if (battle_config.cell_stack_limit < 1)
battle_config.cell_stack_limit = 1;
|