12.10.2010, 16:18
I am using this code to print and save the gangzone, but it doesn't print the hexadecimal right!!!
The COLOR prints "!!!!-'"
%x Inserts a number in hexadecimal notation.
Код:
printf("%x", COLOR);
format(string, sizeof(string), "INSERT INTO gangzones (SQLID, MinX, MinY, MaxX, MaxY, COLOR, Owner) VALUES ('%i', '%f', '%f', '%f', '%f', '%x', '%i')",
minx,miny,maxx,maxy, COLOR, -1);
mysql_query(string);
mysql_query("SELECT MAX(SQLID) FROM gangzones");
mysql_store_result();
%x Inserts a number in hexadecimal notation.

