Jump to content

Cerere Tutorial


R3dD

Recommended Posts

if(strcmp(cmd, "/skip", true) == 0)

{

if(IsPlayerConnected(playerid))

{

    if(Tutorial[playerid] >= 1)

    {

        Tutorial[playerid] = 0;

        SendClientMessage(playerid, COLOR_WHITE, "Text");

        format(query, sizeof(query), "UPDATE tabel SET variabila WHERE id=%d", Tutorial[playerid], PlayerData[playerid][pSQLID]);

        mysql_query(query);

}

}

return 1;

}

Explicatii:

1. La SendClientMessage, in loc de "Text" pui mesajul care vrei sa-i apara in chat celui care da /skip. Daca vrei sa pui rand nou, pui alt SendClientMessage.

2. inlocuiesti peste tot "Tutorial[playerid]" cu variabila de la tine din gamemode care tine de tutorial.

3. la updatarea mysql, inlocuiesti: "tabel" cu numele tabelului tau din mysql;  "variabila" cu numele 'row-ului' (denumirea randului) din baza ta de date.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • 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.