Small Bugfixes (#95)

* Fix Sheets issue 11

* Textboxes: Fix unicode glyphs sometimes not displaying

* Fan Club: fix order of operation bug

* Conductor: refactor ReportBeat

this fixes issues with using crop stomp alongside tempo changes

* Built to Scale (Gold): temporarily disable post-processing

game renders very incorrectly due to the post processing effects
will need someone who knows what they're doing in that field to fix it proper

* marked some assets for deletion

* I'm dumb and left in debug prints
This commit is contained in:
minenice55 2022-06-08 23:35:15 -04:00 committed by GitHub
parent bd6f3ee23d
commit b039ff219a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
21 changed files with 2418 additions and 1425 deletions

View file

@ -12,7 +12,7 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: 957177531333f744abeb6082b4c44bc0, type: 3} m_Script: {fileID: 11500000, guid: 957177531333f744abeb6082b4c44bc0, type: 3}
m_Name: PostProcessOutline m_Name: PostProcessOutline
m_EditorClassIdentifier: m_EditorClassIdentifier:
active: 1 active: 0
enabled: enabled:
overrideState: 1 overrideState: 1
value: 1 value: 1

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -768,7 +768,7 @@ MonoBehaviour:
m_PrefabInstance: {fileID: 0} m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4052947733920485538} m_GameObject: {fileID: 4052947733920485538}
m_Enabled: 1 m_Enabled: 0
m_EditorHideFlags: 0 m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 948f4100a11a5c24981795d21301da5c, type: 3} m_Script: {fileID: 11500000, guid: 948f4100a11a5c24981795d21301da5c, type: 3}
m_Name: m_Name:
@ -847,7 +847,7 @@ MonoBehaviour:
m_PrefabInstance: {fileID: 0} m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0} m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4052947733920485538} m_GameObject: {fileID: 4052947733920485538}
m_Enabled: 1 m_Enabled: 0
m_EditorHideFlags: 0 m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 2a7b4608cc97a8940ad8a9229d742532, type: 3} m_Script: {fileID: 11500000, guid: 2a7b4608cc97a8940ad8a9229d742532, type: 3}
m_Name: m_Name:
@ -1799,6 +1799,7 @@ MonoBehaviour:
m_Name: m_Name:
m_EditorClassIdentifier: m_EditorClassIdentifier:
EligibleHits: [] EligibleHits: []
scheduledInputs: []
firstEnable: 0 firstEnable: 0
renderQuadTrans: {fileID: 743597382397742394} renderQuadTrans: {fileID: 743597382397742394}
camPivot: {fileID: 7562518461416892310} camPivot: {fileID: 7562518461416892310}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 66 KiB

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 54 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 34 KiB

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

After

Width:  |  Height:  |  Size: 24 KiB

View file

@ -189,23 +189,20 @@ namespace HeavenStudio
{ {
Util.Jukebox.PlayOneShot("metronome"); Util.Jukebox.PlayOneShot("metronome");
} }
else if (songPosition <= lastReportedBeat) else if (songPositionInBeats < lastReportedBeat)
{ {
lastReportedBeat = (songPosition - (songPosition % secPerBeat)); lastReportedBeat = Mathf.Round(songPositionInBeats);
} }
} }
} }
} }
public bool ReportBeat(ref float lastReportedBeat, float offset = 0, bool shiftBeatToOffset = false) public bool ReportBeat(ref float lastReportedBeat, float offset = 0, bool shiftBeatToOffset = true)
{ {
bool result = songPosition > (lastReportedBeat + offset) + secPerBeat; bool result = songPositionInBeats + (shiftBeatToOffset ? offset : 0f) >= (lastReportedBeat) + 1f;
if (result == true) if (result)
{ {
lastReportedBeat = (songPosition - (songPosition % secPerBeat)); lastReportedBeat += 1f;
if (!shiftBeatToOffset)
lastReportedBeat += offset;
} }
return result; return result;
} }

View file

@ -159,6 +159,18 @@ namespace HeavenStudio
List<float> entities = Beatmap.entities.Select(c => c.beat).ToList(); List<float> entities = Beatmap.entities.Select(c => c.beat).ToList();
List<float> tempoChanges = Beatmap.tempoChanges.Select(c => c.beat).ToList(); List<float> tempoChanges = Beatmap.tempoChanges.Select(c => c.beat).ToList();
if (currentTempoEvent < Beatmap.tempoChanges.Count && currentTempoEvent >= 0)
{
// Debug.Log("Checking Tempo Change at " + tempoChanges[currentTempoEvent] + ", current beat " + Conductor.instance.songPositionInBeats);
if (Conductor.instance.songPositionInBeats >= tempoChanges[currentTempoEvent])
{
// Debug.Log("Tempo Change at " + Conductor.instance.songPositionInBeats + " of bpm " + Beatmap.tempoChanges[currentTempoEvent].tempo);
Conductor.instance.SetBpm(Beatmap.tempoChanges[currentTempoEvent].tempo);
Conductor.instance.timeSinceLastTempoChange = Time.time;
currentTempoEvent++;
}
}
if (currentEvent < Beatmap.entities.Count && currentEvent >= 0) if (currentEvent < Beatmap.entities.Count && currentEvent >= 0)
{ {
if (Conductor.instance.songPositionInBeats >= entities[currentEvent] /*&& SongPosLessThanClipLength(Conductor.instance.songPositionInBeats)*/) if (Conductor.instance.songPositionInBeats >= entities[currentEvent] /*&& SongPosLessThanClipLength(Conductor.instance.songPositionInBeats)*/)
@ -194,18 +206,6 @@ namespace HeavenStudio
// currentEvent += gameManagerEntities.Count; // currentEvent += gameManagerEntities.Count;
} }
} }
if (currentTempoEvent < Beatmap.tempoChanges.Count && currentTempoEvent >= 0)
{
// Debug.Log("Checking Tempo Change at " + tempoChanges[currentTempoEvent] + ", current beat " + Conductor.instance.songPositionInBeats);
if (Conductor.instance.songPositionInBeats >= tempoChanges[currentTempoEvent])
{
// Debug.Log("Tempo Change at " + Conductor.instance.songPositionInBeats + " of bpm " + Beatmap.tempoChanges[currentTempoEvent].tempo);
Conductor.instance.SetBpm(Beatmap.tempoChanges[currentTempoEvent].tempo);
Conductor.instance.timeSinceLastTempoChange = Time.time;
currentTempoEvent++;
}
}
} }
public void ToggleInputs(bool inputs) public void ToggleInputs(bool inputs)

View file

@ -270,7 +270,7 @@ namespace HeavenStudio.Games
public void StartMarching(float beat) public void StartMarching(float beat)
{ {
marchStartBeat = beat; marchStartBeat = beat;
marchOffset = (marchStartBeat % 1) * Conductor.instance.secPerBeat / Conductor.instance.musicSource.pitch; marchOffset = marchStartBeat % 1;
currentMarchBeat = 0; currentMarchBeat = 0;
stepCount = 0; stepCount = 0;

View file

@ -28,18 +28,25 @@ namespace HeavenStudio.Games.Scripts_FanClub
float clappingStartTime = Single.MinValue; float clappingStartTime = Single.MinValue;
public void AddHit(float beat, int type) public void AddHit(float beat, int type = 0)
{ {
if (player) if (player)
{ {
if (type == 0) // normal clap switch (type)
FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_DOWN, ClapJust, ClapThrough, Out); {
else if (type == 1) // jump case 0:
FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_UP, JumpJust, JumpThrough, JumpOut); FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_DOWN, ClapJust, ClapThrough, Out);
else if (type == 2) //"kamone" charge break;
FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_DOWN, ChargeClapJust, ClapThrough, Out); case 1:
else //"kamone" long clap (first) FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_UP, JumpJust, JumpThrough, JumpOut);
FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_DOWN, LongClapJust, ClapThrough, Out); break;
case 2:
FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_DOWN, ChargeClapJust, ClapThrough, Out);
break;
default:
FanClub.instance.ScheduleInput(beat, 1f, InputType.STANDARD_DOWN, LongClapJust, ClapThrough, Out);
break;
}
} }
} }
@ -107,12 +114,9 @@ namespace HeavenStudio.Games.Scripts_FanClub
} }
if (PlayerInput.PressedUp()) if (PlayerInput.PressedUp())
{ {
if (stopCharge) if (clappingStartTime != Single.MinValue && cond.songPositionInBeats > clappingStartTime + 2f && stopCharge && !FanClub.instance.IsExpectingInputNow())
{ {
if (!FanClub.instance.IsExpectingInputNow()) JumpStart(false);
{
JumpStart(false);
}
} }
else else
{ {

View file

@ -240,9 +240,18 @@ namespace HeavenStudio.Games.Global
} }
else if (idolShown) else if (idolShown)
{ {
IdolAnimator.Play("IdolHide", -1, 0); if (prog < 1f)
IdolAnimator.speed = (1f / cond.pitchedSecPerBeat) * 0.5f; {
idolShown = false; IdolAnimator.Play("NoPose", -1, 0);
IdolAnimator.speed = 1;
idolShown = false;
}
else
{
IdolAnimator.Play("IdolHide", -1, 0);
IdolAnimator.speed = (1f / cond.pitchedSecPerBeat) * 0.5f;
idolShown = false;
}
} }
} }
} }

View file

@ -116,7 +116,7 @@ namespace HeavenStudio.Games
float t1 = closest.startBeat + closest.timer; float t1 = closest.startBeat + closest.timer;
float t2 = toCompare.startBeat + toCompare.timer; float t2 = toCompare.startBeat + toCompare.timer;
Debug.Log("t1=" + t1 + " -- t2=" + t2); // Debug.Log("t1=" + t1 + " -- t2=" + t2);
if (t2 < t1) closest = toCompare; if (t2 < t1) closest = toCompare;
} }