Initial Upload
Initial Upload
This commit is contained in:
20
_module/nss/teleport.nss
Normal file
20
_module/nss/teleport.nss
Normal file
@@ -0,0 +1,20 @@
|
||||
void main()
|
||||
{
|
||||
if (GetLocalInt(OBJECT_SELF, "IsDm") == 0)
|
||||
{
|
||||
if (GetLocalInt(OBJECT_SELF, "EJAIL") == TRUE)
|
||||
{
|
||||
FloatingTextStringOnCreature("There is no escape for you, " + GetName(OBJECT_SELF),OBJECT_SELF,FALSE);
|
||||
return;
|
||||
}
|
||||
if (GetLocalInt(GetModule(), "war") == TRUE)
|
||||
{
|
||||
FloatingTextStringOnCreature("Cannot Teleport in time of war",OBJECT_SELF,FALSE);
|
||||
return;
|
||||
}
|
||||
}
|
||||
SetLocalLocation(OBJECT_SELF, "lBack", GetLocation(OBJECT_SELF));
|
||||
AssignCommand(OBJECT_SELF, ClearAllActions());
|
||||
ExecuteScript("teleporteff", OBJECT_SELF);
|
||||
DelayCommand(0.5,AssignCommand(OBJECT_SELF,ActionJumpToLocation(GetLocation(GetLocalObject(OBJECT_SELF, "Dest")))));
|
||||
}
|
||||
Reference in New Issue
Block a user