|
@@ -17717,13 +17717,11 @@ BUILDIN_FUNC(npcskill)
|
|
*/
|
|
*/
|
|
BUILDIN_FUNC(consumeitem)
|
|
BUILDIN_FUNC(consumeitem)
|
|
{
|
|
{
|
|
- TBL_NPC *nd;
|
|
|
|
TBL_PC *sd;
|
|
TBL_PC *sd;
|
|
struct script_data *data;
|
|
struct script_data *data;
|
|
struct item_data *item_data;
|
|
struct item_data *item_data;
|
|
|
|
|
|
nullpo_retr( 1, ( sd = script_rid2sd( st ) ) );
|
|
nullpo_retr( 1, ( sd = script_rid2sd( st ) ) );
|
|
- nullpo_retr( 1, ( nd = (TBL_NPC *)map_id2bl( sd->npc_id ) ) );
|
|
|
|
|
|
|
|
data = script_getdata( st, 2 );
|
|
data = script_getdata( st, 2 );
|
|
get_val( st, data );
|
|
get_val( st, data );
|
|
@@ -17747,7 +17745,7 @@ BUILDIN_FUNC(consumeitem)
|
|
return SCRIPT_CMD_FAILURE;
|
|
return SCRIPT_CMD_FAILURE;
|
|
}
|
|
}
|
|
|
|
|
|
- run_script( item_data->script, 0, sd->bl.id, nd->bl.id );
|
|
|
|
|
|
+ run_script( item_data->script, 0, sd->bl.id, 0 );
|
|
return SCRIPT_CMD_SUCCESS;
|
|
return SCRIPT_CMD_SUCCESS;
|
|
}
|
|
}
|
|
|
|
|