Zaloguj się by uzyskać pełen dostęp. Nie masz jeszcze konta? Założ je już teraz w kilka sekund.

Wysłany: 2018-02-28, 14:33


Zelniak







Wiek: 25
Na forum: 3159 dni
Posty: 1



Respekt: 50

Mam takie errory:
Kod:

C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(401) : warning 204: symbol is assigned a value that is never used: "s"
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(458) : warning 219: local variable "Query" shadows a variable at a preceding level
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(462) : error 004: function "mysql_query" is not implemented
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(468) : error 004: function "mysql_query" is not implemented
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(486) : warning 219: local variable "Query" shadows a variable at a preceding level
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(493) : error 004: function "mysql_query" is not implemented
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(503) : error 004: function "mysql_query" is not implemented
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(521) : error 004: function "mysql_query" is not implemented
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(525) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(526) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(527) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(528) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(577) : error 004: function "mysql_query" is not implemented
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(581) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(582) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(583) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(584) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(585) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(586) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(587) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(588) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(589) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(590) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(591) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(592) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(593) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(594) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(595) : error 035: argument type mismatch (argument 1)
C:\Users\Lenovo\Desktop\GM\gamemodes\PBT.pwn(596) : error 035: argument type mismatch (argument 1)

Linijki (401-596):
Pawn
 new s[512];
    ShowPlayerDialog(playerid, DIALOG_KONTO, DIALOG_STYLE_LIST, "{00FFFF}Opcje konta","Zmie? has?o\n{999999}Statystyki","Wybierz","Zamknij");
    return 1;
}

CMD:pos(playerid, params[])
{
    new Float:x, Float:y, Float:z;
    GetPlayerPos(playerid, x,y,z);
    new s[256];
    format(s, sizeof(s), "X: %f Y: %f Z: %f  Sekunda: %d   Minuta: %d Godzina %d Ranga: %d Slot %d, klikni?ty %s %d", x,y,z, Gracz[playerid][SekundaG], Gracz[playerid][MinutaG], Gracz[playerid][GodzinaG], Gracz[playerid][Ranga], strval(Gracz[playerid][slot]), PlayerName(Gracz[playerid][klikniety]), Gracz[playerid][klikniety]);
    SendClientMessage(playerid, BIALY, s);
    return 1;
}

CMD:ustaw(playerid, params[])
{
    new wartosc;
    if(sscanf(params, "d", wartosc))
    Gracz[playerid][slot] = wartosc;
    return 1;
}

CMD:kill(playerid, params[])
{
    if(Gracz[playerid][Ranga] >= 3)
    {
        new id;
        if(sscanf(params, "d", id)) return SendClientMessage(playerid, BIALY, "Wpisz: /kill [id]");
        if(IsPlayerConnected(id) == 0) return SendClientMessage(playerid, CZERWONY, "Nie ma takiego id ");
        
        SetPlayerHealth(id, 0.0);
    }
    return 1;
}

CMD:dajrange(playerid, params[])
{
    if(Gracz[playerid][Ranga] == 7)
    {
        new id, poziom;
        if(sscanf(params, "dd", id, poziom)) return SendClientMessage(playerid, SZARY, "Wpisz: /dajrange [id] [ranga]");
        if(IsPlayerConnected(id) == 0) return SendClientMessage(playerid, CZERWONY, "Nie ma gracza o tym ID");
    
        new s[256];
        format(s, sizeof(s), "{00CC00}Da?e? rang? %d graczowi %s [%d]", poziom, PlayerName(id), id);
        SendClientMessage(playerid, BIALY, s);
        Gracz[id][Ranga] = poziom;
        ZapiszGracza(id);
    }
    return 1;
}

CMD:ugw(playerid, params[])
{
    if(Gracz[playerid][Ranga] >= 3 || Gracz[playerid][Policja] == true || Gracz[playerid][PolicjaS] == true)
    {
        new nick[24], Query[80];
        if(sscanf(params, "s[24]", nick)) return SendClientMessage(playerid, SZARY, "Wpisz: /ugw [nick]");
    
        format(Query, sizeof(Query), "SELECT `Nick` FROM `Scigani` WHERE `Nick` = '%s'", nick);
        mysql_query(Query);
        mysql_store_result();
        if(mysql_num_rows() != 0)
        {
            new s[128];
            format(s, sizeof(s), "DELETE FROM Scigani WHERE Nick = '%s'", nick);
            mysql_query(s);
            format(s, sizeof(s), "{00CC00}[Informacja]: {999999}Usuni?to %s z bazy danych policji", nick);
            SendClientMessage(playerid, SZARY, s);
        }
        else
        {
            SendClientMessage(playerid, CZERWONY, "Nie odnaleziono gracza w bazie danych");
        }
        mysql_free_result();
    }
    return 1;
}


CMD:dajgw(playerid, cmdtext[])
{
    if(Gracz[playerid][Ranga] >= 3 || Gracz[playerid][Policja] == true || Gracz[playerid][PolicjaS] == true)
    {
        new id, powod[64], gwiazdkix, Query[256];
        if(sscanf(cmdtext, "dds[64]", id, gwiazdkix, powod)) return SendClientMessage(playerid, SZARY, "Wpisz: /dajgw [id] [gwiazdki 1-6] [pow?d]");
        if(IsPlayerConnected(id) == 0) return SendClientMessage(playerid, CZERWONY, "Nie ma gracza o tym id");
        if(gwiazdkix < 1 || gwiazdkix >= 7) return SendClientMessage(playerid, CZERWONY, "Gwiazdki mog? wynosi? warto?? 1-6");
        if(strlen(powod) < 1 || strlen(powod) >= 64) return SendClientMessage(playerid, CZERWONY, "Pow?d mo?e mie? od 1 do 64 znak?w"); 
    
        format(Query, sizeof(Query), "SELECT `Nick` FROM `Scigani` WHERE `Nick` = '%s' LIMIT 1;", PlayerName(id));
        mysql_query(Query);
        mysql_store_result();
        if(mysql_num_rows() != 0)
        {
            SendClientMessage(playerid, CZERWONY, "Ten gracz jest ju? w bazie danych");
        }    
        else
        {
            new s[256];
            format(s, sizeof(s), "INSERT INTO Scigani VALUES ('%s','%d','%s','%s')", PlayerName(id), gwiazdkix, powod, PlayerName(playerid));
            mysql_query(s);
            format(s, sizeof(s), "{00CC00}[Informacja]: {999999}Pomy?lnie dodano %s (%d), do bazy danych z poziomem poszukiwa? r?wnym {FF0000}%d", PlayerName(id), id, gwiazdkix);
            SendClientMessage(playerid, SZARY, s);
            SetPlayerWantedLevel(id, gwiazdkix);
            Gracz[id][Gwiazdki] = gwiazdkix;
            ZapiszGracza(id);
            SetPlayerColor(id, CZARNY);
            // doda? wiadomo?? dla all policji ?e policjant jakis oznaczyl kogos sciganym
        }
        mysql_free_result();
    }
    return 1;
}

CMD:scigani(playerid, params[])
{
    new buff[1024], buffer[1024], nzw[24], poziom[2], i = 1, powod[64], policjant[24];
    strcat(buff, "{FF0000}Nick:\t{FF0000}Poziom:\t{FF0000}Pow?d:\t{FF0000}Policjant:\n");
    mysql_query("SELECT Nick, Poziom, Powod, Policjant FROM Scigani");
    mysql_store_result();
    while(mysql_fetch_row(buffer))
    {
        mysql_fetch_field("Nick", nzw);
        mysql_fetch_field("Poziom", poziom);
        mysql_fetch_field("Powod", powod);
        mysql_fetch_field("Policjant", policjant);
        if(IsPlayerOnline(nzw))
        {
            format(buffer, sizeof buffer, "{FFFFFF}%2i. {00FFFF}%s\t{00CC00}%d/6\t{999999}%s\t{888888}%s {00CC00} - Online\n", i, nzw, strval(poziom), powod, policjant);
            strcat(buff, buffer);
        }
        else
        {
            format(buffer, sizeof buffer, "{FFFFFF}%2i. {00FFFF}%s\t{00CC00}%d/6\t{999999}%s\t{888888}%s {FF0000} - Offline\n", i, nzw, strval(poziom), powod, policjant);
            strcat(buff, buffer);
        }
        //if(i < 10) strcat(buff, "\n");
        i++;
    }
    mysql_free_result();
    ShowPlayerDialog(playerid, 0, DIALOG_STYLE_TABLIST_HEADERS, "?cigani", buff, "Zamknij", #);
    return 1;
}


CMD:opis(playerid, params[])
{
    new opis[64];
    if(sscanf(params, "s[64]", opis)) return SendClientMessage(playerid, SZARY, "Wpisz: /opis text(64znaki max)");
    
    new s[64];
    format(s, sizeof(s), "{999999}%s", opis);
    Attach3DTextLabelToPlayer(Gracz[playerid][opistext], playerid, 0.0, 0.0, -0.7);
    Update3DTextLabelText(Gracz[playerid][opistext], BIALY, s);
    SendClientMessage(playerid, BIALY, "Ustawiono nowy opis");
    Gracz[playerid][Opis] = opis;
    ZapiszGracza(playerid);
    return 1;
}


CMD:kuppojazd(playerid, params[])
{
    ShowPlayerDialog(playerid, DIALOG_KUP_POJAZD, DIALOG_STYLE_LIST, "Pojazdy", "Burrito\nPony", "Wybierz", "Zamknij");
    return 1;
}

CMD:pojazdy(playerid, params[])
{
    new buff[1024], buffer[1024], pnick[MAX_PLAYER_NAME], i = 1;

    new s[1024];
    format(s, sizeof(s), "SELECT Nick, Nazwa, Tablica, UID, Model, SpawnX, SpawnY, SpawnZ, SpawnR, ZyciePojazdu, Przebieg, Paliwo, CisnienieLP, CisnieniePP, CisnienieLT, CisnieniePT, Olej, Slot FROM PojazdyGraczy WHERE Nick='%s'", PlayerName(playerid));
    strcat(buff, "{999999}Nazwa\t{999999}Model\t{999999}Przebieg\t{999999}UID\n");
    mysql_query(s);
    mysql_store_result();
    while(mysql_fetch_row(buffer))
    {
        mysql_fetch_field("Nick", pnick);
        mysql_fetch_field("Nazwa", Gracz[playerid][nazwa]);
        mysql_fetch_field("Tablica", Gracz[playerid][tablica]);
        mysql_fetch_field("UID", Gracz[playerid][uid]);
        mysql_fetch_field("Model", Gracz[playerid][model]);
        mysql_fetch_field("SpawnX", Gracz[playerid][spawnx]);
        mysql_fetch_field("SpawnY", Gracz[playerid][spawny]);
        mysql_fetch_field("SpawnZ", Gracz[playerid][spawnz]);
        mysql_fetch_field("SpawnR", Gracz[playerid][spawnr]);
        mysql_fetch_field("ZyciePojazdu", Gracz[playerid][zyciepojazdu]);
        mysql_fetch_field("Przebieg", Gracz[playerid][przebieg]);
        mysql_fetch_field("Paliwo", Gracz[playerid][paliwo]);
        mysql_fetch_field("CisnienieLP", Gracz[playerid][cisnienielp]);
        mysql_fetch_field("CisnieniePP", Gracz[playerid][cisnieniepp]);
        mysql_fetch_field("CisnienieLT", Gracz[playerid][cisnienielt]);
        mysql_fetch_field("CisnieniePT", Gracz[playerid][cisnieniept]); 


[ Dodano: 2018-03-04, 13:11 ]
Kto? co?? Za pomoc piwko oczywi?cie :)

Postaw piwo autorowi tego posta
 

 
Tagi: kilka :: rzeczy
Anonymous





Na forum: 245 dni
Posty: 1



Anonymous Koniecznie zajrzyj na:






Skocz do:  
Wyświetl posty z ostatnich:   
GTAONLINE.PL » JĘZYKI PROGRAMOWANIA » PAWN » Kilka rzeczy Ten temat jest zablokowany bez możliwości zmiany postów lub pisania odpowiedzi

Nie możesz pisać nowych tematów
Nie możesz odpowiadać w tematach
Nie możesz zmieniać swoich postów
Nie możesz usuwać swoich postów
Nie możesz głosować w ankietach
Dodaj temat do Ulubionych
Wersja do druku