Minor fixes

This commit is contained in:
SirLynix
2023-06-16 13:06:11 +02:00
parent 6bf91e10e5
commit 2a9ec4f3bb
5 changed files with 7 additions and 8 deletions

View File

@@ -247,7 +247,7 @@ namespace Nz
}
JPH::BodyInterface& bodyInterface = m_world->GetPhysicsSystem()->GetBodyInterface();
bodyInterface.SetShape(m_body->GetID(), m_geom->GetShapeSettings()->Create().Get(), false, (ShouldActivate()) ? JPH::EActivation::Activate : JPH::EActivation::DontActivate);
bodyInterface.SetShape(m_body->GetID(), shape, false, (ShouldActivate()) ? JPH::EActivation::Activate : JPH::EActivation::DontActivate);
if (recomputeInertia)
{
JPH::MassProperties massProperties = m_body->GetShape()->GetMassProperties();
@@ -361,7 +361,6 @@ namespace Nz
{
if (m_body)
{
JPH::BodyInterface& bodyInterface = m_world->GetPhysicsSystem()->GetBodyInterface();
m_world->UnregisterBody(m_body->GetID(), true, !worldDestruction);
m_body = nullptr;
}

View File

@@ -705,7 +705,7 @@ nzsl::Ast::ExpressionType ShaderGraph::ToShaderExpressionType(TextureType type)
{
switch (type)
{
case TextureType::Sampler2D: return nzsl::Ast::SamplerType{ nzsl::ImageType::E2D, nzsl::Ast::PrimitiveType::Float32 };
case TextureType::Sampler2D: return nzsl::Ast::SamplerType{ nzsl::ImageType::E2D, nzsl::Ast::PrimitiveType::Float32, false };
}
assert(false);