From 12f52f6987eaa0a9d54a34482d814d56f8fa70ad Mon Sep 17 00:00:00 2001 From: Chewico Date: Tue, 3 Nov 2026 23:02:44 +0100 Subject: [PATCH] changed to __data --- deerith_client/src/world/cluster_generation.cpp | 4 ++-- deerith_client/src/world/server_communication.cpp | 2 +- deerith_engine_core/include/deerith/world/environment.h | 2 +- deerith_engine_core/src/world/environment.cpp | 4 ++-- deerith_engine_server/src/world/voxel_data_managment.cpp | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/deerith_client/src/world/cluster_generation.cpp b/deerith_client/src/world/cluster_generation.cpp index ff6c334..1e86c9a 100644 --- a/deerith_client/src/world/cluster_generation.cpp +++ b/deerith_client/src/world/cluster_generation.cpp @@ -57,7 +57,7 @@ void deerith::generate_cluster(voxel_cluster_t *_cluster) void deerith::generate_voxel(int x, int y, int z) { - voxel_type_id_t cur_type_id = cluster->data[x][y][z]; + voxel_type_id_t cur_type_id = cluster->__data[x][y][z]; const voxel_type_t &cur_type = get_voxel_type(cur_type_id); if (!cur_type.is_solid) @@ -120,7 +120,7 @@ deerith::voxel_type_id_t deerith::get_cluster_voxel(int x, int y, int z) if (in_bounds_check) { - return cluster->data[x][y][z]; + return cluster->__data[x][y][z]; } glm::ivec3 coords; diff --git a/deerith_client/src/world/server_communication.cpp b/deerith_client/src/world/server_communication.cpp index fba0447..bfff397 100644 --- a/deerith_client/src/world/server_communication.cpp +++ b/deerith_client/src/world/server_communication.cpp @@ -99,7 +99,7 @@ void deerith::process_packet(deerith::packet_cluster_data_t &packet, client_t *c surface_t *surface = get_create_surface(packet.surface_id); voxel_cluster_t *cluster = surface->get_create_cluster(packet.layer); - cluster->data = *packet.__cluster_data; + cluster->__data = *packet.__cluster_data; generate_cluster(cluster); } \ No newline at end of file diff --git a/deerith_engine_core/include/deerith/world/environment.h b/deerith_engine_core/include/deerith/world/environment.h index 6fe6603..29524a0 100644 --- a/deerith_engine_core/include/deerith/world/environment.h +++ b/deerith_engine_core/include/deerith/world/environment.h @@ -18,7 +18,7 @@ namespace deerith int32_t layer; glm::ivec2 surface_id; uint32_t last_update_tick_id; - cluster_voxel_type_id_data_t data = {}; + cluster_voxel_type_id_data_t __data = {}; }; struct surface_t diff --git a/deerith_engine_core/src/world/environment.cpp b/deerith_engine_core/src/world/environment.cpp index b801b34..0c67192 100644 --- a/deerith_engine_core/src/world/environment.cpp +++ b/deerith_engine_core/src/world/environment.cpp @@ -137,7 +137,7 @@ void deerith::set_voxel(voxel_type_id_t voxel_id, glm::ivec3 coordinates) voxel_cluster_t *cluster = surface->get_create_cluster(layer); cluster->last_update_tick_id = get_world_tick(); - cluster->data[internal_voxel_id.x][internal_voxel_id.y][internal_voxel_id.z] = voxel_id; + cluster->__data[internal_voxel_id.x][internal_voxel_id.y][internal_voxel_id.z] = voxel_id; } deerith::voxel_type_id_t deerith::get_voxel_id(glm::ivec3 coordinates) @@ -160,7 +160,7 @@ deerith::voxel_type_id_t deerith::get_voxel_id(glm::ivec3 coordinates) return 0; } - return cluster->data[internal_voxel_id.x][internal_voxel_id.y][internal_voxel_id.z]; + return cluster->__data[internal_voxel_id.x][internal_voxel_id.y][internal_voxel_id.z]; } const deerith::voxel_type_t &deerith::get_voxel(glm::ivec3 coordinates) diff --git a/deerith_engine_server/src/world/voxel_data_managment.cpp b/deerith_engine_server/src/world/voxel_data_managment.cpp index ec18068..0bfb03c 100644 --- a/deerith_engine_server/src/world/voxel_data_managment.cpp +++ b/deerith_engine_server/src/world/voxel_data_managment.cpp @@ -103,7 +103,7 @@ void deerith::send_cluster_info_to_client(client_t *client, voxel_cluster_t *clu cluster_data.layer = cluster->layer; cluster_data.__cluster_data = std::make_unique(); - *cluster_data.__cluster_data = cluster->data; + *cluster_data.__cluster_data = cluster->__data; router_send_packet(cluster_data, client); deerith_trace("sent cluster data to client in {} ms", get_chrono_ms());