fixed order of operation issue
This commit is contained in:
parent
fa6efff84f
commit
9de59c357f
|
|
@ -56,7 +56,7 @@ namespace HeavenStudio.Games.Scripts_TotemClimb
|
|||
for (int i = 0; i < _totems.Count; i++)
|
||||
{
|
||||
_totems[i].beat = startBeat + i;
|
||||
if (_totems[i].beat - 1 >= _game.EndBeat || _game.IsTripleBeat(_totems[i].beat)) _totems[i].transform.gameObject.SetActive(false);
|
||||
_totems[i].transform.gameObject.SetActive(_totems[i].beat - 1 < _game.EndBeat && !_game.IsTripleBeat(_totems[i].beat));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -79,7 +79,7 @@ namespace HeavenStudio.Games.Scripts_TotemClimb
|
|||
|
||||
t.transform.localPosition = new Vector3(t.transform.localPosition.x + (_xDistance * _totemAmount), t.transform.localPosition.y + (_yDistance * _totemAmount));
|
||||
t.beat += _totemAmount;
|
||||
t.transform.gameObject.SetActive(!(t.beat - 1 >= _game.EndBeat || _game.IsTripleBeat(t.beat)));
|
||||
t.transform.gameObject.SetActive(t.beat - 1 < _game.EndBeat && !_game.IsTripleBeat(t.beat));
|
||||
_totemIndex++;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -98,8 +98,6 @@ namespace HeavenStudio.Games
|
|||
if (allStarts.Count == 0) return;
|
||||
|
||||
_startBeat = allStarts[0].beat;
|
||||
_totemManager.InitBeats(_startBeat);
|
||||
|
||||
BeatAction.New(this, new()
|
||||
{
|
||||
new(_startBeat - 1, delegate { _jumper.StartJumping(_startBeat - 1); })
|
||||
|
|
@ -109,7 +107,6 @@ namespace HeavenStudio.Games
|
|||
if (allStops.Count == 0) return;
|
||||
|
||||
_endBeat = allStops[0].beat;
|
||||
_totemManager.InitBeats(_startBeat);
|
||||
}
|
||||
|
||||
private void HandleBopsOnStart(double beat)
|
||||
|
|
@ -141,6 +138,7 @@ namespace HeavenStudio.Games
|
|||
}
|
||||
|
||||
_tripleEvents = tempTriples;
|
||||
_totemManager.InitBeats(_startBeat);
|
||||
}
|
||||
|
||||
private void Update()
|
||||
|
|
|
|||
Loading…
Reference in a new issue