From 2aa3fbf381df35874cca3c87b915d66a4e25b7d3 Mon Sep 17 00:00:00 2001 From: Relintai Date: Fri, 13 Oct 2023 20:27:08 +0200 Subject: [PATCH] Codestyle. --- modules/terraman/world/terrain_chunk.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modules/terraman/world/terrain_chunk.cpp b/modules/terraman/world/terrain_chunk.cpp index d7ac0b38d..6d131bd0c 100644 --- a/modules/terraman/world/terrain_chunk.cpp +++ b/modules/terraman/world/terrain_chunk.cpp @@ -804,18 +804,20 @@ int TerrainChunk::mesh_data_resource_add(const Transform &local_transform, const e.is_inside = aabb.encloses(mesh_aabb); #ifdef MODULE_PROPS_ENABLED - if (get_library().is_valid() && texture.is_valid()) + if (get_library().is_valid() && texture.is_valid()) { e.uv_rect = get_library()->get_prop_uv_rect(texture); - else + } else { e.uv_rect = Rect2(0, 0, 1, 1); + } #else e.uv_rect = Rect2(0, 0, 1, 1); #endif _mesh_data_resources.push_back(e); - if (has_method("_mesh_data_resource_added")) + if (has_method("_mesh_data_resource_added")) { call("_mesh_data_resource_added", index); + } return index; }