SA-MP Forums Archive
way to check for any interior? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: way to check for any interior? (/showthread.php?tid=150646)



way to check for any interior? - iggy1 - 27.05.2010

I know u can check for a single interior, but is there a way i can check if a player is in any interior? so i can disable certain commands when a player is in any interior?
Many thanks in advance.


Re: way to check for any interior? - ViruZZzZ_ChiLLL - 27.05.2010

pawn Код:
new IsPlayerInAnInterior = GetPlayerInterior(playerid);
if(IsPlayerInAnInterior == 0) // if player isn't in an interior
if(IsPlayerInAnInterior == 1) // if player is in a interior



Re: way to check for any interior? - [HiC]TheKiller - 27.05.2010

Quote:
Originally Posted by ViruZZzZ_ChiLLL
pawn Код:
new IsPlayerInAnInterior = GetPlayerInterior(playerid);
if(IsPlayerInAnInterior == 0) // if player isn't in an interior
if(IsPlayerInAnInterior == 1) // if player is in a interior
AHEM

pawn Код:
new IsPlayerInAnInterior = GetPlayerInterior(playerid);
if(IsPlayerInAnInterior == 0) // if player isn't in an interior
if(IsPlayerInAnInterior != 0) // if player is in a interior



Re: way to check for any interior? - iggy1 - 27.05.2010

Quote:
Originally Posted by ViruZZzZ_ChiLLL
pawn Код:
new IsPlayerInAnInterior = GetPlayerInterior(playerid);
if(IsPlayerInAnInterior == 0) // if player isn't in an interior
if(IsPlayerInAnInterior == 1) // if player is in a interior
Nice1 m8 works a treat

Edit: I changed to != anyway thanks again