diff options
Diffstat (limited to 'src/map')
-rw-r--r-- | src/map/atcommand.c | 14 | ||||
-rw-r--r-- | src/map/pc.c | 1 | ||||
-rw-r--r-- | src/map/pet.c | 5 | ||||
-rw-r--r-- | src/map/skill.c | 2 |
4 files changed, 10 insertions, 12 deletions
diff --git a/src/map/atcommand.c b/src/map/atcommand.c index 715fa84ab..347f92d3e 100644 --- a/src/map/atcommand.c +++ b/src/map/atcommand.c @@ -9523,16 +9523,12 @@ int atcommand_homlevel( return 1 ;
level = atoi(message);
- if ( ( level + sd->homunculus.level ) > MAX_LEVEL )
- level = MAX_LEVEL - sd->homunculus.level ;
- if (level >= 1) {
- for (i = 1; i <= level ; i++){
- sd->homunculus.exp += sd->hd->exp_next;
- merc_hom_levelup(sd->hd) ;
- }
- clif_misceffect2(&sd->hd->bl,568) ;
- }
+ for (i = 1; i <= level && sd->hd->exp_next; i++){
+ sd->homunculus.exp += sd->hd->exp_next;
+ merc_hom_levelup(sd->hd);
+ }
+ clif_misceffect2(&sd->hd->bl,568);
return 0;
}
diff --git a/src/map/pc.c b/src/map/pc.c index e56e84ce3..d2556b0dc 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -4758,6 +4758,7 @@ int pc_dead(struct map_session_data *sd,struct block_list *src) if(sd->status.hom_id > 0 && sd->hd) //orn { sd->homunculus.vaporize = 1; + clif_hominfo(sd,0); merc_stop_walking(sd->hd, 1) ; merc_stop_attack(sd->hd) ; merc_hom_delete(sd->hd,0); diff --git a/src/map/pet.c b/src/map/pet.c index 2f5e210ad..317145cb7 100644 --- a/src/map/pet.c +++ b/src/map/pet.c @@ -1034,8 +1034,9 @@ static int pet_ai_sub_hard_lootsearch(struct block_list *bl,va_list ap) sd_id = fitem->first_get_id;
- if(bl->m == pd->bl.m && unit_can_reach_bl(&pd->bl,bl, pd->db->range2, 1, NULL, NULL)
- && rand()%1000<1000/(++(*itc)))
+ if(bl->m == pd->bl.m && (!sd_id || sd_id == pd->msd->bl.id) &&
+ unit_can_reach_bl(&pd->bl,bl, pd->db->range2, 1, NULL, NULL) &&
+ rand()%1000<1000/(++(*itc)))
pd->target_id=bl->id;
return 0;
}
diff --git a/src/map/skill.c b/src/map/skill.c index e06b5f2ef..92af54cb9 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -6212,7 +6212,7 @@ int skill_castend_pos2 (struct block_list *src, int x, int y, int skillid, int s struct mob_data *md; // Correct info, don't change any of this! [celest] - md = mob_once_spawn_sub(src, src->m, -1, -1, sd->status.name,class_,""); + md = mob_once_spawn_sub(src, src->m, x, y, sd->status.name,class_,""); if (md) { md->master_id = src->id; md->special_state.ai = skillid==AM_SPHEREMINE?2:3; |