chore(console): prefer auto

This commit is contained in:
fallenoak 2023-04-17 22:36:52 -05:00
parent a397de8619
commit d6ee59ff7c
No known key found for this signature in database
GPG Key ID: 7628F8E61AEA070D

View File

@ -95,10 +95,10 @@ void ConsoleScreenAnimate(float elapsedSec) {
return;
}
float currentPos = finalPos;
auto currentPos = finalPos;
if (ConsoleGetResizeState() == CS_NONE) {
float direction = s_rect.bottom <= finalPos ? 1.0f : -1.0f;
auto direction = s_rect.bottom <= finalPos ? 1.0f : -1.0f;
currentPos = s_rect.bottom + direction * elapsedSec * 5.0f;
currentPos = ConsoleGetActive() ? std::max(currentPos, finalPos) : std::min(currentPos, finalPos);