14.12.2016, 20:22
PHP Code:
new id=Iter_Free(fObjects);
if(id==-1)return scm(pid,-1,"No free slot to add object!");
Iter_Add(fObjects,id);
new s[200];
format(s,sizeof(s),"INSERT INTO objects(mid,x,y,z,rx,ry,rz) VALUES('%d','%f','%f','%f','%f','%f','%f')",mid,x,y,z,rx,ry,rz);
new Cache:cq=mysql_query(sc,s);
Object[id][sid]=cache_insert_id();
cache_delete(cq);