The fun thing with random numbers, is that they aren't going to be completely random. To increase the "randomness" of it, you can simply increase your scope.
I.E. if you want it to spawn on one number from 1-10, it is going to have more variance than having it spawn from 91-100 in 1-100.
Code:
$random_number = int(rand(100));
if($random_number >= 91) {
quest::spawn(999481,0,0,$x,$y,$z);
}
As Joligario said, you can just fill in $x, $y, $z (and $h if you want it to face the same way the last mob was dying).
Also, if you have a list of monsters you want to spawn, you can use this little trick to pull one out.
Code:
sub EVENT_DEATH {
@MobList = (999481, 999483, 999488); # make an array of your mob numbers here.
$MobToSpawn = $MobList [rand @MobList]; # Should pick out one mob through the length of the array
$random_number = int(rand(100));
if($random_number >= 91) {
quest::spawn($MobToSpawn, 0, 0, $x, $y, $h);
}
}
This should work, have not tested it though.