mirror of
https://github.com/RHeavenStudio/HeavenStudio.git
synced 2025-06-12 11:27:39 +02:00
Rhythm Rally: Fixed broken background in editor preview. FreeCam components can now be enabled/disabled with ctrl+shift+D.
This commit is contained in:
@ -34,7 +34,7 @@ namespace RhythmHeavenMania
|
||||
public float startOffset;
|
||||
public bool playOnStart;
|
||||
public float startBeat;
|
||||
private GameObject currentGameO;
|
||||
[NonSerialized] public GameObject currentGameO;
|
||||
public bool autoplay;
|
||||
|
||||
public event Action<float> onBeatChanged;
|
||||
|
@ -134,6 +134,14 @@ namespace RhythmHeavenMania.Editor
|
||||
{
|
||||
CommandManager.instance.Redo();
|
||||
}
|
||||
|
||||
if (Input.GetKey(KeyCode.LeftShift))
|
||||
{
|
||||
if (Input.GetKeyDown(KeyCode.D))
|
||||
{
|
||||
ToggleDebugCam();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (Timeline.instance.timelineState.selected && Editor.instance.canSelect)
|
||||
@ -415,5 +423,18 @@ namespace RhythmHeavenMania.Editor
|
||||
{
|
||||
return (rectTransform.gameObject.activeSelf && RectTransformUtility.RectangleContainsScreenPoint(rectTransform, Input.mousePosition, Editor.instance.EditorCamera));
|
||||
}
|
||||
|
||||
public void ToggleDebugCam()
|
||||
{
|
||||
var game = GameManager.instance.currentGameO;
|
||||
|
||||
if (game != null)
|
||||
{
|
||||
foreach(FreeCam c in game.GetComponentsInChildren<FreeCam>(true))
|
||||
{
|
||||
c.enabled = !c.enabled;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user