From 626462ad7796d0995e26ac3320c6320e54ba7dbe Mon Sep 17 00:00:00 2001 From: Timm Luyten Date: Fri, 14 Jun 2024 18:18:40 +0300 Subject: [PATCH] Fix on join attachment error --- code/swb_base/Weapon.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/swb_base/Weapon.cs b/code/swb_base/Weapon.cs index c14c72d3..248aa26d 100644 --- a/code/swb_base/Weapon.cs +++ b/code/swb_base/Weapon.cs @@ -116,7 +116,7 @@ protected override void OnStart() Attachments.ForEach( att => { // Log.Info( "[" + att.Name + "] equipped ->" + att.Equipped ); - if ( att.Equipped ) + if ( att is not null && att.Equipped ) att.Equip(); } ); }