mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-10-15 20:08:14 +00:00
fix: prevent negative imagination
And fail switch if we don't have enough imagination
This commit is contained in:
@@ -203,7 +203,7 @@ void RebuildComponent::Update(float deltaTime) {
|
||||
|
||||
++m_DrainedImagination;
|
||||
|
||||
if (newImagination == 0 && m_DrainedImagination < m_TakeImagination) {
|
||||
if (newImagination <= 0 && m_DrainedImagination < m_TakeImagination) {
|
||||
CancelRebuild(builder, eQuickBuildFailReason::OUT_OF_IMAGINATION, true);
|
||||
|
||||
break;
|
||||
|
Reference in New Issue
Block a user