Jump to content
  • 0
Ichigo

OnNPCKillEvent not work in instances

Question

Hi.
I don't know why, but OnNPCKillEvent doesn't work on instance mobs.
Can someone help me, I'm going crazy.
Thank you.

-	script	instance_coins	-1,{
	end;
OnNPCKillEvent:
	switch(killedrid) {
		case 3450:
		case 3254:
		case 3097:
		case 3096:
		case 3092:
		case 3091:
		case 3000:
		case 3029:
		case 3190:
		case 2942:
		case 2564:
		case 2961:
		case 2959:
		case 2529:
		case 2542:
		case 2476:
		case 2322:
		case 2327:
		case 2194:
		case 2190:
		case 2189:
		case 2131:
		case 2538:
		case 3150:
		case 3758:
		case 1929:
		case 1087:
		case 2022:
		case 1956:
		case 1734:
		case 2109:
		case 2253:
		case 2249:
		case 3073:
		case 3181:
		case 3473:
		case 2319:
		case 1874:
		case 2251:
		case 1832:
		case 3124:
		case 2255:
		case 30006:
		case 30007: goto OnFinInstance; end;
		default: end;
	}
	end;

OnFinInstance:
	.@map$ = strcharinfo(3);
	if((compare(.@map$, "@")) || (.@map$=="skycity")) {
		getitem 50014, 1;
	}
	end;
}

]

Share this post


Link to post
Share on other sites

5 answers to this question

Recommended Posts

  • 0

The monsters of yours instance probably have their own label.

monster "place",60,100,"Poring",1002,1;	// call OnNPCKillEvent on monster dead
monster "place",60,100,"Poring",1002,1,"NPCNAME::OnLabel";	// call OnLabel on monster dead (not OnNPCKillEvent)

 

Share this post


Link to post
Share on other sites
  • 0

Global events like that can't be duplicated for instances.

Also try to assign an event to your mob spawns like capuche mentioned.

Edited by llchrisll

Share this post


Link to post
Share on other sites
  • 0

OKAY.
Thanks for the info.
I guess you have to modify the instance manually.

Share this post


Link to post
Share on other sites
  • 0

rename the event label into OnXXX and assign it to your instance monsters.  (instance_coins::OnXXXX)

else leave the event label empty to have it trigger the global event.

Share this post


Link to post
Share on other sites
  • 0

If you would use a global event but want it only to a affect an instance then it's the same as using an event label for the monsters.

Edited by llchrisll

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.