diff --git a/EXILED/Exiled.API/Features/Player.cs b/EXILED/Exiled.API/Features/Player.cs
index 197812f710..884230151f 100644
--- a/EXILED/Exiled.API/Features/Player.cs
+++ b/EXILED/Exiled.API/Features/Player.cs
@@ -608,7 +608,7 @@ public ScpSpawnPreferences.SpawnPreferences ScpPreferences
public bool HasFlashlightModuleEnabled => CurrentItem is Firearm firearm && firearm.FlashlightEnabled;
///
- /// Gets a value indicating whether the player is jumping.
+ /// Gets or sets a value indicating whether the player is jumping.
///
public bool IsJumping
{
diff --git a/EXILED/Exiled.Events/Handlers/Internal/ClientStarted.cs b/EXILED/Exiled.Events/Handlers/Internal/ClientStarted.cs
index 46e1f5881d..7fd6df8af0 100644
--- a/EXILED/Exiled.Events/Handlers/Internal/ClientStarted.cs
+++ b/EXILED/Exiled.Events/Handlers/Internal/ClientStarted.cs
@@ -33,14 +33,30 @@ public static void OnClientStarted()
foreach (KeyValuePair prefab in NetworkClient.prefabs)
{
- if(!prefabs.ContainsKey(prefab.Key) && prefab.Value.TryGetComponent(out Component component))
+ if (!prefabs.ContainsKey(prefab.Key))
+ {
+ if (!prefab.Value.TryGetComponent(out NetworkBehaviour component))
+ {
+ Log.Error($"Failed to get component for prefab: {prefab.Value.name} ({prefab.Key})");
+ continue;
+ }
+
prefabs.Add(prefab.Key, (prefab.Value, component));
+ }
}
foreach (NetworkIdentity ragdollPrefab in RagdollManager.AllRagdollPrefabs)
{
- if(!prefabs.ContainsKey(ragdollPrefab.assetId) && ragdollPrefab.gameObject.TryGetComponent(out Component component))
+ if (!prefabs.ContainsKey(ragdollPrefab.assetId))
+ {
+ if (!ragdollPrefab.TryGetComponent(out BasicRagdoll component))
+ {
+ Log.Error($"Failed to get component for ragdoll prefab: {ragdollPrefab.name}");
+ continue;
+ }
+
prefabs.Add(ragdollPrefab.assetId, (ragdollPrefab.gameObject, component));
+ }
}
for (int i = 0; i < EnumUtils.Values.Length; i++)
diff --git a/EXILED/Exiled.Events/Patches/Events/Item/ChangingAttachments.cs b/EXILED/Exiled.Events/Patches/Events/Item/ChangingAttachments.cs
index e4069148ff..6e45fbd152 100644
--- a/EXILED/Exiled.Events/Patches/Events/Item/ChangingAttachments.cs
+++ b/EXILED/Exiled.Events/Patches/Events/Item/ChangingAttachments.cs
@@ -50,7 +50,7 @@ private static IEnumerable Transpiler(IEnumerable i.IsLdarg(1)) - 1;
+ int index = newInstructions.FindIndex(i => i.opcode == OpCodes.Stloc_2) - 2;
List