Oh yessss Movable Track Sampler
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -84,6 +84,7 @@ GameObject:
|
|||||||
- component: {fileID: 5461587753206792591}
|
- component: {fileID: 5461587753206792591}
|
||||||
- component: {fileID: 5335898105413302274}
|
- component: {fileID: 5335898105413302274}
|
||||||
- component: {fileID: 7343609601733320153}
|
- component: {fileID: 7343609601733320153}
|
||||||
|
- component: {fileID: 2335519274396818332}
|
||||||
m_Layer: 5
|
m_Layer: 5
|
||||||
m_Name: NoteFab
|
m_Name: NoteFab
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
@@ -192,4 +193,29 @@ MonoBehaviour:
|
|||||||
m_TargetGraphic: {fileID: 5335898105413302274}
|
m_TargetGraphic: {fileID: 5335898105413302274}
|
||||||
m_OnClick:
|
m_OnClick:
|
||||||
m_PersistentCalls:
|
m_PersistentCalls:
|
||||||
m_Calls: []
|
m_Calls:
|
||||||
|
- m_Target: {fileID: 2335519274396818332}
|
||||||
|
m_TargetAssemblyTypeName: NotefabContoler, Assembly-CSharp
|
||||||
|
m_MethodName: Onclick
|
||||||
|
m_Mode: 1
|
||||||
|
m_Arguments:
|
||||||
|
m_ObjectArgument: {fileID: 0}
|
||||||
|
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
|
||||||
|
m_IntArgument: 0
|
||||||
|
m_FloatArgument: 0
|
||||||
|
m_StringArgument:
|
||||||
|
m_BoolArgument: 0
|
||||||
|
m_CallState: 2
|
||||||
|
--- !u!114 &2335519274396818332
|
||||||
|
MonoBehaviour:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8453727759659553036}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_EditorHideFlags: 0
|
||||||
|
m_Script: {fileID: 11500000, guid: ae19b314bbfece546a1a8d74d38387ac, type: 3}
|
||||||
|
m_Name:
|
||||||
|
m_EditorClassIdentifier:
|
||||||
|
noteBase: {fileID: 0}
|
||||||
|
|||||||
14
Assets/Prefabs/Sample Assiant Window/NotefabContoler.cs
Normal file
14
Assets/Prefabs/Sample Assiant Window/NotefabContoler.cs
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
using System.Collections;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using Ichni;
|
||||||
|
using Ichni.RhythmGame;
|
||||||
|
using UnityEngine;
|
||||||
|
|
||||||
|
public class NotefabContoler : MonoBehaviour
|
||||||
|
{
|
||||||
|
public NoteBase noteBase;
|
||||||
|
public void Onclick()
|
||||||
|
{
|
||||||
|
EditorManager.instance.uiManager.hierarchy.FindTab(noteBase);
|
||||||
|
}
|
||||||
|
}
|
||||||
11
Assets/Prefabs/Sample Assiant Window/NotefabContoler.cs.meta
Normal file
11
Assets/Prefabs/Sample Assiant Window/NotefabContoler.cs.meta
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: ae19b314bbfece546a1a8d74d38387ac
|
||||||
|
MonoImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
serializedVersion: 2
|
||||||
|
defaultReferences: []
|
||||||
|
executionOrder: 0
|
||||||
|
icon: {instanceID: 0}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -2,6 +2,7 @@ using System;
|
|||||||
using System.Collections;
|
using System.Collections;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using Dreamteck.Splines;
|
||||||
using Ichni;
|
using Ichni;
|
||||||
using Ichni.Editor;
|
using Ichni.Editor;
|
||||||
using Ichni.RhythmGame;
|
using Ichni.RhythmGame;
|
||||||
@@ -11,7 +12,7 @@ using UnityEngine;
|
|||||||
using UnityEngine.InputSystem;
|
using UnityEngine.InputSystem;
|
||||||
using UnityEngine.UI;
|
using UnityEngine.UI;
|
||||||
|
|
||||||
public class SampleWindow : MovableWindow//该window高度为300,横的要在200和500之间切换
|
public class SampleWindow : MovableWindow//该window高度为300,横的要在100和500之间切换
|
||||||
{
|
{
|
||||||
public static List<SampleWindow> instances = new List<SampleWindow>();
|
public static List<SampleWindow> instances = new List<SampleWindow>();
|
||||||
public TMP_InputField DeviverInputField;
|
public TMP_InputField DeviverInputField;
|
||||||
@@ -35,6 +36,8 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
float beatmapStartTime => -EditorManager.instance.songInformation.delay;
|
float beatmapStartTime => -EditorManager.instance.songInformation.delay;
|
||||||
float timePerBeat => 60f / EditorManager.instance.songInformation.bpm;
|
float timePerBeat => 60f / EditorManager.instance.songInformation.bpm;
|
||||||
public GameElement gameElement;
|
public GameElement gameElement;
|
||||||
|
public SplinePositioner trackPositioner = null;
|
||||||
|
public GameObject trackHead;
|
||||||
public void Initialize(GameElement qgameElement, string title)
|
public void Initialize(GameElement qgameElement, string title)
|
||||||
{
|
{
|
||||||
closeButton.onClick.AddListener(() =>
|
closeButton.onClick.AddListener(() =>
|
||||||
@@ -52,6 +55,13 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
this.gameElement = qgameElement;
|
this.gameElement = qgameElement;
|
||||||
|
if (qgameElement is Track track)
|
||||||
|
{
|
||||||
|
trackPositioner = this.gameObject.AddComponent<SplinePositioner>();
|
||||||
|
trackPositioner.spline = track.trackPathSubmodule.path;
|
||||||
|
trackPositioner.enabled = isFocus;
|
||||||
|
trackPositioner.targetObject = trackHead;
|
||||||
|
}
|
||||||
InitializeWindow(title);
|
InitializeWindow(title);
|
||||||
|
|
||||||
|
|
||||||
@@ -70,6 +80,21 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
for (int i = 0; i < (int)EditorManager.instance.songInformation.song.length / timePerBeat; i++)
|
for (int i = 0; i < (int)EditorManager.instance.songInformation.song.length / timePerBeat; i++)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
for (int j = 1; j < Xdevide; j++)
|
||||||
|
{
|
||||||
|
GameObject v = Instantiate(beatLinePrefabh, LineMovepoint);
|
||||||
|
v.transform.localPosition = new Vector3(0, i * beatDeviver + (beatDeviver / Xdevide * j), 0);
|
||||||
|
RawImage g = v.GetComponent<RawImage>();
|
||||||
|
g.color = new Color(g.color.r, g.color.g, g.color.b, 0.2f);
|
||||||
|
if (v.transform.localPosition.y > 600)
|
||||||
|
{
|
||||||
|
Destroy(v);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
GameObject u = Instantiate(beatLinePrefabh, LineMovepoint);
|
GameObject u = Instantiate(beatLinePrefabh, LineMovepoint);
|
||||||
u.transform.localPosition = new Vector3(0, i * beatDeviver, 0);
|
u.transform.localPosition = new Vector3(0, i * beatDeviver, 0);
|
||||||
if (i == 1)
|
if (i == 1)
|
||||||
@@ -78,7 +103,7 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
realDevider = secBeatLineh.position.y - LineMovepoint.position.y;
|
realDevider = secBeatLineh.position.y - LineMovepoint.position.y;
|
||||||
Debug.Log(realDevider);
|
Debug.Log(realDevider);
|
||||||
}
|
}
|
||||||
if (u.transform.localPosition.y > 300)
|
if (u.transform.localPosition.y > 600)
|
||||||
{
|
{
|
||||||
Destroy(u);
|
Destroy(u);
|
||||||
break;
|
break;
|
||||||
@@ -103,28 +128,29 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
{
|
{
|
||||||
GameObject u = Instantiate(NotePrefab, NoteMovepoint);
|
GameObject u = Instantiate(NotePrefab, NoteMovepoint);
|
||||||
u.transform.localPosition = new Vector3(0, i.exactJudgeTime / timePerBeat * beatDeviver, 0);
|
u.transform.localPosition = new Vector3(0, i.exactJudgeTime / timePerBeat * beatDeviver, 0);
|
||||||
|
Image color = u.GetComponent<Image>();
|
||||||
|
u.GetComponent<NotefabContoler>().noteBase = i;
|
||||||
switch (i)
|
switch (i)
|
||||||
{
|
{
|
||||||
case Hold hold:
|
case Hold hold:
|
||||||
u.GetComponent<Image>().color = new Color(0, 1, 0, 1);
|
color.color = new Color(0, 1, 0, 1);
|
||||||
RawImage a = u.GetComponent<RawImage>();
|
RawImage a = u.GetComponent<RawImage>();
|
||||||
a.transform.localPosition = new Vector3(0, (hold.holdEndTime - hold.exactJudgeTime) / timePerBeat * beatDeviver / 2, 0);
|
a.transform.localPosition = new Vector3(0, (hold.holdEndTime - hold.exactJudgeTime) / timePerBeat * beatDeviver / 2, 0);
|
||||||
a.GetComponent<RectTransform>().sizeDelta = new Vector2(0, (hold.holdEndTime - hold.exactJudgeTime) / timePerBeat * beatDeviver);
|
a.GetComponent<RectTransform>().sizeDelta = new Vector2(0, (hold.holdEndTime - hold.exactJudgeTime) / timePerBeat * beatDeviver);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case Tap:
|
case Tap:
|
||||||
u.GetComponent<Image>().color = new Color(0, 1, 1, 1);
|
color.color = new Color(0, 1, 1, 1);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case Stay:
|
case Stay:
|
||||||
u.GetComponent<Image>().color = new Color(1, 1, 0, 1);
|
color.color = new Color(1, 1, 0, 1);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case Flick:
|
case Flick:
|
||||||
u.GetComponent<Image>().color = new Color(1, 0.2f, 0, 1);
|
color.color = new Color(1, 0.2f, 0, 1);
|
||||||
break;
|
break;
|
||||||
}
|
}//服了,之后整合到controler里头去
|
||||||
}
|
}
|
||||||
void Update()
|
void Update()
|
||||||
|
|
||||||
@@ -134,18 +160,38 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
NoteMovepoint.localPosition = new(0, -beatDeviver * songBeat, 0);
|
NoteMovepoint.localPosition = new(0, -beatDeviver * songBeat, 0);
|
||||||
if (isFocus && gameElement is Track track)
|
if (isFocus && gameElement is Track track)
|
||||||
{
|
{
|
||||||
|
if (track.submoduleList.Where(i => i is TrackTimeSubmoduleMovable).Count() != 0)
|
||||||
|
{
|
||||||
|
trackPositioner.SetPercent(track.trackTimeSubmodule.headPercent);
|
||||||
|
}
|
||||||
|
else if (track.submoduleList.Where(i => i is TrackTimeSubmoduleStatic).Count() != 0)
|
||||||
|
{
|
||||||
|
trackPositioner.SetPercent(0f);
|
||||||
|
}
|
||||||
|
TransformChanged();
|
||||||
|
windowRect.GetComponent<CanvasGroup>().alpha = track.timeDurationSubmodule.CheckTimeInDuration(songTime) ? 1f : 0.2f;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
void TransformChanged()
|
||||||
|
{
|
||||||
|
RectTransform canvasRect = EditorManager.instance.inspectorCanvas.GetComponent<RectTransform>();
|
||||||
|
Vector2 ScreenPosition = EditorManager.instance.cameraManager.currentCamera.WorldToScreenPoint(trackHead.transform.position);
|
||||||
|
|
||||||
|
if (RectTransformUtility.ScreenPointToLocalPointInRectangle(canvasRect, ScreenPosition, null, out Vector2 uiPosition))
|
||||||
|
{
|
||||||
|
windowRect.anchoredPosition = new Vector2(uiPosition.x, uiPosition.y + 150f);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public void ChangeFocus()
|
public void ChangeFocus()
|
||||||
{
|
{
|
||||||
isFocus = !isFocus;
|
isFocus = !isFocus;
|
||||||
|
if (trackPositioner != null) trackPositioner.enabled = isFocus;
|
||||||
}
|
}
|
||||||
public void ChangeXdevide(string devide)
|
public void ChangeXdevide(string devide)
|
||||||
{
|
{
|
||||||
Xdevide = int.Parse(devide);
|
Xdevide = int.Parse(devide);
|
||||||
|
SpawnBeatline();
|
||||||
}
|
}
|
||||||
public void ChangeBeatdevide(string devide)
|
public void ChangeBeatdevide(string devide)
|
||||||
{
|
{
|
||||||
@@ -158,7 +204,7 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
if (isExpand)
|
if (isExpand)
|
||||||
{
|
{
|
||||||
isExpand = false;
|
isExpand = false;
|
||||||
windowRect.sizeDelta = new Vector2(200, windowRect.sizeDelta.y);
|
windowRect.sizeDelta = new Vector2(100, windowRect.sizeDelta.y);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -171,7 +217,8 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
// 获取鼠标在 NoteMovepoint 中的相对位置
|
// 获取鼠标在 NoteMovepoint 中的相对位置
|
||||||
Vector2 localMousePosition = NoteMovepoint.InverseTransformPoint(Mouse.current.position.ReadValue());
|
Vector2 localMousePosition = NoteMovepoint.InverseTransformPoint(Mouse.current.position.ReadValue());
|
||||||
Debug.Log(localMousePosition);
|
Debug.Log(localMousePosition);
|
||||||
// 使用 realDevider 进行整数倍舍入
|
|
||||||
|
|
||||||
float mouseBeat = localMousePosition.y / beatDeviver;
|
float mouseBeat = localMousePosition.y / beatDeviver;
|
||||||
float far = 0f;
|
float far = 0f;
|
||||||
while (far < mouseBeat)
|
while (far < mouseBeat)
|
||||||
@@ -179,15 +226,13 @@ public class SampleWindow : MovableWindow//该window高度为300,横的要在2
|
|||||||
far += 1f / Xdevide;
|
far += 1f / Xdevide;
|
||||||
}
|
}
|
||||||
far -= 1f / Xdevide;
|
far -= 1f / Xdevide;
|
||||||
float time = (far * timePerBeat);//idk
|
float time = far * timePerBeat;
|
||||||
//Debug.Log($"Rounded Position Y: {time}");
|
|
||||||
|
|
||||||
if (!isExpand)
|
if (!isExpand)//movable
|
||||||
{
|
{
|
||||||
Tap a = Tap.GenerateElement("New Tap", Guid.NewGuid(), new List<string>(), true, gameElement, time);
|
Tap a = Tap.GenerateElement("New Tap", Guid.NewGuid(), new List<string>(), true, gameElement, time);
|
||||||
noteBases.Add(a);
|
noteBases.Add(a);
|
||||||
SpawnNote(a);
|
SpawnNote(a);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -191,8 +191,8 @@ RectTransform:
|
|||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 0}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 1, y: 1}
|
m_AnchorMax: {x: 1, y: 1}
|
||||||
m_AnchoredPosition: {x: 0, y: -30}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 0, y: -60}
|
m_SizeDelta: {x: 0, y: 0}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &3826833769229920620
|
--- !u!114 &3826833769229920620
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
@@ -969,7 +969,7 @@ GameObject:
|
|||||||
m_Icon: {fileID: 0}
|
m_Icon: {fileID: 0}
|
||||||
m_NavMeshLayer: 0
|
m_NavMeshLayer: 0
|
||||||
m_StaticEditorFlags: 0
|
m_StaticEditorFlags: 0
|
||||||
m_IsActive: 1
|
m_IsActive: 0
|
||||||
--- !u!224 &1863687384833674762
|
--- !u!224 &1863687384833674762
|
||||||
RectTransform:
|
RectTransform:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -1408,7 +1408,7 @@ RectTransform:
|
|||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: 49.3, y: -1.300003}
|
m_AnchoredPosition: {x: 29.3, y: -1.300003}
|
||||||
m_SizeDelta: {x: 35, y: 35}
|
m_SizeDelta: {x: 35, y: 35}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &7786120526457458120
|
--- !u!222 &7786120526457458120
|
||||||
@@ -1535,6 +1535,8 @@ RectTransform:
|
|||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children:
|
||||||
- {fileID: 5350326440702738651}
|
- {fileID: 5350326440702738651}
|
||||||
|
- {fileID: 5519728737445797230}
|
||||||
|
- {fileID: 7551014579700651781}
|
||||||
m_Father: {fileID: 70126183804589383}
|
m_Father: {fileID: 70126183804589383}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 1}
|
m_AnchorMin: {x: 0, y: 1}
|
||||||
@@ -1733,11 +1735,11 @@ RectTransform:
|
|||||||
m_LocalScale: {x: 0.66, y: 0.66, z: 0.66}
|
m_LocalScale: {x: 0.66, y: 0.66, z: 0.66}
|
||||||
m_ConstrainProportionsScale: 1
|
m_ConstrainProportionsScale: 1
|
||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 5350326440702738651}
|
m_Father: {fileID: 4803002250074383695}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: 81.4, y: -1.3000002}
|
m_AnchoredPosition: {x: 64, y: 14.22771}
|
||||||
m_SizeDelta: {x: 45, y: 45}
|
m_SizeDelta: {x: 45, y: 45}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &6548761174430130557
|
--- !u!222 &6548761174430130557
|
||||||
@@ -1855,11 +1857,11 @@ RectTransform:
|
|||||||
m_ConstrainProportionsScale: 1
|
m_ConstrainProportionsScale: 1
|
||||||
m_Children:
|
m_Children:
|
||||||
- {fileID: 4584982385393968897}
|
- {fileID: 4584982385393968897}
|
||||||
m_Father: {fileID: 5350326440702738651}
|
m_Father: {fileID: 4803002250074383695}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: -86.9, y: -1.8000002}
|
m_AnchoredPosition: {x: -64.9, y: 13.72771}
|
||||||
m_SizeDelta: {x: 40, y: 40}
|
m_SizeDelta: {x: 40, y: 40}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &7732886657751279044
|
--- !u!222 &7732886657751279044
|
||||||
@@ -2211,6 +2213,41 @@ RectTransform:
|
|||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
|
m_AnchoredPosition: {x: 0, y: 11.386902}
|
||||||
|
m_SizeDelta: {x: 100, y: 122.7738}
|
||||||
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
|
--- !u!1 &8089137743710118797
|
||||||
|
GameObject:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
serializedVersion: 6
|
||||||
|
m_Component:
|
||||||
|
- component: {fileID: 7104365328599230347}
|
||||||
|
m_Layer: 5
|
||||||
|
m_Name: Track hader
|
||||||
|
m_TagString: Untagged
|
||||||
|
m_Icon: {fileID: 0}
|
||||||
|
m_NavMeshLayer: 0
|
||||||
|
m_StaticEditorFlags: 0
|
||||||
|
m_IsActive: 1
|
||||||
|
--- !u!224 &7104365328599230347
|
||||||
|
RectTransform:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8089137743710118797}
|
||||||
|
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||||
|
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||||
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
|
m_ConstrainProportionsScale: 0
|
||||||
|
m_Children: []
|
||||||
|
m_Father: {fileID: 70126183804589383}
|
||||||
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: 0, y: 0}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 100, y: 100}
|
m_SizeDelta: {x: 100, y: 100}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
@@ -2246,11 +2283,9 @@ RectTransform:
|
|||||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||||
m_ConstrainProportionsScale: 0
|
m_ConstrainProportionsScale: 0
|
||||||
m_Children:
|
m_Children:
|
||||||
- {fileID: 5519728737445797230}
|
|
||||||
- {fileID: 5888054024393656283}
|
- {fileID: 5888054024393656283}
|
||||||
- {fileID: 4051171814187022942}
|
- {fileID: 4051171814187022942}
|
||||||
- {fileID: 1680283986877063858}
|
- {fileID: 1680283986877063858}
|
||||||
- {fileID: 7551014579700651781}
|
|
||||||
- {fileID: 258411808367658307}
|
- {fileID: 258411808367658307}
|
||||||
m_Father: {fileID: 4803002250074383695}
|
m_Father: {fileID: 4803002250074383695}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
@@ -2527,6 +2562,7 @@ GameObject:
|
|||||||
- component: {fileID: 70126183804589383}
|
- component: {fileID: 70126183804589383}
|
||||||
- component: {fileID: 7396740820777350136}
|
- component: {fileID: 7396740820777350136}
|
||||||
- component: {fileID: 7258356208599686677}
|
- component: {fileID: 7258356208599686677}
|
||||||
|
- component: {fileID: 777883499698626610}
|
||||||
m_Layer: 5
|
m_Layer: 5
|
||||||
m_Name: SampleWindow
|
m_Name: SampleWindow
|
||||||
m_TagString: Untagged
|
m_TagString: Untagged
|
||||||
@@ -2551,12 +2587,13 @@ RectTransform:
|
|||||||
- {fileID: 1863687384833674762}
|
- {fileID: 1863687384833674762}
|
||||||
- {fileID: 6090386518530065525}
|
- {fileID: 6090386518530065525}
|
||||||
- {fileID: 4803002250074383695}
|
- {fileID: 4803002250074383695}
|
||||||
|
- {fileID: 7104365328599230347}
|
||||||
m_Father: {fileID: 0}
|
m_Father: {fileID: 0}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: 0, y: 547}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 200, y: 300}
|
m_SizeDelta: {x: 100, y: 300}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &7396740820777350136
|
--- !u!114 &7396740820777350136
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
@@ -2607,6 +2644,20 @@ MonoBehaviour:
|
|||||||
type: 3}
|
type: 3}
|
||||||
secBeatLineh: {fileID: 0}
|
secBeatLineh: {fileID: 0}
|
||||||
gameElement: {fileID: 0}
|
gameElement: {fileID: 0}
|
||||||
|
trackPositioner: {fileID: 0}
|
||||||
|
trackHead: {fileID: 8089137743710118797}
|
||||||
|
--- !u!225 &777883499698626610
|
||||||
|
CanvasGroup:
|
||||||
|
m_ObjectHideFlags: 0
|
||||||
|
m_CorrespondingSourceObject: {fileID: 0}
|
||||||
|
m_PrefabInstance: {fileID: 0}
|
||||||
|
m_PrefabAsset: {fileID: 0}
|
||||||
|
m_GameObject: {fileID: 8976586735561836907}
|
||||||
|
m_Enabled: 1
|
||||||
|
m_Alpha: 1
|
||||||
|
m_Interactable: 1
|
||||||
|
m_BlocksRaycasts: 1
|
||||||
|
m_IgnoreParentGroups: 0
|
||||||
--- !u!1 &9031008402990669482
|
--- !u!1 &9031008402990669482
|
||||||
GameObject:
|
GameObject:
|
||||||
m_ObjectHideFlags: 0
|
m_ObjectHideFlags: 0
|
||||||
@@ -2817,7 +2868,7 @@ RectTransform:
|
|||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: -52.6, y: -1.300003}
|
m_AnchoredPosition: {x: -28.9, y: -1.300003}
|
||||||
m_SizeDelta: {x: 45, y: 45}
|
m_SizeDelta: {x: 45, y: 45}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &2627130424975939783
|
--- !u!222 &2627130424975939783
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ RectTransform:
|
|||||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||||
m_AnchoredPosition: {x: 0, y: 82}
|
m_AnchoredPosition: {x: 0, y: 82}
|
||||||
m_SizeDelta: {x: 500, y: 2}
|
m_SizeDelta: {x: 500, y: 4}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!222 &4593078808003308247
|
--- !u!222 &4593078808003308247
|
||||||
CanvasRenderer:
|
CanvasRenderer:
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -186,8 +186,9 @@ namespace Ichni.RhythmGame
|
|||||||
if (EditorManager.instance.uiManager.inspector.connectedGameElement == parentElement)
|
if (EditorManager.instance.uiManager.inspector.connectedGameElement == parentElement)
|
||||||
{
|
{
|
||||||
EditorManager.instance.uiManager.timeline.SetTimeLine(parentElement);
|
EditorManager.instance.uiManager.timeline.SetTimeLine(parentElement);
|
||||||
foreach (SampleWindow i in SampleWindow.instances.Where(i => i.gameElement)) i.OnceSpawnNote();
|
|
||||||
}
|
}
|
||||||
|
foreach (SampleWindow i in SampleWindow.instances.Where(i => i.gameElement)) i.OnceSpawnNote();
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ namespace Ichni
|
|||||||
public CameraManager cameraManager;
|
public CameraManager cameraManager;
|
||||||
public PostProcessingManager postProcessingManager;
|
public PostProcessingManager postProcessingManager;
|
||||||
public Canvas judgeHintCanvas;
|
public Canvas judgeHintCanvas;
|
||||||
|
public Canvas inspectorCanvas;
|
||||||
public Timeline timeline;
|
public Timeline timeline;
|
||||||
|
|
||||||
public ProjectInformation projectInformation;
|
public ProjectInformation projectInformation;
|
||||||
@@ -38,7 +38,7 @@ namespace Ichni
|
|||||||
public NoteBase.NoteJudgeType currentJudgeType;
|
public NoteBase.NoteJudgeType currentJudgeType;
|
||||||
public bool useNotePrefab;
|
public bool useNotePrefab;
|
||||||
public BasePrefabsCollection basePrefabs;
|
public BasePrefabsCollection basePrefabs;
|
||||||
|
|
||||||
[Title("Runtime Global Elements")]
|
[Title("Runtime Global Elements")]
|
||||||
public VariablesContainer variablesContainer;
|
public VariablesContainer variablesContainer;
|
||||||
public BackgroundSetter backgroundSetter;
|
public BackgroundSetter backgroundSetter;
|
||||||
@@ -66,7 +66,7 @@ namespace Ichni
|
|||||||
this.elementName = "EditorManager";
|
this.elementName = "EditorManager";
|
||||||
this.elementGuid = Guid.Empty;
|
this.elementGuid = Guid.Empty;
|
||||||
uiManager.hierarchy.GenerateTab(this, null);
|
uiManager.hierarchy.GenerateTab(this, null);
|
||||||
|
|
||||||
if (InformationTransistor.instance.isLoadedProject)
|
if (InformationTransistor.instance.isLoadedProject)
|
||||||
{
|
{
|
||||||
LoadProject(InformationTransistor.instance.loadedProjectName);
|
LoadProject(InformationTransistor.instance.loadedProjectName);
|
||||||
@@ -76,13 +76,13 @@ namespace Ichni
|
|||||||
projectManager.GenerateEmptyProject(InformationTransistor.instance.projectInfo_BM, InformationTransistor.instance.songInfo_BM);
|
projectManager.GenerateEmptyProject(InformationTransistor.instance.projectInfo_BM, InformationTransistor.instance.songInfo_BM);
|
||||||
projectManager.saveManager.Save();
|
projectManager.saveManager.Save();
|
||||||
}
|
}
|
||||||
|
|
||||||
isLoaded = true;
|
isLoaded = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Update()
|
private void Update()
|
||||||
{
|
{
|
||||||
if(isLoaded) projectManager.autoSaveManager.UpdateAutoSave();
|
if (isLoaded) projectManager.autoSaveManager.UpdateAutoSave();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void LoadProject(string projectName)
|
public void LoadProject(string projectName)
|
||||||
@@ -92,7 +92,7 @@ namespace Ichni
|
|||||||
beatmapContainer.gameElementList.ForEach(gameElement =>
|
beatmapContainer.gameElementList.ForEach(gameElement =>
|
||||||
{
|
{
|
||||||
gameElement.AfterInitialize();
|
gameElement.AfterInitialize();
|
||||||
|
|
||||||
gameElement.Refresh();
|
gameElement.Refresh();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -102,7 +102,7 @@ namespace Ichni
|
|||||||
IHaveInspection inspector = uiManager.inspector;
|
IHaveInspection inspector = uiManager.inspector;
|
||||||
|
|
||||||
var container = inspector.GenerateContainer("Editor Manager");
|
var container = inspector.GenerateContainer("Editor Manager");
|
||||||
|
|
||||||
var inGameSettings = container.GenerateSubcontainer(3);
|
var inGameSettings = container.GenerateSubcontainer(3);
|
||||||
var judgeTypeDropdown = inspector.GenerateDropdown(this, inGameSettings, "Judge Type",
|
var judgeTypeDropdown = inspector.GenerateDropdown(this, inGameSettings, "Judge Type",
|
||||||
typeof(NoteBase.NoteJudgeType), nameof(currentJudgeType)).AddListenerFunction(() =>
|
typeof(NoteBase.NoteJudgeType), nameof(currentJudgeType)).AddListenerFunction(() =>
|
||||||
@@ -115,7 +115,7 @@ namespace Ichni
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
var useNotePrefabToggle =
|
var useNotePrefabToggle =
|
||||||
inspector.GenerateToggle(this, inGameSettings, "Use Note Prefab", nameof(useNotePrefab));
|
inspector.GenerateToggle(this, inGameSettings, "Use Note Prefab", nameof(useNotePrefab));
|
||||||
|
|
||||||
var generation = container.GenerateSubcontainer(3);
|
var generation = container.GenerateSubcontainer(3);
|
||||||
@@ -132,7 +132,7 @@ namespace Ichni
|
|||||||
inspector.GenerateButton(this, generation, "Generate Variables Container",
|
inspector.GenerateButton(this, generation, "Generate Variables Container",
|
||||||
() => VariablesContainer.GenerateElement("Variables Container", Guid.NewGuid(),
|
() => VariablesContainer.GenerateElement("Variables Container", Guid.NewGuid(),
|
||||||
new List<string>(), true, null, new Dictionary<string, int>()));
|
new List<string>(), true, null, new Dictionary<string, int>()));
|
||||||
|
|
||||||
projectInformation.SetUpInspector();
|
projectInformation.SetUpInspector();
|
||||||
songInformation.SetUpInspector();
|
songInformation.SetUpInspector();
|
||||||
cameraManager.SetUpInspector();
|
cameraManager.SetUpInspector();
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user