diff --git a/props/prop_2d_data.cpp b/props/prop_2d_data.cpp index b6f0422..7437ca5 100644 --- a/props/prop_2d_data.cpp +++ b/props/prop_2d_data.cpp @@ -41,19 +41,6 @@ void Prop2DData::set_id(const int value) { _id = value; } -bool Prop2DData::get_snap_to_mesh() const { - return _snap_to_mesh; -} -void Prop2DData::set_snap_to_mesh(const bool value) { - _snap_to_mesh = value; -} - -Vector3 Prop2DData::get_snap_axis() const { - return _snap_axis; -} -void Prop2DData::set_snap_axis(const Vector3 &value) { - _snap_axis = value; -} Ref Prop2DData::get_prop(const int index) const { ERR_FAIL_INDEX_V(index, _props.size(), Ref()); @@ -154,14 +141,6 @@ Prop2DData::~Prop2DData() { } void Prop2DData::_bind_methods() { - ClassDB::bind_method(D_METHOD("get_snap_to_mesh"), &Prop2DData::get_snap_to_mesh); - ClassDB::bind_method(D_METHOD("set_snap_to_mesh", "value"), &Prop2DData::set_snap_to_mesh); - ADD_PROPERTY(PropertyInfo(Variant::BOOL, "snap_to_mesh"), "set_snap_to_mesh", "get_snap_to_mesh"); - - ClassDB::bind_method(D_METHOD("get_snap_axis"), &Prop2DData::get_snap_axis); - ClassDB::bind_method(D_METHOD("set_snap_axis", "value"), &Prop2DData::set_snap_axis); - ADD_PROPERTY(PropertyInfo(Variant::VECTOR3, "snap_axis"), "set_snap_axis", "get_snap_axis"); - ClassDB::bind_method(D_METHOD("get_prop", "index"), &Prop2DData::get_prop); ClassDB::bind_method(D_METHOD("set_prop", "index", "spell"), &Prop2DData::set_prop); ClassDB::bind_method(D_METHOD("add_prop", "prop"), &Prop2DData::add_prop); diff --git a/props/prop_2d_data.h b/props/prop_2d_data.h index 527e1a5..f96486b 100644 --- a/props/prop_2d_data.h +++ b/props/prop_2d_data.h @@ -57,12 +57,6 @@ public: int get_id() const; void set_id(const int value); - bool get_snap_to_mesh() const; - void set_snap_to_mesh(const bool value); - - Vector3 get_snap_axis() const; - void set_snap_axis(const Vector3 &value); - Ref get_prop(const int index) const; void set_prop(const int index, const Ref prop); void add_prop(const Ref prop); diff --git a/props/prop_2d_data_prop.cpp b/props/prop_2d_data_prop.cpp index f8232a9..509ec54 100644 --- a/props/prop_2d_data_prop.cpp +++ b/props/prop_2d_data_prop.cpp @@ -32,20 +32,6 @@ void Prop2DDataProp2D::set_prop(const Ref value) { _prop = value; } -bool Prop2DDataProp2D::get_snap_to_mesh() { - return _snap_to_mesh; -} -void Prop2DDataProp2D::set_snap_to_mesh(bool value) { - _snap_to_mesh = value; -} - -Vector3 Prop2DDataProp2D::get_snap_axis() { - return _snap_axis; -} -void Prop2DDataProp2D::set_snap_axis(Vector3 value) { - _snap_axis = value; -} - #if TEXTURE_PACKER_PRESENT void Prop2DDataProp2D::_add_textures_into(Ref texture_packer) { if (get_prop().is_valid()) { @@ -95,14 +81,6 @@ void Prop2DDataProp2D::_bind_methods() { ClassDB::bind_method(D_METHOD("set_prop", "value"), &Prop2DDataProp2D::set_prop); ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "prop", PROPERTY_HINT_RESOURCE_TYPE, "Prop2DData"), "set_prop", "get_prop"); - ClassDB::bind_method(D_METHOD("get_snap_to_mesh"), &Prop2DDataProp2D::get_snap_to_mesh); - ClassDB::bind_method(D_METHOD("set_snap_to_mesh", "value"), &Prop2DDataProp2D::set_snap_to_mesh); - ADD_PROPERTY(PropertyInfo(Variant::BOOL, "snap_to_mesh"), "set_snap_to_mesh", "get_snap_to_mesh"); - - ClassDB::bind_method(D_METHOD("get_snap_axis"), &Prop2DDataProp2D::get_snap_axis); - ClassDB::bind_method(D_METHOD("set_snap_axis", "value"), &Prop2DDataProp2D::set_snap_axis); - ADD_PROPERTY(PropertyInfo(Variant::VECTOR3, "snap_axis"), "set_snap_axis", "get_snap_axis"); - #if TEXTURE_PACKER_PRESENT ClassDB::bind_method(D_METHOD("_add_textures_into", "texture_packer"), &Prop2DDataProp2D::_add_textures_into); #endif diff --git a/props/prop_2d_data_prop.h b/props/prop_2d_data_prop.h index 84ca377..8304880 100644 --- a/props/prop_2d_data_prop.h +++ b/props/prop_2d_data_prop.h @@ -40,12 +40,6 @@ public: Ref get_prop() const; void set_prop(const Ref value); - bool get_snap_to_mesh(); - void set_snap_to_mesh(bool value); - - Vector3 get_snap_axis(); - void set_snap_axis(Vector3 value); - #if TEXTURE_PACKER_PRESENT void _add_textures_into(Ref texture_packer); #endif diff --git a/props/prop_2d_data_scene.cpp b/props/prop_2d_data_scene.cpp index 4faa279..382dd8b 100644 --- a/props/prop_2d_data_scene.cpp +++ b/props/prop_2d_data_scene.cpp @@ -32,20 +32,6 @@ void Prop2DDataScene::set_scene(const Ref &value) { _scene = value; } -bool Prop2DDataScene::get_snap_to_mesh() { - return _snap_to_mesh; -} -void Prop2DDataScene::set_snap_to_mesh(bool value) { - _snap_to_mesh = value; -} - -Vector3 Prop2DDataScene::get_snap_axis() { - return _snap_axis; -} -void Prop2DDataScene::set_snap_axis(Vector3 value) { - _snap_axis = value; -} - bool Prop2DDataScene::_processor_handles(Node *node) { Prop2DSceneInstance *i = Object::cast_to(node); @@ -86,12 +72,4 @@ void Prop2DDataScene::_bind_methods() { ClassDB::bind_method(D_METHOD("get_scene"), &Prop2DDataScene::get_scene); ClassDB::bind_method(D_METHOD("set_scene", "value"), &Prop2DDataScene::set_scene); ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "scene", PROPERTY_HINT_RESOURCE_TYPE, "PackedScene"), "set_scene", "get_scene"); - - ClassDB::bind_method(D_METHOD("get_snap_to_mesh"), &Prop2DDataScene::get_snap_to_mesh); - ClassDB::bind_method(D_METHOD("set_snap_to_mesh", "value"), &Prop2DDataScene::set_snap_to_mesh); - ADD_PROPERTY(PropertyInfo(Variant::BOOL, "snap_to_mesh"), "set_snap_to_mesh", "get_snap_to_mesh"); - - ClassDB::bind_method(D_METHOD("get_snap_axis"), &Prop2DDataScene::get_snap_axis); - ClassDB::bind_method(D_METHOD("set_snap_axis", "value"), &Prop2DDataScene::set_snap_axis); - ADD_PROPERTY(PropertyInfo(Variant::VECTOR3, "snap_axis"), "set_snap_axis", "get_snap_axis"); } diff --git a/props/prop_2d_data_scene.h b/props/prop_2d_data_scene.h index 17c32ab..ca019df 100644 --- a/props/prop_2d_data_scene.h +++ b/props/prop_2d_data_scene.h @@ -35,12 +35,6 @@ public: Ref get_scene(); void set_scene(const Ref &value); - bool get_snap_to_mesh(); - void set_snap_to_mesh(bool value); - - Vector3 get_snap_axis(); - void set_snap_axis(Vector3 value); - bool _processor_handles(Node *node); void _processor_process(Ref prop_data, Node *node, const Transform2D &transform); Node *_processor_get_node_for(const Transform2D &transform);