Use Init for dotnet commandline

This commit is contained in:
Simon Lübeß
2022-04-27 12:22:53 +02:00
parent 8c53f21690
commit e51fc77c3f
4 changed files with 313 additions and 4 deletions
@@ -14,8 +14,10 @@ public abstract class ScriptableEntity
[UnmanagedCallersOnly]
public static void UpdateEntity(IntPtr entityPtr)
{
GCHandle entityHandle = GCHandle.FromIntPtr(entityPtr);
Console.WriteLine("Trying to do stuff!");
GCHandle entityHandle = GCHandle.FromIntPtr(entityPtr);
if (entityHandle.Target is ScriptableEntity entity)
{
entity.OnUpdate();