47 lines
1.0 KiB
Plaintext
47 lines
1.0 KiB
Plaintext
//Put this script OnEnter
|
|
|
|
#include "prc_class_const"
|
|
|
|
void main()
|
|
{
|
|
object oPC = GetEnteringObject();
|
|
object oTarget;
|
|
|
|
location lTarget;
|
|
|
|
if (!GetIsPC(oPC)) return;
|
|
|
|
int DoOnce = GetLocalInt(oPC, GetTag(OBJECT_SELF));
|
|
|
|
if (DoOnce==TRUE) return;
|
|
|
|
SetLocalInt(oPC, GetTag(OBJECT_SELF), TRUE);
|
|
|
|
int nClass;
|
|
|
|
nClass = GetLevelByClass(CLASS_TYPE_ROGUE, oPC)
|
|
+GetLevelByClass(CLASS_TYPE_NINJA, oPC)
|
|
+GetLevelByClass(CLASS_TYPE_SCOUT, oPC)
|
|
+GetLevelByClass(CLASS_TYPE_BEGUILER, oPC)
|
|
+GetLevelByClass(CLASS_TYPE_FACTOTUM, oPC)
|
|
+GetLevelByClass(CLASS_TYPE_PSYCHIC_ROGUE, oPC);
|
|
|
|
if (nClass >= 11)
|
|
{
|
|
if (GetIsSkillSuccessful(oPC, SKILL_SEARCH, 88))
|
|
{
|
|
|
|
oTarget = GetWaypointByTag("crackway1");
|
|
|
|
lTarget = GetLocation(oTarget);
|
|
|
|
if (GetAreaFromLocation(lTarget)==OBJECT_INVALID) return;
|
|
|
|
AssignCommand(oPC, ClearAllActions());
|
|
|
|
AssignCommand(oPC, ActionJumpToLocation(lTarget));
|
|
|
|
DelayCommand(1.0, FloatingTextStringOnCreature("You found the magical entrance to a small cave!", oPC));
|
|
}
|
|
}
|
|
} |