Reverted change and simply lowered the spawn height to 8

This commit is contained in:
EmosewaMC 2022-01-15 19:12:07 -08:00
parent fa714aa843
commit d883536ebd

View File

@ -65,12 +65,7 @@ void GfBanana::OnHit(Entity* self, Entity* attacker)
return; return;
} }
// Get the banana cluster position bananaEntity->SetPosition(bananaEntity->GetPosition() - NiPoint3::UNIT_Y * 8);
auto entityPosition = bananaEntity->GetPosition();
// Lower by 10 units to prevent bananas from spawning on top of the tree
entityPosition.SetY(entityPosition.GetY() - 10);
// Set the position to the new position.
bananaEntity->SetPosition(entityPosition);
auto* bananaDestroyable = bananaEntity->GetComponent<DestroyableComponent>(); auto* bananaDestroyable = bananaEntity->GetComponent<DestroyableComponent>();