From e127ad39e742396030352240d829bc903b1d4464 Mon Sep 17 00:00:00 2001 From: Sophia Pearson Date: Mon, 3 Oct 2022 22:22:50 +0200 Subject: godot: inital Godot 4 migration --- Scripts/GodotExtensions/ArrayExtensions.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Scripts/GodotExtensions/ArrayExtensions.cs') diff --git a/Scripts/GodotExtensions/ArrayExtensions.cs b/Scripts/GodotExtensions/ArrayExtensions.cs index aa3a9c4..2712232 100644 --- a/Scripts/GodotExtensions/ArrayExtensions.cs +++ b/Scripts/GodotExtensions/ArrayExtensions.cs @@ -1,11 +1,12 @@ using System; +using Godot; using Godot.Collections; namespace Texty.Scripts.GodotExtensions { public static class ArrayExtensions { - public static void ForEach(this Array array, Action action) + public static void ForEach<[MustBeVariant] T>(this Array array, Action action) { foreach (var element in array) action.Invoke(element); } -- cgit v1.2.3