Jump to content

[REZOLVAT] Urgent.


MasterAdv
 Share

Recommended Posts

De ce primesc eroarea asta?

C:\Users\Mihai\Desktop\gmm.pwn(14925) : error 021: symbol already defined: "GetServerVehicles"
Pawn compiler 3.10.7 Copyright © 1997-2006, ITB CompuPhase
 
 
1 Error.
 
Doar o data o am in GM.
function GetServerVehicles() {
new szQuery[256], vehicles;
    format(szQuery, sizeof(szQuery), "SELECT * FROM `svehicles`");
    new Cache: result = mysql_query(SQL, szQuery);
    vehicles = cache_get_row_count ();
    cache_delete(result);
return vehicles;
}

 

Link to comment
Share on other sites

Mai ai definit undeva "GetServerVehicles", incearca sa redenumesti functia.

Aia am facut, am pus GetSSVehicles, doar 1 masina pot face, o fac pe prima merge, o fac pe a 2-a nu mai merge niciuna.

Nu mai este niciunde.

Link to comment
Share on other sites

  • Administrator

@@MasterAdv

 

Functiile nu returneaza altceva decat 1 si 0. (true si false)

 

Tu, trebuie sa faci un stock ca sa poti returna o valoare customizabila.

stock GetServerVehicles() {
    new szQuery[ 256 ], vehicles;
    format( szQuery, sizeof szQuery, "SELECT * FROM `svehicles`" );
    new Cache: result = mysql_query( SQL, szQuery );
    vehicles = cache_get_row_count();
    cache_delete( result );
    return vehicles;
}
Link to comment
Share on other sites

 

@@MasterAdv

 

Functiile nu returneaza altceva decat 1 si 0. (true si false)

 

Tu, trebuie sa faci un stock ca sa poti returna o valoare customizabila.

stock GetServerVehicles() {
    new szQuery[ 256 ], vehicles;
    format( szQuery, sizeof szQuery, "SELECT * FROM `svehicles`" );
    new Cache: result = mysql_query( SQL, szQuery );
    vehicles = cache_get_row_count();
    cache_delete( result );
    return vehicles;
}

Nu functioneaza.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...