Jump to content
  • 0

Nu imi sesteaza tag-ul la clan


custura

Question

    Acestea sunt liniile(atunci cand playerul se conecteaza ar trebui sa ii seteze numele+tag)

                if(PlayerData[extraid][pClan] > 0)
                    {
                        new clsetName[25];
                        new clanid = PlayerData[extraid][pClan];
                        if(ClanData[clanid][clanTag] == 1)
                        {
                            format(clsetName, sizeof(clsetName), "%s%s", ClanData[PlayerData[extraid][pClan]][clanTag], PlayerData[extraid][pUsername]);
                            SetPlayerName(extraid, clsetName);
                        }
                        else if(ClanData[clanid][clanTag] == 2)
                        {
                            format(clsetName, sizeof(clsetName), "%s%s", PlayerData[extraid][pUsername], ClanData[PlayerData[extraid][pClan]][clanTag]);
                            SetPlayerName(extraid, clsetName);
                        }
                    }

Am facut o comanda sa vad daca citeste bine din baza de date, iar rezultatul este ok

 

sa-mp-012.png

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0
La 17.04.2018 la 21:56, custura a spus:

    Acestea sunt liniile(atunci cand playerul se conecteaza ar trebui sa ii seteze numele+tag)

                if(PlayerData[extraid][pClan] > 0)
                    {
                        new clsetName[25];
                        new clanid = PlayerData[extraid][pClan];
                        if(ClanData[clanid][clanTag] == 1)
                        {
                            format(clsetName, sizeof(clsetName), "%s%s", ClanData[PlayerData[extraid][pClan]][clanTag], PlayerData[extraid][pUsername]);
                            SetPlayerName(extraid, clsetName);
                        }
                        else if(ClanData[clanid][clanTag] == 2)
                        {
                            format(clsetName, sizeof(clsetName), "%s%s", PlayerData[extraid][pUsername], ClanData[PlayerData[extraid][pClan]][clanTag]);
                            SetPlayerName(extraid, clsetName);
                        }
                    }

Am facut o comanda sa vad daca citeste bine din baza de date, iar rezultatul este ok

 

sa-mp-012.png

poate ca extraid nu este idul curent al jucatorului in joc.Fa un debug cu SCM sau printf pt acel extraid

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
Answer this question...

×   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.