Jump to content
  • 0

Broadcast when a special monster is killed


Yuka

Question


  • Group:  Members
  • Topic Count:  100
  • Topics Per Day:  0.03
  • Content Count:  333
  • Reputation:   7
  • Joined:  03/01/14
  • Last Seen:  

I have a special mob spawning every 6 hours and I want to broadcast that it has been killed when it dies. Now in mob_db there is a <event label> field at the end, I guess I have to use this somehow, but I really cannot figure out how. :/

 

My google search gives me the feeling I have to create an NPC instead? (And check EVERY monster that a player kills? :/)

Link to comment
Share on other sites

3 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  38
  • Topics Per Day:  0.01
  • Content Count:  949
  • Reputation:   174
  • Joined:  06/12/12
  • Last Seen:  

-	script	SpecialMonster	-1,{

OnThisMobDeath:
	announce strcharinfo(0)+" just killed this monster!",0;
	end;

}

The event label format is "NPCName::OnEventLabel";

 

Now, for the script above to work, you must change the event label of your special monster into..

 

...,"SpecialMonster::OnThisMobDeath";
  • Upvote 2
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  100
  • Topics Per Day:  0.03
  • Content Count:  333
  • Reputation:   7
  • Joined:  03/01/14
  • Last Seen:  

-	script	SpecialMonster	-1,{

OnThisMobDeath:
	announce strcharinfo(0)+" just killed this monster!",0;
	end;

}

The event label format is "NPCName::OnEventLabel";

 

Now, for the script above to work, you must change the event label of your special monster into..

...,"SpecialMonster::OnThisMobDeath";

 

Ahh, okay, I got this.

OnThisMobDeath is just a label I can call somewhat else?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  38
  • Topics Per Day:  0.01
  • Content Count:  949
  • Reputation:   174
  • Joined:  06/12/12
  • Last Seen:  

Yep! As long as its named properly, you shouldnt encounter any problem

Link to comment
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...