From 418aa7124170b81486e243784dd3e29e18131920 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20L=C3=BCbe=C3=9F?= Date: Sun, 31 Dec 2023 17:22:04 +0100 Subject: [PATCH] ScriptCore: Fixed adding element to arrays --- ScriptCore/Editor/EntityEditor.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ScriptCore/Editor/EntityEditor.cs b/ScriptCore/Editor/EntityEditor.cs index b1c64bc..dc7b0e7 100644 --- a/ScriptCore/Editor/EntityEditor.cs +++ b/ScriptCore/Editor/EntityEditor.cs @@ -642,7 +642,7 @@ internal class EntityEditor newIndex = list.Count; Array newArray = Array.CreateInstance(elementType, list.Count + 1); - Array.Copy((Array)list, newArray, newArray.Length); + Array.Copy((Array)list, newArray, list.Count); newList = newArray; }