summaryrefslogtreecommitdiff
path: root/src/map/mob.c
diff options
context:
space:
mode:
authorskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-12-19 13:41:25 +0000
committerskotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-12-19 13:41:25 +0000
commitd07073885c8ffd1f1ed58beaa34ad281dbe1a68a (patch)
treeb90d325fa23414a55b40d04b58c6bf7a5101cfc9 /src/map/mob.c
parent70dc3acce080b3c4f5061c2394911149d0d82aa4 (diff)
downloadhercules-d07073885c8ffd1f1ed58beaa34ad281dbe1a68a.tar.gz
hercules-d07073885c8ffd1f1ed58beaa34ad281dbe1a68a.tar.bz2
hercules-d07073885c8ffd1f1ed58beaa34ad281dbe1a68a.tar.xz
hercules-d07073885c8ffd1f1ed58beaa34ad281dbe1a68a.zip
- Reverted the mob ThinkTime update, that field is again aDelay as it apparently should be.
- Fixed one small compilation error. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@9522 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/mob.c')
-rw-r--r--src/map/mob.c22
1 files changed, 6 insertions, 16 deletions
diff --git a/src/map/mob.c b/src/map/mob.c
index b2dc67482..f38a5d3ac 100644
--- a/src/map/mob.c
+++ b/src/map/mob.c
@@ -1063,7 +1063,7 @@ static int mob_ai_sub_hard(struct block_list *bl,va_list ap)
if(md->bl.prev == NULL || md->status.hp <= 0)
return 1;
- if (DIFF_TICK(tick, md->last_thinktime) < md->db->min_thinktime)
+ if (DIFF_TICK(tick, md->last_thinktime) < MIN_MOBTHINKTIME)
return 0;
md->last_thinktime = tick;
@@ -1335,7 +1335,7 @@ static int mob_ai_sub_lazy(DBKey key,void * data,va_list ap)
tick=va_arg(ap,unsigned int);
- if(DIFF_TICK(tick,md->last_thinktime)< 10*md->db->min_thinktime)
+ if(DIFF_TICK(tick,md->last_thinktime)< 10*MIN_MOBTHINKTIME)
return 0;
md->last_thinktime=tick;
@@ -2925,7 +2925,6 @@ int mob_clone_spawn(struct map_session_data *sd, int m, int x, int y, const char
mob_db_data[class_]->job_exp=1;
mob_db_data[class_]->range2=AREA_SIZE; //Let them have the same view-range as players.
mob_db_data[class_]->range3=AREA_SIZE; //Min chase of a screen.
- mob_db_data[class_]->min_thinktime = 500; //Average player's reflexes?
mob_db_data[class_]->option=sd->sc.option;
//Skill copy [Skotlex]
@@ -3143,7 +3142,6 @@ static int mob_makedummymobdb(int class_)
mob_dummy->status.adelay=1000;
mob_dummy->status.amotion=500;
mob_dummy->status.dmotion=500;
- mob_dummy->min_thinktime=5000;
mob_dummy->base_exp=2;
mob_dummy->job_exp=1;
mob_dummy->range2=10;
@@ -3308,12 +3306,8 @@ static int mob_readdb(void)
status->mode&=~MD_AGGRESSIVE;
status->speed=atoi(str[26]);
status->aspd_rate = 1000;
- db->min_thinktime=atoi(str[27]);
- status->adelay = status->amotion=atoi(str[28]);
- if (db->min_thinktime > status->adelay)
- status->adelay = db->min_thinktime;
- if (db->min_thinktime < MIN_MOBTHINKTIME)
- db->min_thinktime = MIN_MOBTHINKTIME;
+ status->adelay = atoi(str[27]);
+ status->amotion = atoi(str[28]);
status->dmotion=atoi(str[29]);
if(battle_config.monster_damage_delay_rate != 100)
status->dmotion = status->dmotion*battle_config.monster_damage_delay_rate/100;
@@ -4012,12 +4006,8 @@ static int mob_read_sqldb(void)
status->mode&=~MD_AGGRESSIVE;
status->speed = TO_INT(26);
status->aspd_rate = 1000;
- db->min_thinktime = TO_INT(27);
- status->adelay = status->amotion = TO_INT(28);
- if (db->min_thinktime > status->adelay)
- status->adelay = db->min_thinktime;
- if (db->min_thinktime < MIN_MOBTHINKTIME)
- db->min_thinktime = MIN_MOBTHINKTIME;
+ status->adelay = TO_INT(27);
+ status->amotion = TO_INT(28);
status->dmotion = TO_INT(29);
if(battle_config.monster_damage_delay_rate != 100)
status->dmotion = status->dmotion*battle_config.monster_damage_delay_rate/100;