House
#3

PHP код:
if(newkeys == KEY_SECONDARY_ATTACK )
    {
        for(new 
iMAX_KUCAi++)
        {
            if(
IsPlayerInRangeOfPoint(playerid3.0KucaInfo[i][kUlazX], KucaInfo[i][kUlazY], KucaInfo[i][kUlazZ]))
            {
                if(
PlayerInfo[playerid][PosedovanjeKuce] == || KucaInfo[i][kZatvoreno] == 0)
                   {
                    
SetPlayerVirtualWorld(playeridKucaInfo[i][kVW]);
                    
SetPlayerInterior(playeridKucaInfo[i][kInt]);
                     
SetPlayerPos(playeridKucaInfo[i][kIzlazX], KucaInfo[i][kIzlazY], KucaInfo[i][kIzlazZ]);
                }
                else return 
ERROR(playerid"Kuca je zakljucana!");
            }
            if(
IsPlayerInRangeOfPoint(playerid3.0KucaInfo[i][kIzlazX], KucaInfo[i][kIzlazY], KucaInfo[i][kIzlazZ]) && GetPlayerVirtualWorld(playerid) == KucaInfo[i][kVW])
            {
                
SetPlayerInterior(playerid0);
                
SetPlayerVirtualWorld(playerid0);
                
SetPlayerPos(playeridKucaInfo[i][kUlazX], KucaInfo[i][kUlazY], KucaInfo[i][kUlazZ]);
            }
        }
    } 
There is whole code. It goes under OnPlayerKeyStateChange. But problem is that i can exit house only if it is ID 0. If i create house with ID 1 i can't exit it ID 2 also and so on..
Reply


Messages In This Thread
House - by Micko123 - 28.08.2016, 06:52
Re: House - by Shinja - 28.08.2016, 12:36
Re: House - by Micko123 - 28.08.2016, 12:39
Re: House - by Shinja - 28.08.2016, 12:43
Re: House - by SyS - 28.08.2016, 12:53
Re: House - by Micko123 - 28.08.2016, 12:56
Re: House - by Shinja - 28.08.2016, 13:00
Re: House - by Micko123 - 28.08.2016, 13:06
Re: House - by PrO.GameR - 28.08.2016, 16:32
Re: House - by Micko123 - 28.08.2016, 19:42

Forum Jump:


Users browsing this thread: 1 Guest(s)