public static void NukeEntireRemoSystemAndGoBackToNormalDSAnimStudio() { RemoEventSim.Clear(); ViewportInteractor = null; AnimContainer = null; CurrentCutSibcam = null; CurrentCut = null; RemoName = "scnXXXXXX"; remoCutsLoaded.Clear(); remoCutHkxDict.Clear(); remoCutSibcamDict.Clear(); CurrentCutCameraMotion = null; CurrentCutFoV = null; GFX.World.ClearCustomCameraView_Override(); GFX.World.ClearCustomCameraView_Additive(); CurrentCutHits.Clear(); CurrentCutOtherBlocks.Clear(); DisposeAllModels(); }
public static void UpdateRemoTime(float time) { // JUST FOR MATH TESTING //BakeSibcam(); float frame = time / (1f / 30f); int frameFloor = Math.Min(Math.Max((int)Math.Floor(frame), 0), CurrentCutCameraMotion.Length - 1); int frameCeil = Math.Min(Math.Max((int)Math.Ceiling(frame), 0), CurrentCutCameraMotion.Length - 1); float frameMod = frame % 1; if (CurrentCutCameraMotion == null || CurrentCutFoV == null) { return; } var a = CurrentCutCameraMotion[frameFloor]; var fovA = CurrentCutFoV[frameFloor]; if (frameCeil < CurrentCutSibcam.CameraAnimation.Count) { var b = CurrentCutCameraMotion[frameCeil]; a = NewBlendableTransform.Lerp(a, b, frameMod); var fovB = CurrentCutFoV[frameCeil]; fovA = MathHelper.Lerp(fovA, fovB, frameMod); } if (EnableRemoCameraInViewport) { GFX.World.SetCustomCameraView_Override(a, fovA); } else { GFX.World.ClearCustomCameraView_Override(); } RemoEventSim.Update(ViewportInteractor.Graph, time); }