02.08.2011, 00:45
(
Последний раз редактировалось Donya; 02.08.2011 в 02:01.
)
Well, I came across a problem with my lastest work, I'd like to move a missile/object with z level
I tried like
but it lags severely
I tried like
pawn Код:
new Float:opos[2], Float:G_Z;
GetDynamicObjectPos(objectid, opos[0], opos[1], G_Z);
GetPointZPos(opos[0], opos[1], G_Z);
/*if(!(G_Z < opos[2] - 7.0)) */
MoveDynamicObject(objectid, opos[0], opos[1], G_Z + 0.9, 10000.0);
public OnDynamicObjectMoved(objectid)
{
if(Move_ObjectX[objectid] != 0.0 && Move_ObjectY[objectid] != 0.0)
{
new Float:opos[2], Float:G_Z;
GetDynamicObjectPos(objectid, opos[0], opos[1], G_Z);
GetPointZPos(opos[0], opos[1], G_Z);
MoveDynamicObject(objectid, Move_ObjectX[objectid], Move_ObjectY[objectid], G_Z + 0.9, MISSILE_SPEED);
}
return 1;
}