diff --git a/meshers/blocky/voxel_blocky_model.cpp b/meshers/blocky/voxel_blocky_model.cpp index d16ac9e79..20d3d2955 100644 --- a/meshers/blocky/voxel_blocky_model.cpp +++ b/meshers/blocky/voxel_blocky_model.cpp @@ -244,6 +244,8 @@ void VoxelBlockyModel::bake(BakedData &baked_data, bool bake_tangents, MaterialI BakedData::Model &model = baked_data.model; + // Note: mesh rotation is not implemented here, it is done in derived classes. + // Set empty sides mask model.empty_sides_mask = 0; for (unsigned int side = 0; side < Cube::SIDE_COUNT; ++side) { @@ -612,7 +614,8 @@ void VoxelBlockyModel::_bind_methods() { "get_collision_mask" ); - ADD_GROUP("Rotation", ""); + // Note: rotation property is currently exposed only in derived classes. + // It will not necessarily be supported by all derived classes. BIND_ENUM_CONSTANT(SIDE_NEGATIVE_X); BIND_ENUM_CONSTANT(SIDE_POSITIVE_X); diff --git a/meshers/blocky/voxel_blocky_model_cube.cpp b/meshers/blocky/voxel_blocky_model_cube.cpp index 2bcf63e99..4a38dcf70 100644 --- a/meshers/blocky/voxel_blocky_model_cube.cpp +++ b/meshers/blocky/voxel_blocky_model_cube.cpp @@ -331,6 +331,14 @@ void VoxelBlockyModelCube::_bind_methods() { ADD_PROPERTY( PropertyInfo(Variant::VECTOR2I, "atlas_size_in_tiles"), "set_atlas_size_in_tiles", "get_atlas_size_in_tiles" ); + + // ADD_GROUP("Rotation", ""); + + ADD_PROPERTY( + PropertyInfo(Variant::INT, "mesh_ortho_rotation_index", PROPERTY_HINT_RANGE, "0,24"), + "set_mesh_ortho_rotation_index", + "get_mesh_ortho_rotation_index" + ); } } // namespace zylann::voxel