diff --git a/.github/workflows/nightly-build.yaml b/.github/workflows/nightly-build.yaml
index 9924c74..8bd9ab6 100644
--- a/.github/workflows/nightly-build.yaml
+++ b/.github/workflows/nightly-build.yaml
@@ -28,8 +28,6 @@ jobs:
run: dotnet publish RageCoop.Server/RageCoop.Server.csproj --self-contained -p:PublishSingleFile=true -p:PublishTrimmed=false -r win-x64 -o bin/Release/Server/win-x64 -c Release
- name: Build server linux-x64
run: dotnet publish RageCoop.Server/RageCoop.Server.csproj --self-contained -p:PublishSingleFile=true -p:PublishTrimmed=false -r linux-x64 -o bin/Release/Server/linux-x64 -c Release
- - name: Build server linux-arm
- run: dotnet publish RageCoop.Server/RageCoop.Server.csproj --self-contained -p:PublishSingleFile=true -p:PublishTrimmed=false -r linux-arm -o bin/Release/Server/linux-arm -c Release
- uses: vimtor/action-zip@v1
with:
files: bin/Release/Client
@@ -45,11 +43,6 @@ jobs:
files: bin/Release/Server/linux-x64
dest: RageCoop.Server-linux-x64.zip
- - uses: vimtor/action-zip@v1
- with:
- files: bin/Release/Server/linux-arm
- dest: RageCoop.Server-linux-arm.zip
-
- uses: WebFreak001/deploy-nightly@v1.1.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # automatically provided by github actions
@@ -82,17 +75,3 @@ jobs:
asset_name: RageCoop.Server-linux-x64.zip
asset_content_type: application/zip
max_releases: 7
-
-
- - uses: WebFreak001/deploy-nightly@v1.1.0
- env:
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # automatically provided by github actions
- with:
- upload_url: https://uploads.github.com/repos/RAGECOOP/RAGECOOP-V/releases/70603992/assets{?name,label}
- release_id: 70603992
- asset_path: RageCoop.Server-linux-arm.zip
- asset_name: RageCoop.Server-linux-arm.zip
- asset_content_type: application/zip
- max_releases: 7
- - uses: actions/checkout@v2
-
diff --git a/RageCoop.Client/Main.cs b/RageCoop.Client/Main.cs
index a853bc4..1a8f1a9 100644
--- a/RageCoop.Client/Main.cs
+++ b/RageCoop.Client/Main.cs
@@ -170,7 +170,7 @@ namespace RageCoop.Client
P.Health = 1;
Game.Player.WantedLevel = 0;
Main.Logger.Debug("Player died.");
- Scripting.API.Events.InvokePlayerDied();
+ Scripting.API.Events.InvokePlayerDied(KillMessage());
}
GTA.UI.Screen.StopEffects();
}
@@ -181,7 +181,7 @@ namespace RageCoop.Client
}
else if (P.IsDead && !_lastDead)
{
- Scripting.API.Events.InvokePlayerDied();
+ Scripting.API.Events.InvokePlayerDied(KillMessage());
}
_lastDead = P.IsDead;
@@ -326,7 +326,8 @@ namespace RageCoop.Client
WorldThread.Traffic(true);
Function.Call(Hash.SET_ENABLE_VEHICLE_SLIPSTREAMING, false);
CoopMenu.DisconnectedMenuSetting();
- GTA.UI.Notification.Show("~r~Disconnected: " + reason);
+ if (reason != "Abort")
+ GTA.UI.Notification.Show("~r~Disconnected: " + reason);
LocalPlayerID = default;
});
Memory.RestorePatches();
@@ -393,5 +394,15 @@ namespace RageCoop.Client
});
}
+ private string KillMessage()
+ {
+ if (P.Killer != null)
+ {
+ var killer = EntityPool.GetPedByHandle(P.Killer.Handle);
+ if (killer != null && killer.ID == killer.Owner.ID)
+ return $"~h~{PlayerList.GetPlayer(LocalPlayerID).Username}~h~ was killed by ~h~{killer.Owner.Username}~h~ ({P.CauseOfDeath})";
+ }
+ return $"~h~{PlayerList.GetPlayer(LocalPlayerID).Username}~h~ died";
+ }
}
}
diff --git a/RageCoop.Client/Menus/CoopMenu.cs b/RageCoop.Client/Menus/CoopMenu.cs
index f87b55c..ceb1e72 100644
--- a/RageCoop.Client/Menus/CoopMenu.cs
+++ b/RageCoop.Client/Menus/CoopMenu.cs
@@ -50,7 +50,7 @@ namespace RageCoop.Client.Menus
{
Menu.Banner.Color = Color.FromArgb(225, 0, 0, 0);
- Menu.Title.Color = Color.FromArgb(255, 165, 0);
+ Menu.BannerText.Color = Color.FromArgb(255, 165, 0);
_usernameItem.Activated += UsernameActivated;
_passwordItem.Activated += _passwordActivated;
diff --git a/RageCoop.Client/Menus/Sub/DebugMenu.cs b/RageCoop.Client/Menus/Sub/DebugMenu.cs
index 83c8e6f..12dd0e1 100644
--- a/RageCoop.Client/Menus/Sub/DebugMenu.cs
+++ b/RageCoop.Client/Menus/Sub/DebugMenu.cs
@@ -25,7 +25,7 @@ namespace RageCoop.Client
static DebugMenu()
{
Menu.Banner.Color = Color.FromArgb(225, 0, 0, 0);
- Menu.Title.Color = Color.FromArgb(255, 165, 0);
+ Menu.BannerText.Color = Color.FromArgb(255, 165, 0);
DiagnosticMenu.Opening += (sender, e) =>
diff --git a/RageCoop.Client/Menus/Sub/DevToolMenu.cs b/RageCoop.Client/Menus/Sub/DevToolMenu.cs
index 943547b..4ce8a6a 100644
--- a/RageCoop.Client/Menus/Sub/DevToolMenu.cs
+++ b/RageCoop.Client/Menus/Sub/DevToolMenu.cs
@@ -22,7 +22,7 @@ namespace RageCoop.Client
static DevToolMenu()
{
Menu.Banner.Color = Color.FromArgb(225, 0, 0, 0);
- Menu.Title.Color = Color.FromArgb(255, 165, 0);
+ Menu.BannerText.Color = Color.FromArgb(255, 165, 0);
enableItem.Activated += enableItem_Activated;
enableItem.Checked = false;
diff --git a/RageCoop.Client/Menus/Sub/ServersMenu.cs b/RageCoop.Client/Menus/Sub/ServersMenu.cs
index 8879f11..fe5e3a3 100644
--- a/RageCoop.Client/Menus/Sub/ServersMenu.cs
+++ b/RageCoop.Client/Menus/Sub/ServersMenu.cs
@@ -30,7 +30,7 @@ namespace RageCoop.Client.Menus
static ServersMenu()
{
Menu.Banner.Color = Color.FromArgb(225, 0, 0, 0);
- Menu.Title.Color = Color.FromArgb(255, 165, 0);
+ Menu.BannerText.Color = Color.FromArgb(255, 165, 0);
Menu.Opening += (object sender, System.ComponentModel.CancelEventArgs e) =>
{
@@ -76,7 +76,7 @@ namespace RageCoop.Client.Menus
foreach (ServerInfo server in serverList)
{
string address = $"{server.address}:{server.port}";
- NativeItem tmpItem = new NativeItem($"[{server.country}] {server.name}", $"~b~{address}~s~~n~~g~Version {server.version}.x~s~") { AltTitle = $"[{server.players}/{server.maxPlayers}]" };
+ NativeItem tmpItem = new NativeItem($"[{server.country}] {server.name}", $"~b~{address}~s~~n~~g~Version {server.version}~s~") { AltTitle = $"[{server.players}/{server.maxPlayers}]" };
tmpItem.Activated += (object sender, EventArgs e) =>
{
try
diff --git a/RageCoop.Client/Menus/Sub/SettingsMenu.cs b/RageCoop.Client/Menus/Sub/SettingsMenu.cs
index 8f6e7d2..f3bbc90 100644
--- a/RageCoop.Client/Menus/Sub/SettingsMenu.cs
+++ b/RageCoop.Client/Menus/Sub/SettingsMenu.cs
@@ -17,6 +17,8 @@ namespace RageCoop.Client.Menus
private static readonly NativeCheckboxItem _disableTrafficItem = new NativeCheckboxItem("Disable Traffic (NPCs/Vehicles)", "Local traffic only", Main.Settings.DisableTraffic);
private static readonly NativeCheckboxItem _flipMenuItem = new NativeCheckboxItem("Flip menu", Main.Settings.FlipMenu);
private static readonly NativeCheckboxItem _disablePauseAlt = new NativeCheckboxItem("Disable Alternate Pause", "Don't freeze game time when Esc pressed", Main.Settings.DisableAlternatePause);
+ private static readonly NativeCheckboxItem _showBlip = new NativeCheckboxItem("Show player blip", "Show other player's blip on map", Main.Settings.ShowPlayerBlip);
+ private static readonly NativeCheckboxItem _showNametag = new NativeCheckboxItem("Show player nametag", "Show other player's nametag on your screen", Main.Settings.ShowPlayerNameTag);
private static readonly NativeCheckboxItem _disableVoice = new NativeCheckboxItem("Enable voice", "Check your GTA:V settings to find the right key on your keyboard for PushToTalk and talk to your friends", Main.Settings.Voice);
private static readonly NativeItem _menuKey = new NativeItem("Menu Key", "The key to open menu", Main.Settings.MenuKey.ToString());
@@ -26,7 +28,7 @@ namespace RageCoop.Client.Menus
static SettingsMenu()
{
Menu.Banner.Color = Color.FromArgb(225, 0, 0, 0);
- Menu.Title.Color = Color.FromArgb(255, 165, 0);
+ Menu.BannerText.Color = Color.FromArgb(255, 165, 0);
_disableTrafficItem.CheckboxChanged += DisableTrafficCheckboxChanged;
_disablePauseAlt.CheckboxChanged += DisablePauseAltCheckboxChanged;
@@ -35,6 +37,16 @@ namespace RageCoop.Client.Menus
_menuKey.Activated += ChaneMenuKey;
_passengerKey.Activated += ChangePassengerKey;
_vehicleSoftLimit.Activated += VehicleSoftLimitActivated;
+ _showBlip.Activated += (s, e) =>
+ {
+ Main.Settings.ShowPlayerBlip = _showBlip.Checked;
+ Util.SaveSettings();
+ };
+ _showNametag.Activated += (s, e) =>
+ {
+ Main.Settings.ShowPlayerNameTag = _showNametag.Checked;
+ Util.SaveSettings();
+ };
Menu.Add(_disableTrafficItem);
Menu.Add(_disablePauseAlt);
@@ -43,6 +55,8 @@ namespace RageCoop.Client.Menus
Menu.Add(_menuKey);
Menu.Add(_passengerKey);
Menu.Add(_vehicleSoftLimit);
+ Menu.Add(_showBlip);
+ Menu.Add(_showNametag);
}
private static void DisableVoiceCheckboxChanged(object sender, EventArgs e)
diff --git a/RageCoop.Client/Networking/Networking.cs b/RageCoop.Client/Networking/Networking.cs
index 6feec5d..5b637c7 100644
--- a/RageCoop.Client/Networking/Networking.cs
+++ b/RageCoop.Client/Networking/Networking.cs
@@ -30,16 +30,16 @@ namespace RageCoop.Client
public static void ToggleConnection(string address, string username = null, string password = null, PublicKey publicKey = null)
{
Menus.CoopMenu.Menu.Visible = false;
- Peer?.Shutdown("Bye");
- if (IsOnServer)
- {
- // ?
- }
- else if (IsConnecting)
+ if (IsConnecting)
{
_publicKeyReceived.Set();
IsConnecting = false;
- Notification.Show("Connection has been canceled");
+ Main.QueueAction(() => Notification.Show("Connection has been canceled"));
+ Peer?.Shutdown("Bye");
+ }
+ else if (IsOnServer)
+ {
+ Peer?.Shutdown("Bye");
}
else
{
diff --git a/RageCoop.Client/Networking/Receive.cs b/RageCoop.Client/Networking/Receive.cs
index da05784..fcea653 100644
--- a/RageCoop.Client/Networking/Receive.cs
+++ b/RageCoop.Client/Networking/Receive.cs
@@ -159,6 +159,7 @@ namespace RageCoop.Client
Main.Logger.Error(ex);
Peer.Shutdown($"Packet Error [{packetType}]");
#endif
+ _recycle = false;
}
break;
}
@@ -293,7 +294,7 @@ namespace RageCoop.Client
{
recycle = false;
// Dispatch to script thread
- Main.QueueAction(() => { SyncEvents.HandleEvent(packetType, msg); Peer.Recycle(msg); return true; });
+ Main.QueueAction(() => { SyncEvents.HandleEvent(packetType, msg); return true; });
}
break;
}
@@ -305,7 +306,9 @@ namespace RageCoop.Client
if (c == null)
{
// Main.Logger.Debug($"Creating character for incoming sync:{packet.ID}");
- EntityPool.ThreadSafe.Add(c = new SyncedPed(packet.ID));
+ if (EntityPool.allPeds.Length < Main.Settings.GlobalPedSoftLimit || PlayerList.Players.ContainsKey(packet.ID))
+ EntityPool.ThreadSafe.Add(c = new SyncedPed(packet.ID));
+ else return;
}
PedDataFlags flags = packet.Flags;
c.ID = packet.ID;
@@ -353,7 +356,9 @@ namespace RageCoop.Client
SyncedVehicle v = EntityPool.GetVehicleByID(packet.ID);
if (v == null)
{
- EntityPool.ThreadSafe.Add(v = new SyncedVehicle(packet.ID));
+ if (EntityPool.allVehicles.Length < Main.Settings.GlobalVehicleSoftLimit)
+ EntityPool.ThreadSafe.Add(v = new SyncedVehicle(packet.ID));
+ else return;
}
if (v.IsLocal) { return; }
v.ID = packet.ID;
@@ -393,7 +398,9 @@ namespace RageCoop.Client
{
if (packet.Flags.HasProjDataFlag(ProjectileDataFlags.Exploded)) { return; }
// Main.Logger.Debug($"Creating new projectile: {(WeaponHash)packet.WeaponHash}");
- EntityPool.ThreadSafe.Add(p = new SyncedProjectile(packet.ID));
+ if (EntityPool.allProjectiles.Length < Main.Settings.GlobalProjectileSoftLimit)
+ EntityPool.ThreadSafe.Add(p = new SyncedProjectile(packet.ID));
+ else return;
}
p.Flags = packet.Flags;
p.Position = packet.Position;
diff --git a/RageCoop.Client/Properties/AssemblyInfo.cs b/RageCoop.Client/Properties/AssemblyInfo.cs
index 2c99ea5..e6b2d99 100644
--- a/RageCoop.Client/Properties/AssemblyInfo.cs
+++ b/RageCoop.Client/Properties/AssemblyInfo.cs
@@ -15,8 +15,8 @@ using System.Resources;
[assembly: AssemblyCulture("")]
-// Version informationr(
-[assembly: AssemblyVersion("1.5.4.4")]
-[assembly: AssemblyFileVersion("1.5.4.4")]
+// Version information
+[assembly: AssemblyVersion("1.5.4.6")]
+[assembly: AssemblyFileVersion("1.5.4.6")]
[assembly: NeutralResourcesLanguageAttribute( "en-US" )]
diff --git a/RageCoop.Client/RageCoop.Client.csproj b/RageCoop.Client/RageCoop.Client.csproj
index d0d44ef..60b0988 100644
--- a/RageCoop.Client/RageCoop.Client.csproj
+++ b/RageCoop.Client/RageCoop.Client.csproj
@@ -90,7 +90,7 @@
..\packages\SharpZipLib.1.3.3\lib\net45\ICSharpCode.SharpZipLib.dll
-
+
False
..\libs\LemonUI.SHVDN3.dll
diff --git a/RageCoop.Client/Scripting/API.cs b/RageCoop.Client/Scripting/API.cs
index 0cd5ff3..8c7bb4c 100644
--- a/RageCoop.Client/Scripting/API.cs
+++ b/RageCoop.Client/Scripting/API.cs
@@ -91,7 +91,7 @@ namespace RageCoop.Client.Scripting
///
/// The local player is dead
///
- public static event EmptyEvent OnPlayerDied;
+ public static event EventHandler OnPlayerDied;
///
/// A local vehicle is spawned
@@ -133,7 +133,7 @@ namespace RageCoop.Client.Scripting
internal static void InvokeVehicleDeleted(SyncedVehicle v) { OnVehicleDeleted?.Invoke(null, v); }
internal static void InvokePedSpawned(SyncedPed p) { OnPedSpawned?.Invoke(null, p); }
internal static void InvokePedDeleted(SyncedPed p) { OnPedDeleted?.Invoke(null, p); }
- internal static void InvokePlayerDied() { OnPlayerDied?.Invoke(); }
+ internal static void InvokePlayerDied(string m) { OnPlayerDied?.Invoke(null, m); }
internal static void InvokeTick() { OnTick?.Invoke(); }
internal static void InvokeKeyDown(object s, KeyEventArgs e) { OnKeyDown?.Invoke(s, e); }
diff --git a/RageCoop.Client/Scripting/BaseScript.cs b/RageCoop.Client/Scripting/BaseScript.cs
index 8d489ae..e7f3a6a 100644
--- a/RageCoop.Client/Scripting/BaseScript.cs
+++ b/RageCoop.Client/Scripting/BaseScript.cs
@@ -16,7 +16,7 @@ namespace RageCoop.Client.Scripting
{
API.Events.OnPedDeleted += (s, p) => { API.SendCustomEvent(CustomEvents.OnPedDeleted, p.ID); };
API.Events.OnVehicleDeleted += (s, p) => { API.SendCustomEvent(CustomEvents.OnVehicleDeleted, p.ID); };
- API.Events.OnPlayerDied += () => { API.SendCustomEvent(CustomEvents.OnPlayerDied); };
+ API.Events.OnPlayerDied += (s, m) => { API.SendCustomEvent(CustomEvents.OnPlayerDied, m); };
API.RegisterCustomEventHandler(CustomEvents.SetAutoRespawn, SetAutoRespawn);
API.RegisterCustomEventHandler(CustomEvents.SetDisplayNameTag, SetDisplayNameTag);
@@ -31,7 +31,7 @@ namespace RageCoop.Client.Scripting
API.RegisterCustomEventHandler(CustomEvents.UpdatePedBlip, UpdatePedBlip);
API.RegisterCustomEventHandler(CustomEvents.IsHost, (e) => { _isHost = (bool)e.Args[0]; });
API.RegisterCustomEventHandler(CustomEvents.WeatherTimeSync, WeatherTimeSync);
- API.RegisterCustomEventHandler(CustomEvents.OnPlayerDied, (e) => { GTA.UI.Notification.Show($"~h~{e.Args[0]}~h~ died."); });
+ API.RegisterCustomEventHandler(CustomEvents.OnPlayerDied, (e) => { GTA.UI.Notification.Show((string)e.Args[0]); });
Task.Run(() =>
{
while (true)
diff --git a/RageCoop.Client/Settings.cs b/RageCoop.Client/Settings.cs
index 654c49e..b60e91e 100644
--- a/RageCoop.Client/Settings.cs
+++ b/RageCoop.Client/Settings.cs
@@ -67,6 +67,22 @@ namespace RageCoop.Client
/// The game won't spawn more NPC traffic if the limit is exceeded. -1 for unlimited (not recommended).
///
public int WorldPedSoftLimit { get; set; } = 30;
+
+ ///
+ /// The mod won't sync more vehicles if the limit is exceeded.
+ ///
+ public int GlobalVehicleSoftLimit { get; set; } = 100;
+
+ ///
+ /// The mod won't sync more peds if the limit is exceeded.
+ ///
+ public int GlobalPedSoftLimit { get; set; } = 100;
+
+ ///
+ /// The mod won't sync more projectiles if the limit is exceeded.
+ ///
+ public int GlobalProjectileSoftLimit { get; set; } = 100;
+
///
/// The directory where log and resources downloaded from server will be placed.
///
@@ -76,5 +92,15 @@ namespace RageCoop.Client
/// Show the owner name of the entity you're aiming at
///
public bool ShowEntityOwnerName { get; set; } = false;
+
+ ///
+ /// Show other player's nametag on your screen
+ ///
+ public bool ShowPlayerNameTag { get; set; } = true;
+
+ ///
+ /// Show other player's blip on map
+ ///
+ public bool ShowPlayerBlip { get; set; } = true;
}
}
diff --git a/RageCoop.Client/Sync/Entities/Ped/SyncedPed.cs b/RageCoop.Client/Sync/Entities/Ped/SyncedPed.cs
index 0a5d75e..0452cf3 100644
--- a/RageCoop.Client/Sync/Entities/Ped/SyncedPed.cs
+++ b/RageCoop.Client/Sync/Entities/Ped/SyncedPed.cs
@@ -28,7 +28,7 @@ namespace RageCoop.Client
MainPed = p;
OwnerID = Main.LocalPlayerID;
- Function.Call(Hash.SET_PED_IS_IGNORED_BY_AUTO_OPEN_DOORS, false);
+ //Function.Call(Hash.SET_PED_IS_IGNORED_BY_AUTO_OPEN_DOORS, false);
MainPed.SetConfigFlag((int)PedConfigFlags.CPED_CONFIG_FLAG_DisableHurt, true);
// MainPed.SetConfigFlag((int)PedConfigFlags.CPED_CONFIG_FLAG_DisableMelee, true);
@@ -76,12 +76,13 @@ namespace RageCoop.Client
}
}
- if (((byte)BlipColor == 255) && (PedBlip != null))
+ if (!Main.Settings.ShowPlayerBlip && (byte)BlipColor != 255) BlipColor = (BlipColor)255;
+ if ((byte)BlipColor == 255 && PedBlip != null)
{
PedBlip.Delete();
PedBlip = null;
}
- else if (((byte)BlipColor != 255) && PedBlip == null)
+ else if ((byte)BlipColor != 255 && PedBlip == null)
{
PedBlip = MainPed.AddBlip();
@@ -170,7 +171,7 @@ namespace RageCoop.Client
private void RenderNameTag()
{
- if (!Owner.DisplayNameTag || (MainPed == null) || !MainPed.IsVisible || !MainPed.IsInRange(Main.PlayerPosition, 40f))
+ if (!Owner.DisplayNameTag || !Main.Settings.ShowPlayerNameTag || MainPed == null || !MainPed.IsVisible || !MainPed.IsInRange(Main.PlayerPosition, 40f))
{
return;
}
@@ -597,6 +598,8 @@ namespace RageCoop.Client
MainPed.Task.StandStill(2000);
LastMoving = false;
}
+
+ if (MainPed.IsTaskActive(TaskType.CTaskDiveToGround)) MainPed.Task.ClearAll();
break;
}
SmoothTransition();
diff --git a/RageCoop.Client/Sync/EntityPool.cs b/RageCoop.Client/Sync/EntityPool.cs
index 6bc2022..891e386 100644
--- a/RageCoop.Client/Sync/EntityPool.cs
+++ b/RageCoop.Client/Sync/EntityPool.cs
@@ -43,7 +43,7 @@ namespace RageCoop.Client
#endregion
public static void Cleanup(bool keepPlayer = true, bool keepMine = true)
{
- foreach (var ped in PedsByID.Values)
+ foreach (var ped in PedsByID.Values.ToArray())
{
if ((keepPlayer && (ped.ID == Main.LocalPlayerID)) || (keepMine && (ped.OwnerID == Main.LocalPlayerID))) { continue; }
RemovePed(ped.ID);
@@ -277,8 +277,8 @@ namespace RageCoop.Client
{
ProjectilesByHandle.Remove(p.Handle);
}
- Main.Logger.Debug($"Removing projectile {sp.ID}. Reason:{reason}");
- p.Explode();
+ //Main.Logger.Debug($"Removing projectile {sp.ID}. Reason:{reason}");
+ if (sp.Exploded) p.Explode();
}
ProjectilesByID.Remove(id);
}
@@ -363,7 +363,8 @@ namespace RageCoop.Client
foreach (Ped p in allPeds)
{
SyncedPed c = GetPedByHandle(p.Handle);
- if (c == null && (p != Game.Player.Character))
+ List mainCharacters = new List { PedHash.Michael, PedHash.Franklin, PedHash.Franklin02, PedHash.Trevor };
+ if (c == null && p != Game.Player.Character && !mainCharacters.Contains((PedHash)p.Model.Hash))
{
if (allPeds.Length > Main.Settings.WorldPedSoftLimit && p.PopulationType == EntityPopulationType.RandomAmbient && !p.IsInVehicle())
{
diff --git a/RageCoop.Client/Sync/SyncEvents.cs b/RageCoop.Client/Sync/SyncEvents.cs
index d486fa8..07cda98 100644
--- a/RageCoop.Client/Sync/SyncEvents.cs
+++ b/RageCoop.Client/Sync/SyncEvents.cs
@@ -126,7 +126,7 @@ namespace RageCoop.Client
}
var p = EntityPool.GetPedByID(ownerID)?.MainPed;
- if (p == null) { p = Game.Player.Character; Main.Logger.Warning("Failed to find owner for bullet"); }
+ if (p == null) { return; /* p = Game.Player.Character; Main.Logger.Warning("Failed to find owner for bullet"); */ }
if (!CorePFXAsset.IsLoaded) { CorePFXAsset.Request(); }
if (_lastWeaponHash != weaponHash)
{
diff --git a/RageCoop.Server/Properties/AssemblyInfo.cs b/RageCoop.Server/Properties/AssemblyInfo.cs
index f056db6..1242a23 100644
--- a/RageCoop.Server/Properties/AssemblyInfo.cs
+++ b/RageCoop.Server/Properties/AssemblyInfo.cs
@@ -15,7 +15,7 @@ using System.Resources;
[assembly: AssemblyCulture("")]
// Version information
-[assembly: AssemblyVersion("1.5.4.3")]
-[assembly: AssemblyFileVersion("1.5.4.3")]
+[assembly: AssemblyVersion("1.5.4.5")]
+[assembly: AssemblyFileVersion("1.5.4.5")]
[assembly: NeutralResourcesLanguageAttribute( "en-US" )]
diff --git a/RageCoop.Server/Scripting/BaseScript.cs b/RageCoop.Server/Scripting/BaseScript.cs
index 7fd24b8..537d84b 100644
--- a/RageCoop.Server/Scripting/BaseScript.cs
+++ b/RageCoop.Server/Scripting/BaseScript.cs
@@ -38,7 +38,7 @@ namespace RageCoop.Server.Scripting
});
API.RegisterCustomEventHandler(CustomEvents.OnPlayerDied, (e) =>
{
- API.SendCustomEventQueued(API.GetAllClients().Values.Where(x => x != e.Client).ToList(), CustomEvents.OnPlayerDied, e.Client.Username);
+ API.SendCustomEventQueued(API.GetAllClients().Values.Where(x => x != e.Client).ToList(), CustomEvents.OnPlayerDied, e.Args);
});
API.Events.OnChatMessage += (s, e) =>
Server.Logger?.Info((e.Client?.Username ?? e.ClaimedSender ?? "Unknown") + ": " + e.Message);
diff --git a/libs/LemonUI.SHVDN3.dll b/libs/LemonUI.SHVDN3.dll
index c998d32..2f0f66d 100644
Binary files a/libs/LemonUI.SHVDN3.dll and b/libs/LemonUI.SHVDN3.dll differ