Beispiel #1
0
        private static IEnumerator SetGoodRateChart_Process()
        {
            yield return(new WaitForEndOfFrame());

            Log.Write("SetFloatingDisplay Start");

            Vector3 ChartStandardLevelPosition = new Vector3(0, 0.25f, 2.25f); /* Original: 0, -0.4, 2.25 */
            Vector3 ChartStandardLevelRotation = new Vector3(35, 0, 0);

            var pos = ChartStandardLevelPosition;
            var rot = Quaternion.Euler(ChartStandardLevelRotation);

            floatingScreenForScore = FloatingScreen.CreateFloatingScreen(new Vector2(105, 65), false, pos, rot);

            floatingScreenForScore.SetRootViewController(BeatSaberUI.CreateViewController <GoodRateViewController>(), true);

            Image image = floatingScreenForScore.GetComponent <Image>();

            image.enabled = false;

            GraphContainer graph = floatingScreenForScore.gameObject.AddComponent <GraphContainer>();

            floatingScreenForScore.rootViewController.gameObject.SetActive(false);
            graph.gameObject.SetActive(false);
        }
Beispiel #2
0
        private void Awake()
        {
            GraphContainer  = transform.Find("GraphContainer").GetComponent <RectTransform>();
            _labelTemplateX = GraphContainer.Find("LabelTemplateX").GetComponent <RectTransform>();
            _labelTemplateY = GraphContainer.Find("LabelTemplateY").GetComponent <RectTransform>();
            _dashTemplateX  = GraphContainer.Find("DashTemplateX").GetComponent <RectTransform>();
            _dashTemplateY  = GraphContainer.Find("DashTemplateY").GetComponent <RectTransform>();

            DotObjects    = new List <GameObject>();
            LinkObjects   = new List <GameObject>();
            LabelXObjects = new List <GameObject>();
            LabelYObjects = new List <GameObject>();
            DashXObjects  = new List <GameObject>();
            DashYObjects  = new List <GameObject>();
        }