summaryrefslogtreecommitdiff
path: root/src/map/mob.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-05-05 16:30:47 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-05-05 16:30:47 +0000
commitd99c0313edbb4bd24172f825b7d621ad620ec7d1 (patch)
treeadac4c1ccf43f1a85c65f0e47dc3b4a8af9c8044 /src/map/mob.c
parentfc694ecbe6734d01c0a1626beb96f514fb06aa5e (diff)
downloadhercules-d99c0313edbb4bd24172f825b7d621ad620ec7d1.tar.gz
hercules-d99c0313edbb4bd24172f825b7d621ad620ec7d1.tar.bz2
hercules-d99c0313edbb4bd24172f825b7d621ad620ec7d1.tar.xz
hercules-d99c0313edbb4bd24172f825b7d621ad620ec7d1.zip
- Being in Enjoyable Rest state will now also trigger the HP/SP Time skills (even if there's no other TK around).
- Renamed SC_TKDORI to SC_TKREST (makes more sense if you ask me) - Added battle config settings view_range_rate and chase_range_rate to adjust the view-range and chase-range (range2/range3) of the mob_db without having to manually change them. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@6490 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/mob.c')
-rw-r--r--src/map/mob.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/map/mob.c b/src/map/mob.c
index 20afedab4..5e6c5765a 100644
--- a/src/map/mob.c
+++ b/src/map/mob.c
@@ -3152,6 +3152,22 @@ static int mob_readdb(void)
mob_db_data[class_]->luk=atoi(str[19]);
mob_db_data[class_]->range2=atoi(str[20]);
mob_db_data[class_]->range3=atoi(str[21]);
+ if (battle_config.view_range_rate!=100)
+ {
+ mob_db_data[class_]->range2=
+ mob_db_data[class_]->range2
+ *battle_config.view_range_rate/100;
+ if (mob_db_data[class_]->range2<1)
+ mob_db_data[class_]->range2=1;
+ }
+ if (battle_config.chase_range_rate!=100)
+ {
+ mob_db_data[class_]->range3=
+ mob_db_data[class_]->range3
+ *battle_config.chase_range_rate/100;
+ if (mob_db_data[class_]->range3<mob_db_data[class_]->range2)
+ mob_db_data[class_]->range3=mob_db_data[class_]->range2;
+ }
mob_db_data[class_]->size=atoi(str[22]);
mob_db_data[class_]->race=atoi(str[23]);
mob_db_data[class_]->element=atoi(str[24]);