Initial upload
Initial upload. PRC8 has been added. Module compiles, PRC's default AI & treasure scripts have been integrated. Started work on top hak for SLA / Ability / Scripting modifications.
This commit is contained in:
82
_module/nss/jw_cryptarea_exi.nss
Normal file
82
_module/nss/jw_cryptarea_exi.nss
Normal file
@@ -0,0 +1,82 @@
|
||||
void main()
|
||||
{
|
||||
{
|
||||
object oObject = GetFirstObjectInArea();
|
||||
int nPCinArea=FALSE;
|
||||
location lLoc;
|
||||
object oItem;
|
||||
|
||||
|
||||
|
||||
while (GetIsObjectValid(oObject))
|
||||
{
|
||||
if (GetIsPC(oObject))
|
||||
{
|
||||
nPCinArea = TRUE;
|
||||
}
|
||||
oObject=GetNextObjectInArea();
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (nPCinArea != TRUE)
|
||||
{
|
||||
|
||||
// close and lock door
|
||||
object oDoor=GetObjectByTag("jw_door_down");
|
||||
AssignCommand(oDoor,ActionCloseDoor(oDoor));
|
||||
AssignCommand(oDoor,SetLocked(oDoor,TRUE));
|
||||
|
||||
object oEnc=GetObjectByTag("guardainskels");
|
||||
SetEncounterActive(1,oEnc);
|
||||
|
||||
//// make new lever
|
||||
DelayCommand(5.0,SignalEvent(GetObjectByTag("jw_lion"),EventUserDefined(50)));
|
||||
|
||||
//// ensure lever "triggered" int is 1
|
||||
|
||||
DelayCommand(7.0,SetLocalInt(GetObjectByTag("jw_trap_lever"),"triggered",1));
|
||||
|
||||
|
||||
|
||||
oObject = GetFirstObjectInArea();
|
||||
while (GetIsObjectValid(oObject) == TRUE)
|
||||
{
|
||||
//if (GetIsEncounterCreature(oObject)&&!GetPlotFlag(oObject))
|
||||
// {
|
||||
// DestroyObject(oObject);
|
||||
// }
|
||||
// if (GetObjectType(oObject)==OBJECT_TYPE_TRIGGER)
|
||||
// {
|
||||
// SetEncounterActive(TRUE,oObject);
|
||||
// }
|
||||
if (GetTag(oObject) == "jw_guardskel")
|
||||
{
|
||||
DestroyObject(oObject);
|
||||
}
|
||||
|
||||
if (GetTag(oObject) == "BodyBag")
|
||||
{
|
||||
|
||||
oItem = GetFirstItemInInventory(oObject);
|
||||
while (GetIsObjectValid(oItem) == TRUE)
|
||||
{
|
||||
|
||||
|
||||
DestroyObject(oItem);
|
||||
|
||||
oItem=GetNextItemInInventory(oObject);
|
||||
}
|
||||
|
||||
SetPlotFlag(oObject,FALSE);
|
||||
|
||||
DestroyObject(oObject);
|
||||
}
|
||||
oObject=GetNextObjectInArea();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user