// This script causes monsters to drop a red potion when they are killed.
function onMonsterDeath(monster, killer) {
// Check if the killer is a player.
if (killer.isPlayer()) {
// Drop a red potion.
monster.dropItem(501, 1);
}
}
module.exports = {
onMonsterDeath: onMonsterDeath
};
Question
GubA
// This script causes monsters to drop a red potion when they are killed. function onMonsterDeath(monster, killer) { // Check if the killer is a player. if (killer.isPlayer()) { // Drop a red potion. monster.dropItem(501, 1); } } module.exports = { onMonsterDeath: onMonsterDeath };
Thank you to help me
Link to comment
Share on other sites
4 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.