Jump to content
  • 0

Problema clan


Maddo

Question

Problema intalnita (descriere):Deci, atunci cand dau prin [/shop] sa creez clan, imi apare primul dialog sa scriu numele, ok, scriu numele, dau enter, dupa apare sa scriu tag-ul, scriu tag-ul, dau enter, si asa ramane, nu mai se intampla nimic, si in /clan nu exista o optiune sa setezi tag, sau ceva gen, si la Info scrie "Clan name: Numele de la clan" si la "Clan tag: " nu scrie nimic, va rog, help !!!!
Ero(area / rile) / warning-(ul / urile):Nu este nici o eroare, numai ca nu apare.
Liniile de cod / sursa / script-ul(obligatoriu):Nu stiu ce sa pun, daca e nevoie las gm-ul in privat unui scripter profesionist ca Mister, Equinox, DeadrickFox(Scuze daca am gresit numele)
Imagini / Video (optional):Nu cred ca e nevoie
Ati incercat sa rezolvati singur?:Da, dar fara succes, am incercat sa modific niste linii, sa scot return sa fac mai multe, dar fara succes

 

Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

Mai nou m-am facut clarvazator,identific fantome si probleme altora fara sa stiu defapt care este codul sursei.

 

De ce ... crezi ca nu te ajuta nimeni?

Daca nu postezi nimic,atunci ramai asa..

 

 

Link to comment
Share on other sites

  • 0

Poftim, pun asta, care e legata de clan

 

case DIALOG_BUYCLAN:
        {
            if(strlen(inputtext) < 4 || strlen(inputtext) > 10) {
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Numele clanului trebuie sa aiba intre 4 si 10 caractere.");
                ShowPlayerDialog(playerid, DIALOG_BUYCLAN, DIALOG_STYLE_INPUT, "Creeaza un clan:", "{FFFFFF}Esti pe cale sa-ti faci un clan.\nPasul intai este de a-ti alege numele clanului.", "Selecteaza", "");
                return 1;
            }

            new
                szDate[256],
                Year, Month, Day, Hour, Minute, Second;

            getdate(Year, Month, Day);
            gettime(Hour, Minute, Second);

            format(szDate, sizeof(szDate), "%02d/%02d/%d - %02d:%02d:%02d", Day, Month, Year, Hour, Minute, Second);

            mysql_format(mysql, szQuery, 256, "INSERT INTO `clans` (`Name`, `Owner`, `RegisterDate`, `Color`) VALUES ('%e', '%e', '%e', 'FFFFFF')", inputtext, PlayerInfo[playerid][pUsername], szDate);
            new Cache: result = mysql_query(mysql, szQuery);
            new i = cache_insert_id();
            cache_delete(result);

            format(ClanInfo[clName], 64, inputtext);
            format(ClanInfo[clOwner], 256, PlayerInfo[playerid][pUsername]);
            format(ClanInfo[clRegisterDate], 256, szDate);
            format(ClanInfo[clColor], 256, "FFFFFF");
            format(PlayerInfo[playerid][pClanDate], 256, szDate);
            PlayerInfo[playerid][pClan] = i;
            PlayerInfo[playerid][pClanRank] = 6;
            if(strlen(inputtext) < 3 || strlen(inputtext) > 6) {
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Tagul clanului trebuie sa aiba intre 3 si 6 caractere.");
                new szText[256];
                   format(szText, sizeof(szText), "{FFFFFF}Ai ales numele {F2BA38}%s{FFFFFF}.\nAl doilea pas este de a-ti {608FFC}alege tag-ul clanului{FFFFFF}.", inputtext);
                   ShowPlayerDialog(playerid, DIALOG_BUYCLAN2, DIALOG_STYLE_INPUT, "Creeaza un clan:", szText, "Select", "");
                return 1;
            }
            
            new clanid = PlayerInfo[playerid][pClan];
            
            format(ClanInfo[clanid][clTag], 64, inputtext);
            format(szQuery, sizeof(szQuery), "UPDATE `clans` SET `Tag`='%s' WHERE `ID`='%d'", inputtext, clanid);
            mysql_query(mysql, szQuery);
            new szText[256];
            format(szText, sizeof(szText), "{F7FF66}%s{FFFFFF}Name\nName{F7FF66}%s", ClanInfo[clanid][clTag], ClanInfo[clanid][clTag]);
            ShowPlayerDialog(playerid, DIALOG_BUYCLAN3, DIALOG_STYLE_LIST, "{F2BA38}Alege pozitia tagului:", szText, "Selecteaza", "");
            
            new
                szName[256];

            ClanInfo[clanid][clTagType] = listitem;
            format(string, sizeof(string), "Felicitari! Ti-ai creeat propriul tau clan. (%s - Tag: %s [Tag Type: %d])", ClanInfo[clanid][clName], ClanInfo[clanid][clTag], listitem);
            SendClientMessage(playerid, COLOR_MONEY, string);
            format(szQuery, sizeof(szQuery), "UPDATE `clans` SET `TagType`='%d' WHERE `ID`='%d'", listitem, clanid);
            mysql_query(mysql, szQuery);
            format(ClanInfo[clanid][clRankName1], 32, "Rank 1");
            format(ClanInfo[clanid][clRankName2], 32, "Rank 2");
            format(ClanInfo[clanid][clRankName3], 32, "Rank 3");
            format(ClanInfo[clanid][clRankName4], 32, "Rank 4");
            format(ClanInfo[clanid][clRankName5], 32, "Rank 5");
            format(ClanInfo[clanid][clRankName6], 32, "Rank 6");
            format(ClanInfo[clanid][clMotd], 32, "None");
            if(ClanInfo[clanid][clTagType] == 0) {
                format(szName, sizeof(szName), "%s%s", ClanInfo[clanid][clTag], PlayerInfo[playerid][pUsername]);
            }
            else if(ClanInfo[clanid][clTagType] == 1) {
                format(szName, sizeof(szName), "%s%s", PlayerInfo[playerid][pUsername], ClanInfo[clanid][clTag]);
            }
            SetPlayerName(playerid, szName);
            PlayerInfo[playerid][pPremiumPoints] -= 75;
            format(szQuery, sizeof(szQuery), "UPDATE `accounts` SET `GoldPoints`='%d' WHERE `Username`='%s'", PlayerInfo[playerid][pPremiumPoints], PlayerInfo[playerid][pUsername]);
            mysql_query(mysql, szQuery);
        }

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.