Enter restriction
#1

How to restrict player to enter house if it is not his own?
What i am using now is doing vice versa and i don't know why.

I want to check if houseownerid is the same as playerid(from table accounts)
so i am using the same variables
is there other way i can do it?
PHP код:
        else if(IsPlayerInRangeOfPoint(playerid2.0HouseInfo[hid][XEnt],HouseInfo[hid][YEnt],HouseInfo[hid][ZEnt])) //enter house!
        
{
            if((
pinfo[playerid][ID] != HouseInfo[hid][HOwnerID]) && (HouseInfo[hid][HOwned]) == 1) return SendClientMessage(playerid, -1""COL_RED"SERVER"COL_WHITE":You cant enter the house since it's not yours!");
            
EnterHouse(playerid,hid);
        } 
now with that way it doesn't allow me even if i am the owner of the house
Reply


Messages In This Thread
Enter restriction - by vassilis - 06.12.2015, 12:51
Re: Enter restriction - by Sanady - 06.12.2015, 12:58
Re: Enter restriction - by SilverStand - 06.12.2015, 13:04
Re: Enter restriction - by PrO.GameR - 06.12.2015, 13:05
Re: Enter restriction - by vassilis - 06.12.2015, 13:26
Re: Enter restriction - by jlalt - 06.12.2015, 13:37
Re: Enter restriction - by vassilis - 06.12.2015, 13:48
Re: Enter restriction - by vassilis - 06.12.2015, 16:35

Forum Jump:


Users browsing this thread: 2 Guest(s)