Skip to content
This repository has been archived by the owner on Aug 27, 2024. It is now read-only.

Commit

Permalink
fix old progress bug
Browse files Browse the repository at this point in the history
  • Loading branch information
dankmeme01 committed Oct 15, 2023
1 parent a9d00bd commit d2dde0a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/hooked/play_layer.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -258,11 +258,6 @@ class $modify(ModifiedPlayLayer, PlayLayer) {
}

self->updateSelfProgress();

if (g_debug) {
// self->m_player1->setOpacity(64);
// self->m_player2->setOpacity(64);
}
}

// updateStuff is update() but less time-sensitive, runs every second rather than every frame.
Expand Down Expand Up @@ -345,6 +340,11 @@ class $modify(ModifiedPlayLayer, PlayLayer) {

updateNewProgress(progressVal, static_cast<PlayerProgressNew*>(progress));
} else { // old progress
if (g_spectatedPlayer == playerId) {
progress->setVisible(false);
return;
}

if (!isPlayerVisible(players.first->getPosition()) || g_debug) {
bool onRightSide = playerPos.x > m_player1->getPositionX();
progress->updateValues(progressVal * 100, onRightSide);
Expand Down

0 comments on commit d2dde0a

Please sign in to comment.