28.11.2012, 20:08
What about it?
It will create the object in front of the player.
It will create the object in front of the player.
PHP код:
new ObjID = strval(params);
new Float:X, Float:Y, Float:Z, Float:Ang;
GetPlayerPos(playerid, X, Y, Z);
GetPlayerFacingAngle(playerid, Ang);
X += (3 * floatsin(-Ang, degrees));
Y += (3 * floatcos(-Ang, degrees));
CreateObject(ObjID, X, Y, Z, 0.0, 0.0, Ang);