HoS_PRC8/_mod/_module/nss/guard_c_showm2.nss
Jaysyn904 04165202c0 Initial upload
Initial upload
2024-11-25 19:36:07 -05:00

35 lines
872 B
Plaintext

// guard_c_showm1 - Show Guard point 2?
int StartingConditional()
{
object oMod=GetModule();
object oPC=GetPCSpeaker();
string sID=GetLocalString(oPC,"sTeamID");
location lLoc=GetLocalLocation(oMod,"lGuard2_"+sID);
object oArea=GetAreaFromLocation(lLoc);
float fX;
float fY;
float fZ;
vector vPos=GetPositionFromLocation(lLoc);
int nX;
int nY;
int nZ;
string sToken;
int nNum=2;
if (oArea!=OBJECT_INVALID)
{ // area exists
fX=vPos.x;
fY=vPos.y;
fZ=vPos.z;
nX=FloatToInt(fX);
nY=FloatToInt(fY);
nZ=FloatToInt(fZ);
sToken=GetName(oArea)+"("+IntToString(nX)+","+IntToString(nY)+","+IntToString(nZ)+")";
SetCustomToken(88000+nNum,"Currently assigned to: "+sToken);
} // area exists
else
{
SetCustomToken(88000+nNum," ");
}
return TRUE;
}