diff options
author | Matheus Macabu <mkbu95@gmail.com> | 2013-07-04 14:35:24 -0300 |
---|---|---|
committer | Matheus Macabu <mkbu95@gmail.com> | 2013-07-04 14:35:24 -0300 |
commit | 5ea7b8b9e172ed16fda6ee5a051ae0dbb767b4ac (patch) | |
tree | 1a622268c8f8f148de045c408b6e94f4b4592b93 /src/map/pc.c | |
parent | 5479f9631f8579d03fbfd14d8a49c7976226a156 (diff) | |
parent | 6ced266cc8d41ce6a3c5323c22f295e37b3f5684 (diff) | |
download | hercules-5ea7b8b9e172ed16fda6ee5a051ae0dbb767b4ac.tar.gz hercules-5ea7b8b9e172ed16fda6ee5a051ae0dbb767b4ac.tar.bz2 hercules-5ea7b8b9e172ed16fda6ee5a051ae0dbb767b4ac.tar.xz hercules-5ea7b8b9e172ed16fda6ee5a051ae0dbb767b4ac.zip |
Merge branch 'master' of https://github.com/HerculesWS/Hercules
Diffstat (limited to 'src/map/pc.c')
-rw-r--r-- | src/map/pc.c | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/src/map/pc.c b/src/map/pc.c index 3ddae9222..f2c0ddc37 100644 --- a/src/map/pc.c +++ b/src/map/pc.c @@ -861,11 +861,15 @@ int pc_isequip(struct map_session_data *sd,int n) if(item == NULL) return 0; - if(item->elv && sd->status.base_level < (unsigned int)item->elv) + if(item->elv && sd->status.base_level < (unsigned int)item->elv){ + clif->msg(sd, 0x6ED); return 0; + } #ifdef RENEWAL - if(item->elvmax && sd->status.base_level > (unsigned int)item->elvmax) + if(item->elvmax && sd->status.base_level > (unsigned int)item->elvmax){ + clif->msg(sd, 0x6ED); return 0; + } #endif if(item->sex != 2 && sd->status.sex != item->sex) return 0; @@ -4113,7 +4117,7 @@ int pc_isUseitem(struct map_session_data *sd,int n) return 0; if( (item->item_usage.flag&NOUSE_SITTING) && (pc_issit(sd) == 1) && (pc->get_group_level(sd) < item->item_usage.override) ) { - clif->msgtable(sd->fd,664); + clif->msgtable(sd->fd,0x297); //clif->colormes(sd->fd,COLOR_WHITE,msg_txt(1474)); return 0; // You cannot use this item while sitting. } @@ -4218,12 +4222,16 @@ int pc_isUseitem(struct map_session_data *sd,int n) if(item->sex != 2 && sd->status.sex != item->sex) return 0; //Required level check - if(item->elv && sd->status.base_level < (unsigned int)item->elv) + if(item->elv && sd->status.base_level < (unsigned int)item->elv){ + clif->msg(sd, 0x6EE); return 0; + } #ifdef RENEWAL - if(item->elvmax && sd->status.base_level > (unsigned int)item->elvmax) + if(item->elvmax && sd->status.base_level > (unsigned int)item->elvmax){ + clif->msg(sd, 0x6EE); return 0; + } #endif //Not equipable by class. [Skotlex] @@ -4775,6 +4783,7 @@ int pc_setpos(struct map_session_data* sd, unsigned short mapindex, int x, int y sd->state.changemap = (sd->mapindex != mapindex); sd->state.warping = 1; + sd->state.workinprogress = 0; if( sd->state.changemap ) { // Misc map-changing settings int i; sd->state.pmap = sd->bl.m; @@ -6607,8 +6616,10 @@ void pc_damage(struct map_session_data *sd,struct block_list *src,unsigned int h skill->sit(sd,0); } - if( sd->progressbar.npc_id ) + if( sd->progressbar.npc_id ){ clif->progressbar_abort(sd); + sd->state.workinprogress = 0; + } if( sd->status.pet_id > 0 && sd->pd && battle_config.pet_damage_support ) pet_target_check(sd,src,1); |