12.12.2009, 18:33
Hey guys, i was just checking a script, Bombing Filterscript (by Mauzen) and i noticed a function here:
this is the only thing in the script using MySQL is their something in 0.3 that could maybe remove the MySQL from this as i dont really want to use MySQL but.... please help thanks.
-©un3o.
pawn Код:
public Float:GetGroundZ(Float:x, Float:y) {
new rxy[96];
x = 5.0 * floatround(x / 5.0); //Replace all 5.0 by the MySQL "map resolution"
y = 5.0 * floatround(y / 5.0); //Replace all 5.0 by the MySQL "map resolution"
format(rxy, 96, "SELECT z FROM hmap WHERE x = %d AND y = %d;", floatround(x), floatround(y));
samp_mysql_query(rxy);
samp_mysql_store_result();
samp_mysql_fetch_row(rxy);
return floatstr(rxy);
}
-©un3o.