Is this possible? moving objects upon z level (smoothly)
#1

Well, I came across a problem with my lastest work, I'd like to move a missile/object with z level

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;
}
but it lags severely
Reply


Messages In This Thread
Is this possible? moving objects upon z level (smoothly) - by Donya - 02.08.2011, 00:45

Forum Jump:


Users browsing this thread: 1 Guest(s)