changed maps but lighting fked

This commit is contained in:
ntr committed 2023-09-11 13:12:08 +10:00
1 parent 6e9d834cfd
commit 7e0703975d
54 files changed
+75740 -8208

No files matched your search

+1 -1
View File
@@ -6,7 +6,7 @@
<ui:VisualElement name="Bottom" class="bottom">
<ui:VisualElement name="notice" style="flex-grow: 1; background-color: rgba(0, 0, 0, 0);">
<ui:VisualElement name="timerDesc" style="flex-grow: 1; background-color: rgba(0, 0, 0, 0); flex-direction: row; justify-content: space-between; align-items: auto; width: auto; align-self: stretch; flex-shrink: 0; font-size: 14px; color: rgb(245, 245, 245);">
<ui:Label tabindex="-1" display-tooltip-when-elided="true" name="msg" style="align-self: flex-end; align-items: auto;" />
<ui:Label tabindex="-1" display-tooltip-when-elided="true" name="noticeMsg" style="align-self: flex-end; align-items: auto;" />
<ui:Label tabindex="-1" display-tooltip-when-elided="true" name="noticePosition" text="5 / 128" />
</ui:VisualElement>
<ui:VisualElement name="noticeLap" style="flex-grow: 1; background-color: rgba(0, 0, 0, 0); flex-direction: row; justify-content: space-between; align-items: auto; width: auto; align-self: stretch; flex-shrink: 0;">
+21 -1
View File
@@ -21,9 +21,18 @@ public class TimingUI : MonoBehaviour {
VisualElement notice;
VisualElement noticeSectors;
VisualElement noticeDiff;
Label noticeMsg;
Label noticeTime;
Label noticePosition;
static string[] completionMsgs = {
"smooth",
"very fast",
"well done",
"ナイス",
"(⌐▨_▨)",
};
void OnEnable() {
Init();
}
@@ -38,6 +47,7 @@ public class TimingUI : MonoBehaviour {
timer = uiDocument.rootVisualElement.Q<VisualElement>("timer");
timerSectors = uiDocument.rootVisualElement.Q<VisualElement>("timerSectors");
noticeMsg = uiDocument.rootVisualElement.Q<Label>("noticeMsg");
noticeTime = uiDocument.rootVisualElement.Q<Label>("noticeTime");
noticeDiff = uiDocument.rootVisualElement.Q<VisualElement>("noticeDiff");
@@ -68,8 +78,15 @@ public class TimingUI : MonoBehaviour {
}
public void UpdateUI() {
if (timerSectors == null)
if (timerSectors == null) {
Debug.LogWarning("null timerSectors");
return;
}
if (timing == null) {
Debug.LogWarning("null timing");
return;
}
Lap timerPbLap = timing.Pb;
if (timerPbLap != null)
@@ -100,6 +117,9 @@ public class TimingUI : MonoBehaviour {
noticeDiff.Clear();
noticeDiff.Add(timing.CompareLap(lap).ToLabel());
int msgIndex = UnityEngine.Random.Range(0, completionMsgs.Length);
noticeMsg.text = completionMsgs[msgIndex];
noticeSectors.Clear();
foreach (SectorTime sector in lap.Sectors) {
Label l = timing.CompareSector(sector).ToLabel();