Jump to content



Recommended Posts

Salut boiz
kum fac comanda nre ?? ?? ??  // 

ita aici kum am fakut komanda /n da pe nre nuj kum sho fac

imi zike cnv?


CMD:n(playerid, params[])
    if(P_Data[playerid][pHelper] > 1)
        return SCM(playerid, color_gray, "Faci parte din staff deja!");
    if(P_Data[playerid][pAdmin] > 1)
        return SCM(playerid, color_gray, "Faci parte din staff deja!");    
    if(IntrebareON[playerid] == 1)
        return SCM(playerid, color_gray, "Ai deja o intrebare pusa!");
    new intrebare[64],string[64];
    if(sscanf(params, "s[64]", intrebare))
        return SCM(playerid, color_gray, "Folosire: /n <intrebare/question>");
    SCM(playerid, color_yellow, "Ai pus o intrebare ! Asteapta pana raspunde un helper.");
    IntrebareON[playerid] = 1;
    format(string, sizeof(string), "%s[%d] a pus intrebarea: %s", GetName(playerid), playerid, intrebare);
    SendHelperMessage(color_anunt, string);
    return 1;


Link to comment
Share on other sites

Presupun ca asta vrei sa faci (/nre id raspuns).

// Pe undeva prin gamemode (inainte de comanda /n) adaugi:
new NText[MAX_PLAYERS][64];

// La comanda /n pui urmatoarea linie pe undeva pe la final:
format(NText[playerid], 64, intrebare);

CMD:nre(playerid, params[])
    if(P_Data[playerid][pHelper] == 0 && P_Data[playerid][pAdmin] == 0) 
        return SCM(playerid, color_gray, "Nu ai acces la aceasta comanda!");
    new id, raspuns[64];
    if(sscanf(params, "us[64]", id, raspuns))
        return SCM(playerid, color_gray, "Folosire: /nre <nume/id> <raspuns/answer>");

    if(IntrebareON[id] == 0)
        return SCM(playerid, color_gray, "Acel jucator nu a pus o intrebare.");

    new string[128];
    format(string, sizeof(string), "%s[%d] a intrebat: %s", GetName(id), id, NText[id]);
    SendClientMessageToAll(color_anunt, string);
    format(string, sizeof(string), "%s[%d] a raspuns: %s", GetName(playerid), playerid, raspuns);
    SendClientMessageToAll(color_anunt, string);          
    IntrebareON[id] = 0;
    NText[id][0] = EOS;
    return 1;

Daca gasesti buguri sau ceva ma anunti, spor! :D

Edited by NERS
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.

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.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • 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.