Lockdoor from inside
#1

I wanna lock my house from the inside(interior) , but when im trying to do this its says im not near my house, Can someone find the problem.

Already thanks for help!

pawn Код:
CMD:lockdoor(playerid, params[], help)
{
        #pragma unused params
        #pragma unused help
        new h = Player[playerid][Houseid];
        if(h == 999) return SCM(playerid,-1,"{FF8000}[House]:{FFFFFF} You don't have a house.");
        if(House[h][Lock] == 1) return SCM(playerid,-1,"{FF8000}[House]:{FFFFFF} House is already locked.");
        if(!IsPlayerInRangeOfPoint(playerid,3.0,House[h][EnterX],House[h][EnterY],House[h][EnterZ])) return SCM(playerid,-1,"{FF8000}[House]:{FFFFFF} You are not near your house");
        if(!IsPlayerInRangeOfPoint(playerid,3.0,House[h][ExitX],House[h][ExitY],House[h][ExitZ])) return SCM(playerid,-1,"{FF8000}[House]:{FFFFFF} You are not near your house");
        Choose[playerid] = 1;
        House[h][Lock] = 1;
        SendClientMessage(playerid,-1,"{FF8000}[House]:{FFFFFF} Door has been locked!");
        return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)