Last active
April 17, 2018 14:59
-
-
Save tsubaki/c6f9776dc67e14e4deab9bbe3c6e1c1a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.Experimental.LowLevel; | |
public class SpawnSystem | |
{ | |
[RuntimeInitializeOnLoadMethod()] | |
static void Init() | |
{ | |
var mySystem = new PlayerLoopSystem() | |
{ | |
type = typeof(MyLoopSystemUpdate), | |
updateDelegate = () => | |
{ | |
Debug.Log("DO IT!!!"); | |
} | |
}; | |
var playerLoop = new PlayerLoopSystem(); | |
playerLoop.subSystemList = new PlayerLoopSystem[] { mySystem }; | |
PlayerLoop.SetPlayerLoop(playerLoop); | |
} | |
public struct MyLoopSystemUpdate{ } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment