diff options
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/battle.c | 2 | ||||
-rw-r--r-- | src/map/battle.h | 2 | ||||
-rw-r--r-- | src/map/mercenary.c | 3 |
3 files changed, 6 insertions, 1 deletions
diff --git a/src/map/battle.c b/src/map/battle.c index 0376a2ac3..f4a28b534 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -3738,6 +3738,7 @@ static const struct battle_data_short { { "override_mob_names", &battle_config.override_mob_names }, { "min_chat_delay", &battle_config.min_chat_delay }, { "homunculus_show_growth", &battle_config.homunculus_show_growth }, //[orn] + { "homunculus_friendly_rate", &battle_config.homunculus_friendly_rate }, }; static const struct battle_data_int { @@ -4171,6 +4172,7 @@ void battle_set_defaults() { battle_config.min_chat_delay = 0; battle_config.hvan_explosion_intimate = 45000; //[orn] battle_config.homunculus_show_growth = 0; //[orn] + battle_config.homunculus_friendly_rate = 100; } void battle_validate_conf() { diff --git a/src/map/battle.h b/src/map/battle.h index e78713583..588317f2a 100644 --- a/src/map/battle.h +++ b/src/map/battle.h @@ -437,7 +437,7 @@ extern struct Battle_Config { unsigned short min_chat_delay; //Minimum time between client messages. [Skotlex]
unsigned int hvan_explosion_intimate ; // fix [albator]
unsigned short homunculus_show_growth ; //[orn]
-
+ unsigned short homunculus_friendly_rate;
} battle_config;
void do_init_battle(void);
diff --git a/src/map/mercenary.c b/src/map/mercenary.c index 118bda037..472ac285c 100644 --- a/src/map/mercenary.c +++ b/src/map/mercenary.c @@ -393,6 +393,9 @@ int merc_hom_gainexp(struct homun_data *hd,int exp) // Return then new value
int merc_hom_increase_intimacy(struct homun_data * hd, unsigned int value)
{
+ if (battle_config.homunculus_friendly_rate != 100)
+ value = (value * battle_config.homunculus_friendly_rate) / 100;
+
if (hd->master->homunculus.intimacy + value <= 100000)
hd->master->homunculus.intimacy += value;
else
|