mirror of
https://github.com/Relintai/voxelman.git
synced 2025-01-12 15:01:09 +01:00
Hide a few properties from the editor, and also from serialization.
This commit is contained in:
parent
49af0c9f30
commit
b970c86264
@ -1543,31 +1543,31 @@ void VoxelChunkDefault::wait_and_finish_thread() {
|
||||
void VoxelChunkDefault::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("get_build_flags"), &VoxelChunkDefault::get_build_flags);
|
||||
ClassDB::bind_method(D_METHOD("set_build_flags", "value"), &VoxelChunkDefault::set_build_flags);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "build_flags", PROPERTY_HINT_FLAGS, BINDING_STRING_BUILD_FLAGS), "set_build_flags", "get_build_flags");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "build_flags", PROPERTY_HINT_FLAGS, BINDING_STRING_BUILD_FLAGS, 0), "set_build_flags", "get_build_flags");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_active_build_phase_type"), &VoxelChunkDefault::get_active_build_phase_type);
|
||||
ClassDB::bind_method(D_METHOD("set_active_build_phase_type", "value"), &VoxelChunkDefault::set_active_build_phase_type);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "active_build_phase_type", PROPERTY_HINT_ENUM, BINDING_STRING_ACTIVE_BUILD_PHASE_TYPE), "set_active_build_phase_type", "get_active_build_phase_type");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "active_build_phase_type", PROPERTY_HINT_ENUM, BINDING_STRING_ACTIVE_BUILD_PHASE_TYPE, 0), "set_active_build_phase_type", "get_active_build_phase_type");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_lod_size"), &VoxelChunkDefault::get_lod_size);
|
||||
ClassDB::bind_method(D_METHOD("set_lod_size", "value"), &VoxelChunkDefault::set_lod_size);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "lod_size"), "set_lod_size", "get_lod_size");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "lod_size", PROPERTY_HINT_NONE, "", 0), "set_lod_size", "get_lod_size");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_current_build_phase"), &VoxelChunkDefault::get_current_build_phase);
|
||||
ClassDB::bind_method(D_METHOD("set_current_build_phase", "value"), &VoxelChunkDefault::set_current_build_phase);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "current_build_phase"), "set_current_build_phase", "get_current_build_phase");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "current_build_phase", PROPERTY_HINT_NONE, "", 0), "set_current_build_phase", "get_current_build_phase");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_max_build_phase"), &VoxelChunkDefault::get_max_build_phase);
|
||||
ClassDB::bind_method(D_METHOD("set_max_build_phase", "value"), &VoxelChunkDefault::set_max_build_phase);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "max_build_phase"), "set_max_build_phase", "get_max_build_phase");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "max_build_phase", PROPERTY_HINT_NONE, "", 0), "set_max_build_phase", "get_max_build_phase");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_lights_dirty"), &VoxelChunkDefault::get_lights_dirty);
|
||||
ClassDB::bind_method(D_METHOD("set_lights_dirty", "value"), &VoxelChunkDefault::set_lights_dirty);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "lights_dirty", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_EDITOR), "set_lights_dirty", "get_lights_dirty");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "lights_dirty", PROPERTY_HINT_NONE, "", 0), "set_lights_dirty", "get_lights_dirty");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_lod_num"), &VoxelChunkDefault::get_lod_num);
|
||||
ClassDB::bind_method(D_METHOD("set_lod_num"), &VoxelChunkDefault::set_lod_num);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "lod_num"), "set_lod_num", "get_lod_num");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "lod_num", PROPERTY_HINT_NONE, "", 0), "set_lod_num", "get_lod_num");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_current_lod_level"), &VoxelChunkDefault::get_current_lod_level);
|
||||
ClassDB::bind_method(D_METHOD("set_current_lod_level"), &VoxelChunkDefault::set_current_lod_level);
|
||||
|
@ -894,7 +894,7 @@ void VoxelChunk::_bind_methods() {
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_is_build_threaded"), &VoxelChunk::get_is_build_threaded);
|
||||
ClassDB::bind_method(D_METHOD("set_is_build_threaded", "value"), &VoxelChunk::set_is_build_threaded);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "is_build_threaded"), "set_is_build_threaded", "get_is_build_threaded");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "is_build_threaded", PROPERTY_HINT_NONE, "", 0), "set_is_build_threaded", "get_is_build_threaded");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_transform"), &VoxelChunk::get_transform);
|
||||
ClassDB::bind_method(D_METHOD("set_transform", "value"), &VoxelChunk::set_transform);
|
||||
@ -906,15 +906,15 @@ void VoxelChunk::_bind_methods() {
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_is_generating"), &VoxelChunk::get_is_generating);
|
||||
ClassDB::bind_method(D_METHOD("set_is_generating", "value"), &VoxelChunk::set_is_generating);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "is_generating"), "set_is_generating", "get_is_generating");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "is_generating", PROPERTY_HINT_NONE, "", 0), "set_is_generating", "get_is_generating");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_dirty"), &VoxelChunk::get_dirty);
|
||||
ClassDB::bind_method(D_METHOD("set_dirty", "value"), &VoxelChunk::set_dirty);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "dirty"), "set_dirty", "get_dirty");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "dirty", PROPERTY_HINT_NONE, "", 0), "set_dirty", "get_dirty");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_state"), &VoxelChunk::get_state);
|
||||
ClassDB::bind_method(D_METHOD("set_state", "value"), &VoxelChunk::set_state);
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "state"), "set_state", "get_state");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "state", PROPERTY_HINT_NONE, "", 0), "set_state", "get_state");
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_position_x"), &VoxelChunk::get_position_x);
|
||||
ClassDB::bind_method(D_METHOD("set_position_x", "value"), &VoxelChunk::set_position_x);
|
||||
|
Loading…
Reference in New Issue
Block a user