Jump to content

Cerere Sistem Vehicle


H3AtonN

Recommended Posts

As dori si eu mult,sa ma ajutati cu ceva.. De curand am inceput sa lucrez la un server,dar vreau sa-l fac cat mai calumea,dar unele chestii nu le stiu,de accea sper sa ma ajutati voi.. Pai eu as vrea, sa scriu de exemplu /Vehicle si sa imi dea un tabel,in acel tabel sa-mi apara toate masinile pe care le detin. Si sa dau pe una dintre ele,si sa imi scrie Respawneaza,Localizeaza,Informatii.cam atat.. As fi foarte recunoscator daca m-ar ajuta si pe mine cineva..Macar cineva care sa-mi explice.. Va rog nu inchideti acest topic!

Link to comment
Share on other sites

Este pentru connt premium gold si silver si jucatori normali

CMD:cars(playerid, params[])
{
    new string[500];
    if(IsPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_RED, "Nu esti logat!");
    if(PlayerInfo[playerid][pPcarkey] == 999 && PlayerInfo[playerid][pPcarkey2] == 999 && PlayerInfo[playerid][pPcarkey3] == 999 && PlayerInfo[playerid][pPcarkey4] == 999 && PlayerInfo[playerid][pPcarkey5] == 999
    && PlayerInfo[playerid][pPcarkey6] == 999 && PlayerInfo[playerid][pPcarkey7] == 999)
        return SCM(playerid, COLOR_WHITE, "Nu ai o masina personala.");

    new dtext[555];
    new
        carkey1 = PlayerInfo[playerid][pPcarkeyID],
        carkey2 = PlayerInfo[playerid][pPcarkey2ID],
        carkey3 = PlayerInfo[playerid][pPcarkey3ID],
        carkey4 = PlayerInfo[playerid][pPcarkey4ID],
        carkey5 = PlayerInfo[playerid][pPcarkey5ID],
        carkey6 = PlayerInfo[playerid][pPcarkey6ID],
        carkey7 = PlayerInfo[playerid][pPcarkey7ID];

    if(PlayerInfo[playerid][pPcarkey] < 999) {
        format(string, 256, "{E8E072}[SLOT 1] {309425}%s\n", VehicleNames[GetVehicleModel(carkey1)-400]);
        strcat(dtext, string);
    }
    else strcat(dtext, "{E7F26D}<slot liber>\n");

    if(PlayerInfo[playerid][pPcarkey2] < 999) {
        format(string, 256, "{E8E072}[SLOT 2] {309425}%s\n", VehicleNames[GetVehicleModel(carkey2)-400]);
        strcat(dtext, string);
    }
    else strcat(dtext, "{E7F26D}<slot liber>\n");

    if(PlayerInfo[playerid][pPcarkey3] < 999) {
        format(string, 256, "{E8E072}[SLOT 3] {309425}%s\n", VehicleNames[GetVehicleModel(carkey3)-400]);
        strcat(dtext, string);
    }
    else strcat(dtext, "{E7F26D}<slot liber>\n");

    if(PlayerInfo[playerid][pPremium] >= 1)
    {
        if(PlayerInfo[playerid][pPcarkey4] < 999) {
            format(string, 256, "{E8E072}[SLOT 4] {309425}%s\n", VehicleNames[GetVehicleModel(carkey4)-400]);
            strcat(dtext, string);
        }
        else strcat(dtext, "{E7F26D}<slot liber>\n");

        if(PlayerInfo[playerid][pPcarkey5] < 999) {
            format(string, 256, "{E8E072}[SLOT 5] {309425}%s\n", VehicleNames[GetVehicleModel(carkey5)-400]);
            strcat(dtext, string);
        }
        else strcat(dtext, "{E7F26D}<slot liber>\n");
    }

    if(PlayerInfo[playerid][pPremium] == 2)
    {
        if(PlayerInfo[playerid][pPcarkey6] < 999) {
            format(string, 256, "{E8E072}[SLOT 6] {309425}%s\n", VehicleNames[GetVehicleModel(carkey6)-400]);
            strcat(dtext, string);
        }
        else strcat(dtext, "{E7F26D}<slot liber>\n");

        if(PlayerInfo[playerid][pPcarkey7] < 999) {
            format(string, 256, "{E8E072}[SLOT 7] {309425}%s\n", VehicleNames[GetVehicleModel(carkey7)-400]);
            strcat(dtext, string);
        }
        else strcat(dtext, "{E7F26D}<slot liber>\n");
    }
    ShowPlayerDialog(playerid, 252, DIALOG_STYLE_LIST, "{FFFB00}Cars:", dtext, "Selecteaza", "Iesire");
    return 1;
}

 

 

 

 

if(dialogid == 252)
     {
        if(!response) return 1;
        if(response)
        {
               switch(listitem)
               {
                case 0: {
                    if(PlayerInfo[playerid][pPcarkey] < 999) return ShowPlayerDialog(playerid, 253, DIALOG_STYLE_LIST, "Vehicle menu:", "Vehicle Info\nFind Car\nRespawn\n{FF0000}Remove Tuning\n{FF0000}Remove Neon{FFFFFF}", "Selecteaza", "Back");
                    else SCM(playerid, 0x8CEB83FF, "Nu ai o masina pe acest slot.");
                }
                case 1: {
                    if(PlayerInfo[playerid][pPcarkey2] < 999) return ShowPlayerDialog(playerid, 254, DIALOG_STYLE_LIST, "Vehicle menu:", "Vehicle Info\nFind Car\nRespawn\n{FF0000}Remove Tuning\n{FF0000}Remove Neon{FFFFFF}", "Selecteaza", "Back");
                      else SCM(playerid, 0x8CEB83FF, "Nu ai o masina pe acest slot.");
                  }
                case 2: {
                    if(PlayerInfo[playerid][pPcarkey3] < 999) return ShowPlayerDialog(playerid, 255, DIALOG_STYLE_LIST, "Vehicle menu:", "Vehicle Info\nFind Car\nRespawn\n{FF0000}Remove Tuning\n{FF0000}Remove Neon{FFFFFF}", "Selecteaza", "Back");
                    else SCM(playerid, 0x8CEB83FF, "Nu ai o masina pe acest slot.");
                }
                case 3: {
                    if(PlayerInfo[playerid][pPcarkey4] < 999) return ShowPlayerDialog(playerid, 256, DIALOG_STYLE_LIST, "Vehicle menu:", "Vehicle Info\nFind Car\nRespawn\n{FF0000}Remove Tuning\n{FF0000}Remove Neon{FFFFFF}", "Selecteaza", "Back");
                    else SCM(playerid, 0x8CEB83FF, "Nu ai o masina pe acest slot.");
                }
                case 4: {
                    if(PlayerInfo[playerid][pPcarkey5] < 999) return ShowPlayerDialog(playerid, 257, DIALOG_STYLE_LIST, "Vehicle menu:", "Vehicle Info\nFind Car\nRespawn\n{FF0000}Remove Tuning\n{FF0000}Remove Neon{FFFFFF}", "Selecteaza", "Back");
                      else SCM(playerid, 0x8CEB83FF, "Nu ai o masina pe acest slot.");
                  }
                case 5: {
                    if(PlayerInfo[playerid][pPcarkey6] < 999) return ShowPlayerDialog(playerid, 258, DIALOG_STYLE_LIST, "Vehicle menu:", "Vehicle Info\nFind Car\nRespawn\n{FF0000}Remove Tuning\n{FF0000}Remove Neon{FFFFFF}", "Selecteaza", "Back");
                    else SCM(playerid, 0x8CEB83FF, "Nu ai o masina pe acest slot.");
                }
                case 6: {
                    if(PlayerInfo[playerid][pPcarkey7] < 999) return ShowPlayerDialog(playerid, 259, DIALOG_STYLE_LIST, "Vehicle menu:", "Vehicle Info\nFind Car\nRespawn\n{FF0000}Remove Tuning\n{FF0000}Remove Neon{FFFFFF}", "Selecteaza", "Back");
                    else SCM(playerid, 0x8CEB83FF, "Nu ai o masina pe acest slot.");
                }
            }
        }
    }

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.