06.11.2012, 13:47
Hello guys, i got a problem with mysql load.Firstly i made a new house system for my server.But something wrong.
Problem is:
When i'm loading the functions from mysql table.Labels,pickups and house positions cannot load.I looked toward to mysql logs.But everything are fine.Now i'm writing the pawn codes.Please help me about this issue.Thank you for help already.
Problem is:
When i'm loading the functions from mysql table.Labels,pickups and house positions cannot load.I looked toward to mysql logs.But everything are fine.Now i'm writing the pawn codes.Please help me about this issue.Thank you for help already.
pawn Код:
function EvleriYukle()
{
mysql_query("SELECT NULL FROM `evler`"); mysql_store_result(); toplamevler = mysql_num_rows();
new toplamyuklenenevsayisi = 1;
new formatlama1[600],formatlama2[600];
for(new i = 1; i <= toplamevler; i++)
{
HD[i][ID] = EvInt(i,"ID");
HD[i][owner] = EvStr(i,"owner");
HD[i][price] = EvInt(i,"price");
HD[i][exteriorX] = EvFlo(i,"exteriorX");
HD[i][exteriorY] = EvFlo(i,"exteriorY");
HD[i][exteriorZ] = EvFlo(i,"exteriorZ");
HD[i][interiorX] = EvFlo(i,"interiorX");
HD[i][interiorY] = EvFlo(i,"interiorY");
HD[i][interiorZ] = EvFlo(i,"interiorZ");
HD[i][interiorInt] = EvInt(i,"interiorInt");
HD[i][locked] = EvInt(i,"locked");
format(formatlama1,sizeof(formatlama1),"{0080FF}Ev Sahibi: {FFFFFF}%s\n{0080FF}Ev Durumu: {FFFFFF}Satilik Degil\n{0080FF}Ev Fiyati: {FFFFFF}$%i",HD[i][owner],HD[i][price]);
format(formatlama2,sizeof(formatlama2),"{0080FF}Ev Sahibi: {FFFFFF}YOK\n{0080FF}Ev Durumu: {FFFFFF}Satilik\n{0080FF}Ev Fiyati: {FFFFFF}$%i",HD[i][price]);
if(strlen(HD[i][owner]) > 0){ Create3DTextLabel(formatlama1, -1, HD[i][exteriorX], HD[i][exteriorY], HD[i][exteriorZ], 40.0, 0, 1); CreatePickup(1273, 1, HD[i][exteriorX], HD[i][exteriorY], HD[i][exteriorZ], -1);}
else {Create3DTextLabel(formatlama2, -1, HD[i][exteriorX], HD[i][exteriorY], HD[i][exteriorZ], 40.0, 0, 1); CreatePickup(1273, 1, HD[i][exteriorX], HD[i][exteriorY], HD[i][exteriorZ], -1);}
toplamyuklenenevsayisi++;
}
return 1;
}