Hmm i have that line., I followed the main topic first post.
here's what i got on my npc.c
/**
MVP Tomb System. [malufett]
**/
static int totalnpctomb = 0;
int npc_mvp_tomb(struct mob_data *md, struct map_session_data *sd){
char w1[256], w2[256], w3[256];
struct npc_data *nd = NULL;
int count;
nullpo_ret(md);
if(sd){
struct mob_data *boss_md = map_getmob_boss(sd->bl.m); // Search for Boss on this Map and ignore summoned Boss
if( boss_md != NULL &&
boss_md->bl.prev != NULL &&
md->bl.id == boss_md->bl.id)
{
int x = boss_md->bl.x, y = boss_md->bl.y;
sprintf(w2, "Tomb#%d", boss_md->class_);
sprintf(w1, "%s, %d, %d, 1", map[boss_md->bl.m].name, x , y);
sprintf(w3, "n%d::OnMyMobDead", totalnpctomb);
sprintf(w2, "%s::n%d", w2, count=totalnpctomb++);
safestrncpy(md->npc_event, w3, sizeof(md->npc_event));
npc_parse_duplicate(w1,"duplicate(tomb_stone)",w2,"565", "-", "-", "MVP_TOMB"+boss_md->class_);
if(md->spawn_timer != INVALID_TIMER){
const struct TimerData * timer_data = get_timer(md->spawn_timer);
pc_setreg(sd, add_str("@spawn_delay"), DIFF_TICK(timer_data->tick, gettick()) + 60);
}
npc_event(sd,md->npc_event,0);
safestrncpy(md->npc_event, "", sizeof(md->npc_event));
if(SCRIPT_MAX_ARRAYSIZE > totalnpctomb) totalnpctomb = 0;
}
}else{
sprintf(w1, "n%d", md->target_id);
nd = npc_name2id(w1);
if (nd != NULL){
npc_unload(nd);
md->target_id = 0;
totalnpctomb--;
}
}
return count;
}