Aschbourne_PRC8/_module/nss/class_only_1.nss
GetOffMyYarn 7f75e229f9 Adds and Changes
Added missing crafting maps, removed unnecessary maps, changed a few miscellaneous things.
2024-09-14 13:52:39 -04:00

24 lines
751 B
Plaintext

// Place in the OnAreaTransitionClick event for the <span class="highlight">door</span>
void main()
{
object oPC = GetClickingObject();
object oJump = GetTransitionTarget(OBJECT_SELF);
int nPCClass1 = GetClassByPosition(1, oPC);
int nPCClass2 = GetClassByPosition(2, oPC);
int nPCClass3 = GetClassByPosition(3, oPC);
int nCheck1 = CLASS_TYPE_ROGUE;
int nCheck2 = CLASS_TYPE_ASSASSIN;
if (!GetIsPC(oPC))
{
return;
}
else if ((nPCClass1 == nCheck1) || (nPCClass2 == nCheck1) || (nPCClass3 == nCheck1) || (nPCClass1 == nCheck2) || (nPCClass2 == nCheck2) ||(nPCClass3 == nCheck2))
{
AssignCommand(oPC, JumpToObject(oJump));
}
else
{
FloatingTextStringOnCreature("Only Rogues or Assassins may pass this way.", oPC);
}
}