SLEEP SPELL Level: B7, J23, M7, R22 Cost: 25 mana Target: one monster When: non-combat Delay: one combat round Duration: 7 to 12 hours Effect: Sleep puts the target to sleep. Sleeping monsters sustain more damage when they are hit. If a sleeping mobile is hit it will wake and fight normally. The backstab skill never fails on a sleeping mobile, regardless of the player class attempting the backstab.
Code:
if (!saves_spell(victim, SAVING_SPELL) && GET_LEVEL(victim) < LVL_IMM) {
af.type = SPELL_SLEEP;
af.duration = 4+(GET_LEVEL(ch)>>2);
af.modifier = 0;
af.location = APPLY_NONE;
af.bitvector = AFF_SLEEP;
affect_join(victim, &af, FALSE, FALSE);
if (GET_POS(victim)>POSITION_SLEEPING) {
act("You feel very sleepy ..... zzzzzz",FALSE,victim,0,0,TO_CHAR);
act("$n goes to sleep.",TRUE,victim,0,0,TO_ROOM);
GET_POS(victim)=POSITION_SLEEPING;
}
} else
send_to_char("Nope. Sorry... Try again.....\n\r",ch);
Usage: cast 'sleep' <victim> sing 'sleep' <victim> See also: Backstab
Because the sleep spell has a duration, use the bard song SUGGEST to put guards and other pesky aggro mobs to sleep infinitely.
