summaryrefslogtreecommitdiff
path: root/src/map/npc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/npc.c')
-rw-r--r--src/map/npc.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/map/npc.c b/src/map/npc.c
index d5c7c021a..97b41e033 100644
--- a/src/map/npc.c
+++ b/src/map/npc.c
@@ -814,14 +814,13 @@ int npc_event(struct map_session_data* sd, const char* eventname, int ontouch)
int npc_touch_areanpc_sub(struct block_list *bl, va_list ap)
{
struct map_session_data *sd;
- int pc_id,npc_id;
+ int pc_id;
char *name;
nullpo_ret(bl);
nullpo_ret((sd = map_id2sd(bl->id)));
pc_id = va_arg(ap,int);
- npc_id = va_arg(ap,int);
name = va_arg(ap,char*);
if( pc_ishiding(sd) )
@@ -854,7 +853,7 @@ int npc_touchnext_areanpc(struct map_session_data* sd, bool leavemap)
nd->touching_id = sd->touching_id = 0;
snprintf(name, ARRAYLENGTH(name), "%s::%s", nd->exname, script_config.ontouch_name);
- map_forcountinarea(npc_touch_areanpc_sub,nd->bl.m,nd->bl.x - xs,nd->bl.y - ys,nd->bl.x + xs,nd->bl.y + ys,1,BL_PC,sd->bl.id,nd->bl.id,name);
+ map_forcountinarea(npc_touch_areanpc_sub,nd->bl.m,nd->bl.x - xs,nd->bl.y - ys,nd->bl.x + xs,nd->bl.y + ys,1,BL_PC,sd->bl.id,name);
}
return 0;
}
@@ -1649,11 +1648,10 @@ int npc_selllist(struct map_session_data* sd, int n, unsigned short* item_list)
// delete items
for( i = 0; i < n; i++ )
{
- int nameid, amount, idx;
+ int amount, idx;
idx = item_list[i*2]-2;
amount = item_list[i*2+1];
- nameid = sd->status.inventory[idx].nameid;
if( sd->inventory_data[idx]->type == IT_PETEGG && sd->status.inventory[idx].card[0] == CARD0_PET )
{