summaryrefslogtreecommitdiff
path: root/src/map/clif.c
diff options
context:
space:
mode:
authorshennetsind <ind@henn.et>2013-06-09 00:34:35 -0300
committershennetsind <ind@henn.et>2013-06-09 00:34:35 -0300
commit89a571a3c5d4c9366843a462c40efdebb24d17fe (patch)
treed2b388b44f2e389a676cf7a54b4f6d65d17d2925 /src/map/clif.c
parent9189034a11186f37fba2a603bed656502c87f688 (diff)
downloadhercules-89a571a3c5d4c9366843a462c40efdebb24d17fe.tar.gz
hercules-89a571a3c5d4c9366843a462c40efdebb24d17fe.tar.bz2
hercules-89a571a3c5d4c9366843a462c40efdebb24d17fe.tar.xz
hercules-89a571a3c5d4c9366843a462c40efdebb24d17fe.zip
Fixed Bug #7318
Special Thanks to Beret, malufett, mkbu95~! http://hercules.ws/board/tracker/issue-7318-using-skill-and-talking-with-npc/ Signed-off-by: shennetsind <ind@henn.et>
Diffstat (limited to 'src/map/clif.c')
-rw-r--r--src/map/clif.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/map/clif.c b/src/map/clif.c
index 6e4cae5c6..f808b00ab 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -10747,22 +10747,24 @@ void clif_parse_NpcClicked(int fd,struct map_session_data *sd)
{
struct block_list *bl;
- if(pc_isdead(sd)) {
+ if( pc_isdead(sd) ) {
clif_clearunit_area(&sd->bl,CLR_DEAD);
return;
}
- if ( pc_cant_act2(sd) )
+ if ( pc_cant_act2(sd) || !(bl = iMap->id2bl(RFIFOL(fd,2))) )
return;
-
- bl = iMap->id2bl(RFIFOL(fd,2));
- if (!bl) return;
+
switch (bl->type) {
case BL_MOB:
case BL_PC:
clif->pActionRequest_sub(sd, 0x07, bl->id, iTimer->gettick());
break;
case BL_NPC:
+ if( sd->ud.skilltimer != INVALID_TIMER ) {
+ clif->colormes(fd,COLOR_WHITE,msg_txt(1476));
+ break;
+ }
if( bl->m != -1 )// the user can't click floating npcs directly (hack attempt)
npc_click(sd,(TBL_NPC*)bl);
break;