Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
An editor-side Update() equivalent
private void OnEnable() {
EditorApplication.update += OnUpdate;
}
private void OnDisable() {
EditorApplication.update -= OnUpdate;
}
private void OnUpdate() {
// do things
// force loop update so that inputs aren't required
EditorApplication.QueuePlayerLoopUpdate();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment