21.01.2014, 17:38
That is because your angles should be the same value for both the players facing angle try this.
Is a bad idea to do it the way your trying to do it as you might need the same function it will be easier to update the object position with less copy paste code. Does this happen to be for a map editor ?
pawn Code:
stock bool:GetPosInFrontOfPoint(&Float:OutputX, &Float:OutputY, Float:Angle, Float:Distance)
{
if(!Distance) return false;
OutputX += floatmul(Distance, floatsin(-Angle, degrees));
OutputY += floatmul(Distance, floatcos(-Angle, degrees));
return true;
}