private void Update() { ObiProfiler.EnableProfiler(); Interpolate(Time.fixedDeltaTime, accumulatedTime); ObiProfiler.DisableProfiler(); accumulatedTime += Time.deltaTime; }
private void Awake() { if (_instance != null && _instance != this) { DestroyImmediate(this); } else { _instance = this; } }
private void Awake() { if (_instance != null && _instance != this) { DestroyImmediate(this); } else { _instance = this; Oni.EnableProfiler(true); } }
private void Awake() { if (_instance != null && _instance != this) { DestroyImmediate(this); } else { _instance = this; Oni.EnableProfiler(true); numThreads = Oni.GetMaxSystemConcurrency(); } }
private void FixedUpdate() { ObiProfiler.EnableProfiler(); BeginStep(Time.fixedDeltaTime); float substepDelta = Time.fixedDeltaTime / (float)substeps; // Divide the step into multiple smaller substeps: for (int i = 0; i < substeps; ++i) { Substep(Time.fixedDeltaTime, substepDelta, substeps - i); } EndStep(substepDelta); ObiProfiler.DisableProfiler(); accumulatedTime -= Time.fixedDeltaTime; }
public void OnDestroy() { _instance = null; Oni.EnableProfiler(false); }