Smoother ped heading calibration
This commit is contained in:
parent
fa4fe2c10f
commit
87dfc18d91
@ -694,7 +694,12 @@ namespace RageCoop.Client
|
||||
{
|
||||
if (!IsAiming && !MainPed.IsGettingUp)
|
||||
{
|
||||
MainPed.Heading=Heading;
|
||||
var cur=MainPed.Heading;
|
||||
var diff=Heading-cur;
|
||||
if (diff > 180) { diff = diff - 360; }
|
||||
else if (diff < -180) { diff = 360 + diff; }
|
||||
|
||||
MainPed.Heading=cur+diff/2;
|
||||
}
|
||||
MainPed.Velocity=Velocity+5*dist*(Position-MainPed.ReadPosition());
|
||||
}
|
||||
|
@ -93,6 +93,8 @@ namespace RageCoop.Client
|
||||
public static bool AddPlayer()
|
||||
{
|
||||
Ped p = Game.Player.Character;
|
||||
// var clipset=p.Gender==Gender.Male? "MOVE_M@TOUGH_GUY@" : "MOVE_F@TOUGH_GUY@";
|
||||
// Function.Call(Hash.SET_PED_MOVEMENT_CLIPSET,p,clipset,1f);
|
||||
SyncedPed player = GetPedByID(Main.LocalPlayerID);
|
||||
if (player==null)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user