diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-09-14 13:46:14 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-09-14 13:46:14 +0000 |
commit | 4be12e4c23f2a73543fa60ff3e0e0f4235a49ff0 (patch) | |
tree | 6f8c93989fac5b609363d112e91213387607e478 /src/map/mob.c | |
parent | dca95417da6587e2bc8916cbc749b28430e82b84 (diff) | |
download | hercules-4be12e4c23f2a73543fa60ff3e0e0f4235a49ff0.tar.gz hercules-4be12e4c23f2a73543fa60ff3e0e0f4235a49ff0.tar.bz2 hercules-4be12e4c23f2a73543fa60ff3e0e0f4235a49ff0.tar.xz hercules-4be12e4c23f2a73543fa60ff3e0e0f4235a49ff0.zip |
- Corrected Smokie's pet script to use petskillbonus instead of "bonus"
- Added constant map_flag_gvg2 which tags gvg maps independently of whether woe is on or off.
- battle_calc_gvg_damage will be invoked in gvg maps regardless of woe time.
- NPC_MENTALBREAKER now zaps matk*lv SP based on observations by Tharis.
- md->class_ will be changed on mob-class-change to fix all class-change related bugs. On respawn, the spawn data will be used to revert to the original class.
- Improved the pet skillbonus timer for "eternal bonuses" cases where the bonus delay is 0.
- Adjusted gvg long damage rate to 80%, magic damage rate to 60%
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@8748 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/mob.c')
-rw-r--r-- | src/map/mob.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/map/mob.c b/src/map/mob.c index ca12ba0eb..6742c204a 100644 --- a/src/map/mob.c +++ b/src/map/mob.c @@ -632,11 +632,13 @@ int mob_spawn (struct mob_data *md) md->last_thinktime = tick -MIN_MOBTHINKTIME; if (md->bl.prev != NULL) unit_remove_map(&md->bl,2); - else if (md->vd->class_ != md->class_) { + else + if (md->spawn && md->class_ != md->spawn->class_) + { + md->class_ = md->spawn->class_; status_set_viewdata(&md->bl, md->class_); md->db = mob_db(md->class_); - if (md->spawn) - memcpy(md->name,md->spawn->name,NAME_LENGTH); + memcpy(md->name,md->spawn->name,NAME_LENGTH); } if (md->spawn) { //Respawn data @@ -2286,6 +2288,7 @@ int mob_class_change (struct mob_data *md, int class_) return 0; //Clones hp_rate = md->status.hp*100/md->status.max_hp; + md->class_ = class_; md->db = mob_db(class_); if (battle_config.override_mob_names==1) memcpy(md->name,md->db->name,NAME_LENGTH-1); |