I think you're looking for $npc->Kill().
Example:
Code:
sub EVENT_SAY {
if ($text=~/kill yourself/i) {
quest::say("As you wish, oh great one");
$npc->Kill();
}
}
Found here:
QuestObjects (Wiki).
Something interesting about the quest system is that, basically, the quest:: commands are wrappers for the commands listed in the above Wiki article. For example, you can make an NPC say something using $npc->Say(), although that one in particular takes an additional option (format).