[Pomoc]Sistemi

Započeo Fantom_, Mart 17, 2013, 16:21:32 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:CLRP
Detaljan opis problema:Nerade mi komande za stan i vikendicu neznam zasto!Molim vas za pomoc!Hitno je!
Dio skripte:
Ovo je STAN CMD:
COMMAND:stan(playerid,params[])
{
    new string[230];
    new x_job[220];
    new idx;
    new playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, sizeof(playername));
    new gouse = PlayerInfo[playerid][pPstankey];
    if(PlayerInfo[playerid][pPstankey] == 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], false) == 0) {
        SendClientMessage( playerid, WHITE, "Ne posjedujes Stan!" );
        return 1;
    }

    x_job = strtok(params, idx);
    if(!strlen(x_job) && PlayerInfo[playerid][pPstankey] != 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], true) == 0) {
        format( string, sizeof( string ), " %s | Cijena: %d (ID Stana: %d) Vlasnik: %s", Stan[PlayerInfo[playerid][pPstankey]][hOpis],Stan[PlayerInfo[playerid][pPstankey]][HousePrice], PlayerInfo[playerid][pPstankey], Stan[PlayerInfo[playerid][pPstankey]][hOwner]);
        SendClientMessage( playerid, 0x366936FF, string);
        SendClientMessage(playerid, 0x5C865CFF,"{168BFF}POMOC:{838361} /stan [ime]");
        SendClientMessage(playerid, 0x6D936DFF,"Dostupno: prodaj, informacije, preuredi");
        SendClientMessage(playerid, 0x7EA07EFF,"Dostupno: otkljucaj, zakljucaj");
        return 1;
    }
    if(strcmp(x_job,"prodaj",true) == 0) {
        new sendername[MAX_PLAYER_NAME], stringt[64];
        if(PlayerInfo[playerid][pPstankey] == 255) {
            SendClientMessage(playerid, COLOR_WHITE, "Ne posjedujes stan.");
            return 1;
        }

        if(PlayerInfo[playerid][pPstankey] != 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], true) == 0) {
            new id;
            new stan = PlayerInfo[playerid][pPstankey];
            Stan[stan][hOwned] = 0;
            Stan[stan][LockStatus] = 1;
            GetPlayerName(playerid, sendername, sizeof(sendername));
            strmid(Stan[stan][hOwner], "Niko", 0, strlen("Niko"), 255);
            ConsumingMoney[playerid] = 1;
            Stan[stan][hOwned] = 0;
            PlayerInfo[playerid][pSpawnChange] = 1;
            GivePlayerCash(playerid,Stan[stan][HousePrice]);
            PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
            format( stringt, sizeof( stringt ), "~y~Prodali ste stan za: ~g~%d$", Stan[stan][HousePrice]);
            GameTextForPlayer(playerid, stringt, 5000, 1);
            PlayerInfo[playerid][pPstankey] = 255;
            if(PlayerInfo[playerid][pLocal] == stan) {
                SetPlayerInterior(playerid,0);
                SetPlayerPos(playerid,Stan[stan][sExteriorX],Stan[stan][sExteriorY],Stan[stan][sExteriorZ]);
                PlayerInfo[playerid][pInt] = 0;
            }
            SaveStan(stan);
            OnPropTextdrawUpdate(4,id);
            SacuvajIgraca(playerid);
            return 1;

        }

    }
    else if(strcmp(x_job,"otkljucaj",true) == 0) {
#pragma unused params

        if( PlayerInfo[playerid][pPstankey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Stan[gouse][sExteriorX], Stan[gouse][sExteriorY], Stan[gouse][sExteriorZ])) {
            if(Stan[gouse][LockStatus] == 1) {
                Stan[gouse][LockStatus] = 0;
                SaveStan(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Stan otkljucan." );
            }
        }
        return 1;
    }
    else if(strcmp(x_job,"zakljucaj",true) == 0) {
#pragma unused params

        if( PlayerInfo[playerid][pPstankey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Stan[gouse][sExteriorX], Stan[gouse][sExteriorY], Stan[gouse][sExteriorZ])) {
            if(Stan[gouse][LockStatus] == 0) {
                Stan[gouse][LockStatus] = 1;
                SaveStan(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Stan zakljucan." );
            }
        }
        return 1;
    }
    return 1;
}


ovo je VIKENDICA CMD:

COMMAND:vikendica(playerid,params[])
{
    new string[340];
    new x_job[320];
    new idx;
    new playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, sizeof(playername));
    new gouse = PlayerInfo[playerid][pPvikendicakey];
    if(PlayerInfo[playerid][pPvikendicakey] == 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], false) == 0) {
        SendClientMessage( playerid, WHITE, "Ne posjedujes Vikendicu!" );
        return 1;
    }

    x_job = strtok(params, idx);
    if(!strlen(x_job) && PlayerInfo[playerid][pPvikendicakey] != 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], true) == 0) {
        format( string, sizeof( string ), " %s | Cijena: %d (ID Vikendice: %d) Vlasnik: %s", Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOpis],Vikendica[PlayerInfo[playerid][pPvikendicakey]][VikendicaPrice], PlayerInfo[playerid][pPvikendicakey], Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner]);
        SendClientMessage( playerid, 0x366936FF, string);
        SendClientMessage(playerid, 0x5C865CFF,"{168BFF}POMOC:{838361} /vikendica [ime]");
        SendClientMessage(playerid, 0x6D936DFF,"Dostupno: prodaj, informacije");
        SendClientMessage(playerid, 0x7EA07EFF,"Dostupno: otkljucaj, zakljucaj");
        return 1;
    }
    if(strcmp(x_job,"prodaj",true) == 0) {
        new sendername[MAX_PLAYER_NAME], stringt[64];
        if(PlayerInfo[playerid][pPvikendicakey] == 255) {
            SendClientMessage(playerid, COLOR_WHITE, "Ne posjedujes Vikendicu.");
            return 1;
        }

        if(PlayerInfo[playerid][pPvikendicakey] != 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], true) == 0) {
            new id;
            new vikendica = PlayerInfo[playerid][pPvikendicakey];
            Vikendica[vikendica][vOwned] = 0;
            Vikendica[vikendica][vLockStatus] = 1;
            GetPlayerName(playerid, sendername, sizeof(sendername));
            strmid(Vikendica[vikendica][vOwner], "Niko", 0, strlen("Niko"), 255);
            ConsumingMoney[playerid] = 1;
            Vikendica[vikendica][vOwned] = 0;
            PlayerInfo[playerid][pSpawnChange] = 1;
            GivePlayerCash(playerid,Vikendica[vikendica][VikendicaPrice]);
            PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
            format( stringt, sizeof( stringt ), "~y~Prodali ste Vikendicu za: ~g~%d$", Vikendica[vikendica][VikendicaPrice]);
            GameTextForPlayer(playerid, stringt, 5000, 1);
            PlayerInfo[playerid][pPvikendicakey] = 255;
            if(PlayerInfo[playerid][pLocal] == vikendica) {
                SetPlayerInterior(playerid,0);
                SetPlayerPos(playerid,Vikendica[vikendica][vExteriorX],Vikendica[vikendica][vExteriorY],Vikendica[vikendica][vExteriorZ]);
                PlayerInfo[playerid][pInt] = 0;
            }
            SaveVikendica(vikendica);
            OnPropTextdrawUpdate(5,id);
            SacuvajIgraca(playerid);
            return 1;

        }

    }
    else if(strcmp(x_job,"otkljucaj",true) == 0) {
#pragma unused params

        if( PlayerInfo[playerid][pPvikendicakey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Vikendica[gouse][vExteriorX], Vikendica[gouse][vExteriorY], Vikendica[gouse][vExteriorZ])) {
            if(Vikendica[gouse][vLockStatus] == 1) {
                Vikendica[gouse][vLockStatus] = 0;
                SaveVikendica(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Vikendica otkljucana." );
            }
        }
        return 1;
    }
    else if(strcmp(x_job,"zakljucaj",true) == 0) {
#pragma unused params

        if( PlayerInfo[playerid][pPvikendicakey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Vikendica[gouse][vExteriorX], Vikendica[gouse][vExteriorY], Vikendica[gouse][vExteriorZ])) {
            if(Vikendica[gouse][vLockStatus] == 0) {
                Vikendica[gouse][vLockStatus] = 1;
                SaveVikendica(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Vikendica zakljucana." );
            }
        }
        return 1;
    }
    return 1;
}

Neke slike/video za lakse dobivanje pomoci(neobavezno)://

Opisi kak' ti ne radi. Ispise poruku 'SERVER: Unknown command' ili nesto drugo?

Last nick: Paradox

Napise mi unijeli ste nepostojecu komandu!

Probaj ovo:
COMMAND:stan(playerid,params[])
{
    new string[230];
    new x_job[220];
    new idx;
    new playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, sizeof(playername));
    new gouse = PlayerInfo[playerid][pPstankey];
    if(PlayerInfo[playerid][pPstankey] == 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], false) == 0) {
        SendClientMessage( playerid, WHITE, "Ne posjedujes Stan!" );
        return 1;
    }

    x_job = strtok(params, idx);
    if(!strlen(x_job) && PlayerInfo[playerid][pPstankey] != 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], true) == 0) {
        format( string, sizeof( string ), " %s | Cijena: %d (ID Stana: %d) Vlasnik: %s", Stan[PlayerInfo[playerid][pPstankey]][hOpis],Stan[PlayerInfo[playerid][pPstankey]][HousePrice], PlayerInfo[playerid][pPstankey], Stan[PlayerInfo[playerid][pPstankey]][hOwner]);
        SendClientMessage( playerid, 0x366936FF, string);
        SendClientMessage(playerid, 0x5C865CFF,"{168BFF}POMOC:{838361} /stan [ime]");
        SendClientMessage(playerid, 0x6D936DFF,"Dostupno: prodaj, informacije, preuredi");
        SendClientMessage(playerid, 0x7EA07EFF,"Dostupno: otkljucaj, zakljucaj");
        return 1;
    }
    if(strcmp(x_job,"prodaj",true) == 0) {
        new sendername[MAX_PLAYER_NAME], stringt[64];
        if(PlayerInfo[playerid][pPstankey] == 255) {
            SendClientMessage(playerid, COLOR_WHITE, "Ne posjedujes stan.");
            return 1;
        }

        if(PlayerInfo[playerid][pPstankey] != 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], true) == 0) {
            new id;
            new stan = PlayerInfo[playerid][pPstankey];
            Stan[stan][hOwned] = 0;
            Stan[stan][LockStatus] = 1;
            GetPlayerName(playerid, sendername, sizeof(sendername));
            strmid(Stan[stan][hOwner], "Niko", 0, strlen("Niko"), 255);
            ConsumingMoney[playerid] = 1;
            Stan[stan][hOwned] = 0;
            PlayerInfo[playerid][pSpawnChange] = 1;
            GivePlayerCash(playerid,Stan[stan][HousePrice]);
            PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
            format( stringt, sizeof( stringt ), "~y~Prodali ste stan za: ~g~%d$", Stan[stan][HousePrice]);
            GameTextForPlayer(playerid, stringt, 5000, 1);
            PlayerInfo[playerid][pPstankey] = 255;
            if(PlayerInfo[playerid][pLocal] == stan) {
                SetPlayerInterior(playerid,0);
                SetPlayerPos(playerid,Stan[stan][sExteriorX],Stan[stan][sExteriorY],Stan[stan][sExteriorZ]);
                PlayerInfo[playerid][pInt] = 0;
            }
            SaveStan(stan);
            OnPropTextdrawUpdate(4,id);
            SacuvajIgraca(playerid);
            return 1;

        }

    }
    else if(strcmp(x_job,"otkljucaj",true) == 0) {

        if( PlayerInfo[playerid][pPstankey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Stan[gouse][sExteriorX], Stan[gouse][sExteriorY], Stan[gouse][sExteriorZ])) {
            if(Stan[gouse][LockStatus] == 1) {
                Stan[gouse][LockStatus] = 0;
                SaveStan(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Stan otkljucan." );
            }
        }
        return 1;
    }
    else if(strcmp(x_job,"zakljucaj",true) == 0) {

        if( PlayerInfo[playerid][pPstankey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Stan[gouse][sExteriorX], Stan[gouse][sExteriorY], Stan[gouse][sExteriorZ])) {
            if(Stan[gouse][LockStatus] == 0) {
                Stan[gouse][LockStatus] = 1;
                SaveStan(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Stan zakljucan." );
            }
        }
        return 1;
    }
    return 1;
}


COMMAND:vikendica(playerid,params[])
{
    new string[340];
    new x_job[320];
    new idx;
    new playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, sizeof(playername));
    new gouse = PlayerInfo[playerid][pPvikendicakey];
    if(PlayerInfo[playerid][pPvikendicakey] == 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], false) == 0) {
        SendClientMessage( playerid, WHITE, "Ne posjedujes Vikendicu!" );
        return 1;
    }

    x_job = strtok(params, idx);
    if(!strlen(x_job) && PlayerInfo[playerid][pPvikendicakey] != 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], true) == 0) {
        format( string, sizeof( string ), " %s | Cijena: %d (ID Vikendice: %d) Vlasnik: %s", Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOpis],Vikendica[PlayerInfo[playerid][pPvikendicakey]][VikendicaPrice], PlayerInfo[playerid][pPvikendicakey], Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner]);
        SendClientMessage( playerid, 0x366936FF, string);
        SendClientMessage(playerid, 0x5C865CFF,"{168BFF}POMOC:{838361} /vikendica [ime]");
        SendClientMessage(playerid, 0x6D936DFF,"Dostupno: prodaj, informacije");
        SendClientMessage(playerid, 0x7EA07EFF,"Dostupno: otkljucaj, zakljucaj");
        return 1;
    }
    if(strcmp(x_job,"prodaj",true) == 0) {
        new sendername[MAX_PLAYER_NAME], stringt[64];
        if(PlayerInfo[playerid][pPvikendicakey] == 255) {
            SendClientMessage(playerid, COLOR_WHITE, "Ne posjedujes Vikendicu.");
            return 1;
        }

        if(PlayerInfo[playerid][pPvikendicakey] != 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], true) == 0) {
            new id;
            new vikendica = PlayerInfo[playerid][pPvikendicakey];
            Vikendica[vikendica][vOwned] = 0;
            Vikendica[vikendica][vLockStatus] = 1;
            GetPlayerName(playerid, sendername, sizeof(sendername));
            strmid(Vikendica[vikendica][vOwner], "Niko", 0, strlen("Niko"), 255);
            ConsumingMoney[playerid] = 1;
            Vikendica[vikendica][vOwned] = 0;
            PlayerInfo[playerid][pSpawnChange] = 1;
            GivePlayerCash(playerid,Vikendica[vikendica][VikendicaPrice]);
            PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
            format( stringt, sizeof( stringt ), "~y~Prodali ste Vikendicu za: ~g~%d$", Vikendica[vikendica][VikendicaPrice]);
            GameTextForPlayer(playerid, stringt, 5000, 1);
            PlayerInfo[playerid][pPvikendicakey] = 255;
            if(PlayerInfo[playerid][pLocal] == vikendica) {
                SetPlayerInterior(playerid,0);
                SetPlayerPos(playerid,Vikendica[vikendica][vExteriorX],Vikendica[vikendica][vExteriorY],Vikendica[vikendica][vExteriorZ]);
                PlayerInfo[playerid][pInt] = 0;
            }
            SaveVikendica(vikendica);
            OnPropTextdrawUpdate(5,id);
            SacuvajIgraca(playerid);
            return 1;

        }

    }
    else if(strcmp(x_job,"otkljucaj",true) == 0) {
	
        if( PlayerInfo[playerid][pPvikendicakey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Vikendica[gouse][vExteriorX], Vikendica[gouse][vExteriorY], Vikendica[gouse][vExteriorZ])) {
            if(Vikendica[gouse][vLockStatus] == 1) {
                Vikendica[gouse][vLockStatus] = 0;
                SaveVikendica(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Vikendica otkljucana." );
            }
        }
        return 1;
    }
    else if(strcmp(x_job,"zakljucaj",true) == 0) {

        if( PlayerInfo[playerid][pPvikendicakey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Vikendica[gouse][vExteriorX], Vikendica[gouse][vExteriorY], Vikendica[gouse][vExteriorZ])) {
            if(Vikendica[gouse][vLockStatus] == 0) {
                Vikendica[gouse][vLockStatus] = 1;
                SaveVikendica(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Vikendica zakljucana." );
            }
        }
        return 1;
    }
    return 1;
}

Last nick: Paradox



COMMAND:stan(playerid,params[])
{
    new string[230];
    new x_job[220];
    new idx;
    new playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, sizeof(playername));
    new gouse = PlayerInfo[playerid][pPstankey];
    if(PlayerInfo[playerid][pPstankey] == 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], false) == 0) {
        SendClientMessage( playerid, WHITE, "Ne posjedujes Stan!" );
        return 1;
    }

    x_job = strtok(params, idx);
    if(!strlen(x_job) && PlayerInfo[playerid][pPstankey] != 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], true) == 0) {
        format( string, sizeof( string ), " %s | Cijena: %d (ID Stana: %d) Vlasnik: %s", Stan[PlayerInfo[playerid][pPstankey]][hOpis],Stan[PlayerInfo[playerid][pPstankey]][HousePrice], PlayerInfo[playerid][pPstankey], Stan[PlayerInfo[playerid][pPstankey]][hOwner]);
        SendClientMessage( playerid, 0x366936FF, string);
        SendClientMessage(playerid, 0x5C865CFF,"{168BFF}POMOC:{838361} /stan [ime]");
        SendClientMessage(playerid, 0x6D936DFF,"Dostupno: prodaj, informacije, preuredi");
        SendClientMessage(playerid, 0x7EA07EFF,"Dostupno: otkljucaj, zakljucaj");
        return 1;
    }
    if(strcmp(x_job,"prodaj",true) == 0) {
        new sendername[MAX_PLAYER_NAME], stringt[64];
        if(PlayerInfo[playerid][pPstankey] == 255) {
            SendClientMessage(playerid, COLOR_WHITE, "Ne posjedujes stan.");
            return 1;
        }

        if(PlayerInfo[playerid][pPstankey] != 255 && strcmp(playername, Stan[PlayerInfo[playerid][pPstankey]][hOwner], true) == 0) {
            new id;
            new stan = PlayerInfo[playerid][pPstankey];
            Stan[stan][hOwned] = 0;
            Stan[stan][LockStatus] = 1;
            GetPlayerName(playerid, sendername, sizeof(sendername));
            strmid(Stan[stan][hOwner], "Niko", 0, strlen("Niko"), 255);
            ConsumingMoney[playerid] = 1;
            Stan[stan][hOwned] = 0;
            PlayerInfo[playerid][pSpawnChange] = 1;
            GivePlayerCash(playerid,Stan[stan][HousePrice]);
            PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
            format( stringt, sizeof( stringt ), "~y~Prodali ste stan za: ~g~%d$", Stan[stan][HousePrice]);
            GameTextForPlayer(playerid, stringt, 5000, 1);
            PlayerInfo[playerid][pPstankey] = 255;
            if(PlayerInfo[playerid][pLocal] == stan) {
                SetPlayerInterior(playerid,0);
                SetPlayerPos(playerid,Stan[stan][sExteriorX],Stan[stan][sExteriorY],Stan[stan][sExteriorZ]);
                PlayerInfo[playerid][pInt] = 0;
            }
            SaveStan(stan);
            OnPropTextdrawUpdate(4,id);
            SacuvajIgraca(playerid);

        }

    }
    else if(strcmp(x_job,"otkljucaj",true) == 0) {

        if( PlayerInfo[playerid][pPstankey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Stan[gouse][sExteriorX], Stan[gouse][sExteriorY], Stan[gouse][sExteriorZ])) {
            if(Stan[gouse][LockStatus] == 1) {
                Stan[gouse][LockStatus] = 0;
                SaveStan(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Stan otkljucan." );
            }
        }
    }
    else if(strcmp(x_job,"zakljucaj",true) == 0) {

        if( PlayerInfo[playerid][pPstankey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Stan[gouse][sExteriorX], Stan[gouse][sExteriorY], Stan[gouse][sExteriorZ])) {
            if(Stan[gouse][LockStatus] == 0) {
                Stan[gouse][LockStatus] = 1;
                SaveStan(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Stan zakljucan." );
            }
        }
    }
    return 1;
}


COMMAND:vikendica(playerid,params[])
{
    new string[340];
    new x_job[320];
    new idx;
    new playername[MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername, sizeof(playername));
    new gouse = PlayerInfo[playerid][pPvikendicakey];
    if(PlayerInfo[playerid][pPvikendicakey] == 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], false) == 0) {
        SendClientMessage( playerid, WHITE, "Ne posjedujes Vikendicu!" );
        return 1;
    }

    x_job = strtok(params, idx);
    if(!strlen(x_job) && PlayerInfo[playerid][pPvikendicakey] != 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], true) == 0) {
        format( string, sizeof( string ), " %s | Cijena: %d (ID Vikendice: %d) Vlasnik: %s", Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOpis],Vikendica[PlayerInfo[playerid][pPvikendicakey]][VikendicaPrice], PlayerInfo[playerid][pPvikendicakey], Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner]);
        SendClientMessage( playerid, 0x366936FF, string);
        SendClientMessage(playerid, 0x5C865CFF,"{168BFF}POMOC:{838361} /vikendica [ime]");
        SendClientMessage(playerid, 0x6D936DFF,"Dostupno: prodaj, informacije");
        SendClientMessage(playerid, 0x7EA07EFF,"Dostupno: otkljucaj, zakljucaj");
        return 1;
    }
    if(strcmp(x_job,"prodaj",true) == 0) {
        new sendername[MAX_PLAYER_NAME], stringt[64];
        if(PlayerInfo[playerid][pPvikendicakey] == 255) {
            SendClientMessage(playerid, COLOR_WHITE, "Ne posjedujes Vikendicu.");
            return 1;
        }

        if(PlayerInfo[playerid][pPvikendicakey] != 255 && strcmp(playername, Vikendica[PlayerInfo[playerid][pPvikendicakey]][vOwner], true) == 0) {
            new id;
            new vikendica = PlayerInfo[playerid][pPvikendicakey];
            Vikendica[vikendica][vOwned] = 0;
            Vikendica[vikendica][vLockStatus] = 1;
            GetPlayerName(playerid, sendername, sizeof(sendername));
            strmid(Vikendica[vikendica][vOwner], "Niko", 0, strlen("Niko"), 255);
            ConsumingMoney[playerid] = 1;
            Vikendica[vikendica][vOwned] = 0;
            PlayerInfo[playerid][pSpawnChange] = 1;
            GivePlayerCash(playerid,Vikendica[vikendica][VikendicaPrice]);
            PlayerPlaySound(playerid, 1052, 0.0, 0.0, 0.0);
            format( stringt, sizeof( stringt ), "~y~Prodali ste Vikendicu za: ~g~%d$", Vikendica[vikendica][VikendicaPrice]);
            GameTextForPlayer(playerid, stringt, 5000, 1);
            PlayerInfo[playerid][pPvikendicakey] = 255;
            if(PlayerInfo[playerid][pLocal] == vikendica) {
                SetPlayerInterior(playerid,0);
                SetPlayerPos(playerid,Vikendica[vikendica][vExteriorX],Vikendica[vikendica][vExteriorY],Vikendica[vikendica][vExteriorZ]);
                PlayerInfo[playerid][pInt] = 0;
            }
            SaveVikendica(vikendica);
            OnPropTextdrawUpdate(5,id);
            SacuvajIgraca(playerid);

        }

    }
    else if(strcmp(x_job,"otkljucaj",true) == 0) {
	
        if( PlayerInfo[playerid][pPvikendicakey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Vikendica[gouse][vExteriorX], Vikendica[gouse][vExteriorY], Vikendica[gouse][vExteriorZ])) {
            if(Vikendica[gouse][vLockStatus] == 1) {
                Vikendica[gouse][vLockStatus] = 0;
                SaveVikendica(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Vikendica otkljucana." );
            }
        }
    }
    else if(strcmp(x_job,"zakljucaj",true) == 0) {

        if( PlayerInfo[playerid][pPvikendicakey] != 255  && IsPlayerInRangeOfPoint( playerid, 5, Vikendica[gouse][vExteriorX], Vikendica[gouse][vExteriorY], Vikendica[gouse][vExteriorZ])) {
            if(Vikendica[gouse][vLockStatus] == 0) {
                Vikendica[gouse][vLockStatus] = 1;
                SaveVikendica(gouse);
                SendClientMessage( playerid, 0xB1D8C4FF, "Vikendica zakljucana." );
            }
        }
    }
    return 1;
}

Last nick: Paradox