Shargast_PRC8/_module/Chapter 2/nss/arearestrictlvl5.nss
Jaysyn904 66a0a3e043 Initial commit
Initial commit.
2024-08-03 14:13:18 -04:00

21 lines
724 B
Plaintext

// Script Name: Level Restricted Area
// Purpose: Restrict access to areas by PC level
// Placement: Place in OnAreaTransitionClick on Doors
// Author: Qobra, with help from Adam_wasserman & Janus-SOK
// Created: 22 July 2002
// NOTE: You can change the level restriction by setting the 2 vaules (5 & 10)
// to anything you like within range 1-20.
void main() {
object oClicker = GetClickingObject();
object oTarget = GetTransitionTarget( OBJECT_SELF );
location lLoc = GetLocation( oTarget );
if ((GetHitDice(oClicker) >= 5) && (GetHitDice(oClicker) <=10)) {
AssignCommand( oClicker, JumpToLocation( lLoc ) );
} else {
SpeakString( "You have not reached the 5th horizon of life and cannot enter this area " + "." );
}
}