Jump to content
  • 0

Question

Posted

Salu am si eu o intrebare care poate sa-mi rezolve si mie aceasta problema de compilare, 

http://prntscr.com/g6ujws

Acesta este cel de la eroare 22151, cea de de la eroarea 16395 nu stiu ce trebuie sa va dau mai exact.

Daca este ceva imi spuneti ce sa va dau si va dau.

Sper sa ma puteti ajuta va multumesc frumos.

	else if(strcmp(item, "slot1", true) == 0) {
		if(userid != INVALID_PLAYER_ID) {
			PlayerInfo[userid][pCarKey][0] = valoare ;
			if(valoare > 0) {
				format(CarInfo[valoare][cOwner], 256, GetName(userid));
				CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
				format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
				mysql_query(SQL, query);
			}
		}

 

http://prntscr.com/g6ulgi

 

 

9 answers to this question

Recommended Posts

  • 0
Posted

Chiar nu puteai face poza cand apesi f5 si arata fereastra cu erori? 

Nu stim nici codul nici eroarea nu putem sa te ajutam si dupa se face dublu post ca de ce nu ne ajuta nimeni 

 

    __  ____      __           
   /  |/  (_)____/ /____  _____
  / /|_/ / / ___/ __/ _ \/ ___/
 / /  / / (__  ) /_/  __/ /    
/_/  /_/_/____/\__/\___/_/     
SERVICII SCRIPTING DE CALITATE
Pagina     Scripting     pawn
  • 0
Posted (edited)

Prima eroare am facut-o.

la cea ai spus tu mai jos nu stiu exact la ce te referi.. imi poti spune mai exact? e pcarkey[0]

Iar pentru cealalta cauta la enum pinfo daca pcarkey este definit   ,pcarkey[9], sau fara [9]

Uite o poza : http://prntscr.com/g75x4e
Edited by eXtazy1
  • 0
Posted
2 hours ago, eXtazy1 said:

Prima eroare am facut-o.

la cea ai spus tu mai jos nu stiu exact la ce te referi.. imi poti spune mai exact? e pcarkey[0]

Iar pentru cealalta cauta la enum pinfo daca pcarkey este definit   ,pcarkey[9], sau fara [9]

Uite o poza : http://prntscr.com/g75x4e

acel PlayerInfo[playerid][pCarkey]   nu inteleg de ce mai are inca o coloana [0] trebuie sa cauti unde ai definit variabilele sa vezi daca e corect cum le ai creat

 

esti sigur ca nu e 

PlayerInfo[userid][pCarKey] = valoare ; //fara acel [0] 

inloc de 

 

PlayerInfo[userid][pCarKey][0] = valoare ;

si mai departe

 

PlayerInfo[userid][pCarKey1] = valoare ;

inloc de 

PlayerInfo[userid][pCarKey][1] = valoare ;

 

    __  ____      __           
   /  |/  (_)____/ /____  _____
  / /|_/ / / ___/ __/ _ \/ ___/
 / /  / / (__  ) /_/  __/ /    
/_/  /_/_/____/\__/\___/_/     
SERVICII SCRIPTING DE CALITATE
Pagina     Scripting     pawn
  • 0
Posted

Parctic astea sunt sloturile de masini, uite codu-l

Spoiler

    else if(strcmp(item, "slot1", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey] [0] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey1='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot2", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][1] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey2='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot3", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][2] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey3='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot4", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][3] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey4='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot5", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][4] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey5='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot6", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][5] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey6='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot7", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][6] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey7='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot8", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][7] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey8='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot9", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][8] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey9='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }
    else if(strcmp(item, "slot10", true) == 0) {
        if(userid != INVALID_PLAYER_ID) {
            PlayerInfo[userid][pCarKey][9] = valoare;
            if(valoare > 0) {
                format(CarInfo[valoare][cOwner], 256, GetName(userid));
                CarInfo[valoare][Userid] = PlayerInfo[userid][pSQLID];
                format(query, sizeof(query), "UPDATE `cars` SET `Userid`='%d', `Name`='%s' WHERE `ID`='%d'", PlayerInfo[userid][pSQLID], GetName(userid), PlayerInfo[userid][pCarKey][0]);
                mysql_query(SQL, query);
            }
        }
        mysql_format(SQL, string, sizeof(string), "UPDATE users SET CarKey10='%d' WHERE `name`='%s' LIMIT 1", valoare, id);
        mysql_tquery(SQL, string, "", "");
    }

 

  • 0
Posted

la inceputu scriptului, pune

new pCarKey

 

nu stiu exact locu unde tre sa-ti vina.. daca nu cauta in tot scriptu tau daca ai asa ceva

 

new pCarKey

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • 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.