Also scale bounds origin
This commit is contained in:
@@ -32,7 +32,7 @@ void Systems::RenderSystem::UpdateEntity( double dt, EntityID entity, EntityID p
|
||||
#ifdef DEBUG
|
||||
auto bounds = m_World->GetComponent<Components::Bounds>(entity, "Bounds");
|
||||
if (bounds != nullptr) {
|
||||
glm::vec3 origin = transformComponent->Position + bounds->Origin;
|
||||
glm::vec3 origin = transformComponent->Scale * (transformComponent->Position + bounds->Origin);
|
||||
glm::vec3 volumeVector = transformComponent->Scale * bounds->VolumeVector;
|
||||
m_Renderer->AddAABBToDraw(origin, volumeVector);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user