Add BRUISER3, BRUTUS3, MONSTER5 weapon sync (closes #26)
This commit is contained in:
parent
ae10da874b
commit
adb9439226
@ -110,6 +110,20 @@ namespace RageCoop.Client
|
|||||||
private bool _lastDead;
|
private bool _lastDead;
|
||||||
private void OnTick(object sender, EventArgs e)
|
private void OnTick(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
|
/*
|
||||||
|
unsafe
|
||||||
|
{
|
||||||
|
var stationName = Function.Call<string>(Hash.GET_RADIO_STATION_NAME, Game.RadioStation);
|
||||||
|
|
||||||
|
//_GET_CURRENT_RADIO_TRACK_NAME
|
||||||
|
var currentTrack = Function.Call<int>((Hash)0x34D66BC058019CE0, stationName);
|
||||||
|
Function.Call(Hash.SET_RADIO_TRACK, "RADIO_03_HIPHOP_NEW", "ARM1_RADIO_STARTS");
|
||||||
|
return currentTrack;
|
||||||
|
|
||||||
|
var h1 = Function.Call<int>(Hash._GET_CURRENT_RADIO_STATION_HASH);
|
||||||
|
return $"{h1},{h2},{s},{s1}";
|
||||||
|
}
|
||||||
|
*/
|
||||||
P= Game.Player.Character;
|
P= Game.Player.Character;
|
||||||
PlayerPosition=P.ReadPosition();
|
PlayerPosition=P.ReadPosition();
|
||||||
FPS=Game.FPS;
|
FPS=Game.FPS;
|
||||||
@ -190,18 +204,8 @@ namespace RageCoop.Client
|
|||||||
_lastDead=P.IsDead;
|
_lastDead=P.IsDead;
|
||||||
Ticked++;
|
Ticked++;
|
||||||
}
|
}
|
||||||
float p1;
|
|
||||||
float p2;
|
|
||||||
private void OnKeyDown(object sender, KeyEventArgs e)
|
private void OnKeyDown(object sender, KeyEventArgs e)
|
||||||
{
|
{
|
||||||
if (e.KeyCode==Keys.Right)
|
|
||||||
{
|
|
||||||
p1+=0.05f;
|
|
||||||
}
|
|
||||||
if (e.KeyCode==Keys.Up)
|
|
||||||
{
|
|
||||||
p2+=0.05f;
|
|
||||||
}
|
|
||||||
if (MainChat.Focused)
|
if (MainChat.Focused)
|
||||||
{
|
{
|
||||||
MainChat.OnKeyDown(e.KeyCode);
|
MainChat.OnKeyDown(e.KeyCode);
|
||||||
|
@ -767,13 +767,9 @@ namespace RageCoop.Client
|
|||||||
Function.Call(Hash.TASK_DRIVE_BY, MainPed, 0, 0, AimCoords.X, AimCoords.Y, AimCoords.Z, 1, 100, 1, FiringPattern.SingleShot);
|
Function.Call(Hash.TASK_DRIVE_BY, MainPed, 0, 0, AimCoords.X, AimCoords.Y, AimCoords.Z, 1, 100, 1, FiringPattern.SingleShot);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else if (_lastDriveBy || MainPed.IsTaskActive(TaskType.CTaskAimGunVehicleDriveBy))
|
||||||
{
|
{
|
||||||
if (MainPed.IsTaskActive(TaskType.CTaskAimGunVehicleDriveBy))
|
MainPed.Task.ClearAll();
|
||||||
{
|
|
||||||
|
|
||||||
MainPed.Task.ClearAll();
|
|
||||||
}
|
|
||||||
_lastDriveBy=false;
|
_lastDriveBy=false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -79,6 +79,18 @@ namespace RageCoop.Client
|
|||||||
BulletsShot++;
|
BulletsShot++;
|
||||||
switch (v.Model.Hash)
|
switch (v.Model.Hash)
|
||||||
{
|
{
|
||||||
|
// BRUISER3
|
||||||
|
case -2042350822:
|
||||||
|
return BulletsShot%2==0 ? 52 : 50;
|
||||||
|
|
||||||
|
// BRUTUS3
|
||||||
|
case 2038858402:
|
||||||
|
return 84;
|
||||||
|
|
||||||
|
// MONSTER5
|
||||||
|
case -715746948:
|
||||||
|
return BulletsShot%2==0 ? 63 : 65;
|
||||||
|
|
||||||
// JB7002
|
// JB7002
|
||||||
case 394110044:
|
case 394110044:
|
||||||
return BulletsShot%2==0 ? 54 : 53;
|
return BulletsShot%2==0 ? 54 : 53;
|
||||||
@ -193,7 +205,15 @@ namespace RageCoop.Client
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
public static int GetMuzzleTurret(this Vehicle v)
|
||||||
|
{
|
||||||
|
switch (v.Model.Hash)
|
||||||
|
{
|
||||||
|
default:
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
public static bool IsUsingProjectileWeapon(this Ped p)
|
public static bool IsUsingProjectileWeapon(this Ped p)
|
||||||
{
|
{
|
||||||
var vp = p.VehicleWeapon;
|
var vp = p.VehicleWeapon;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user