summaryrefslogtreecommitdiff
path: root/scene/resources
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2017-01-02 23:03:46 -0300
committerJuan Linietsky <reduzio@gmail.com>2017-01-02 23:03:46 -0300
commit118eed485e8f928a5a0dab530ae93211afa10525 (patch)
tree83efb5cbcebb7046e5b64dfe1712475a7d3b7f14 /scene/resources
parentce26eb74bca48f16e9a34b4eb1c34e50dfc5daae (diff)
ObjectTypeDB was renamed to ClassDB. Types are meant to be more generic to Variant.
All usages of "type" to refer to classes were renamed to "class" ClassDB has been exposed to GDScript. OBJ_TYPE() macro is now GDCLASS()
Diffstat (limited to 'scene/resources')
-rw-r--r--scene/resources/animation.cpp76
-rw-r--r--scene/resources/animation.h2
-rw-r--r--scene/resources/audio_stream.cpp24
-rw-r--r--scene/resources/audio_stream.h4
-rw-r--r--scene/resources/audio_stream_resampled.h2
-rw-r--r--scene/resources/bit_mask.cpp18
-rw-r--r--scene/resources/bit_mask.h2
-rw-r--r--scene/resources/bounds.cpp4
-rw-r--r--scene/resources/bounds.h2
-rw-r--r--scene/resources/box_shape.cpp4
-rw-r--r--scene/resources/box_shape.h2
-rw-r--r--scene/resources/canvas.h2
-rw-r--r--scene/resources/capsule_shape.cpp8
-rw-r--r--scene/resources/capsule_shape.h2
-rw-r--r--scene/resources/capsule_shape_2d.cpp8
-rw-r--r--scene/resources/capsule_shape_2d.h2
-rw-r--r--scene/resources/circle_shape_2d.cpp4
-rw-r--r--scene/resources/circle_shape_2d.h2
-rw-r--r--scene/resources/color_ramp.cpp24
-rw-r--r--scene/resources/color_ramp.h2
-rw-r--r--scene/resources/concave_polygon_shape.cpp4
-rw-r--r--scene/resources/concave_polygon_shape.h2
-rw-r--r--scene/resources/concave_polygon_shape_2d.cpp4
-rw-r--r--scene/resources/concave_polygon_shape_2d.h2
-rw-r--r--scene/resources/convex_polygon_shape.cpp4
-rw-r--r--scene/resources/convex_polygon_shape.h2
-rw-r--r--scene/resources/convex_polygon_shape_2d.cpp6
-rw-r--r--scene/resources/convex_polygon_shape_2d.h2
-rw-r--r--scene/resources/curve.cpp138
-rw-r--r--scene/resources/curve.h6
-rw-r--r--scene/resources/dynamic_font.cpp34
-rw-r--r--scene/resources/dynamic_font.h6
-rw-r--r--scene/resources/dynamic_font_stb.cpp8
-rw-r--r--scene/resources/dynamic_font_stb.h6
-rw-r--r--scene/resources/environment.cpp232
-rw-r--r--scene/resources/environment.h2
-rw-r--r--scene/resources/event_stream.h4
-rw-r--r--scene/resources/font.cpp56
-rw-r--r--scene/resources/font.h4
-rw-r--r--scene/resources/gibberish_stream.cpp16
-rw-r--r--scene/resources/gibberish_stream.h2
-rw-r--r--scene/resources/material.cpp128
-rw-r--r--scene/resources/material.h4
-rw-r--r--scene/resources/mesh.cpp50
-rw-r--r--scene/resources/mesh.h2
-rw-r--r--scene/resources/mesh_data_tool.cpp76
-rw-r--r--scene/resources/mesh_data_tool.h2
-rw-r--r--scene/resources/mesh_library.cpp26
-rw-r--r--scene/resources/mesh_library.h2
-rw-r--r--scene/resources/multimesh.cpp40
-rw-r--r--scene/resources/multimesh.h2
-rw-r--r--scene/resources/packed_scene.cpp56
-rw-r--r--scene/resources/packed_scene.h4
-rw-r--r--scene/resources/plane_shape.cpp4
-rw-r--r--scene/resources/plane_shape.h2
-rw-r--r--scene/resources/polygon_path_finder.cpp22
-rw-r--r--scene/resources/polygon_path_finder.h2
-rw-r--r--scene/resources/ray_shape.cpp4
-rw-r--r--scene/resources/ray_shape.h2
-rw-r--r--scene/resources/rectangle_shape_2d.cpp4
-rw-r--r--scene/resources/rectangle_shape_2d.h2
-rw-r--r--scene/resources/room.cpp4
-rw-r--r--scene/resources/room.h2
-rw-r--r--scene/resources/sample.cpp34
-rw-r--r--scene/resources/sample.h2
-rw-r--r--scene/resources/sample_library.cpp18
-rw-r--r--scene/resources/sample_library.h2
-rw-r--r--scene/resources/scene_format_text.cpp14
-rw-r--r--scene/resources/scene_preloader.cpp18
-rw-r--r--scene/resources/scene_preloader.h2
-rw-r--r--scene/resources/segment_shape_2d.cpp12
-rw-r--r--scene/resources/segment_shape_2d.h4
-rw-r--r--scene/resources/shader.cpp14
-rw-r--r--scene/resources/shader.h8
-rw-r--r--scene/resources/shader_graph.cpp152
-rw-r--r--scene/resources/shader_graph.h6
-rw-r--r--scene/resources/shape.h2
-rw-r--r--scene/resources/shape_2d.cpp12
-rw-r--r--scene/resources/shape_2d.h2
-rw-r--r--scene/resources/shape_line_2d.cpp8
-rw-r--r--scene/resources/shape_line_2d.h2
-rw-r--r--scene/resources/sky_box.cpp8
-rw-r--r--scene/resources/sky_box.h4
-rw-r--r--scene/resources/space_2d.cpp4
-rw-r--r--scene/resources/space_2d.h2
-rw-r--r--scene/resources/sphere_shape.cpp4
-rw-r--r--scene/resources/sphere_shape.h2
-rw-r--r--scene/resources/style_box.cpp68
-rw-r--r--scene/resources/style_box.h8
-rw-r--r--scene/resources/surface_tool.cpp38
-rw-r--r--scene/resources/surface_tool.h2
-rw-r--r--scene/resources/texture.cpp118
-rw-r--r--scene/resources/texture.h10
-rw-r--r--scene/resources/theme.cpp62
-rw-r--r--scene/resources/theme.h2
-rw-r--r--scene/resources/tile_set.cpp62
-rw-r--r--scene/resources/tile_set.h2
-rw-r--r--scene/resources/video_stream.h4
-rw-r--r--scene/resources/world.cpp12
-rw-r--r--scene/resources/world.h2
-rw-r--r--scene/resources/world_2d.cpp8
-rw-r--r--scene/resources/world_2d.h2
102 files changed, 955 insertions, 955 deletions
diff --git a/scene/resources/animation.cpp b/scene/resources/animation.cpp
index d86c476ef4..b5c438d953 100644
--- a/scene/resources/animation.cpp
+++ b/scene/resources/animation.cpp
@@ -1680,59 +1680,59 @@ float Animation::get_step() const{
void Animation::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("add_track","type","at_pos"),&Animation::add_track,DEFVAL(-1));
- ObjectTypeDB::bind_method(_MD("remove_track","idx"),&Animation::remove_track);
- ObjectTypeDB::bind_method(_MD("get_track_count"),&Animation::get_track_count);
- ObjectTypeDB::bind_method(_MD("track_get_type","idx"),&Animation::track_get_type);
- ObjectTypeDB::bind_method(_MD("track_get_path","idx"),&Animation::track_get_path);
- ObjectTypeDB::bind_method(_MD("track_set_path","idx","path"),&Animation::track_set_path);
- ObjectTypeDB::bind_method(_MD("find_track","path"),&Animation::find_track);
+ ClassDB::bind_method(_MD("add_track","type","at_pos"),&Animation::add_track,DEFVAL(-1));
+ ClassDB::bind_method(_MD("remove_track","idx"),&Animation::remove_track);
+ ClassDB::bind_method(_MD("get_track_count"),&Animation::get_track_count);
+ ClassDB::bind_method(_MD("track_get_type","idx"),&Animation::track_get_type);
+ ClassDB::bind_method(_MD("track_get_path","idx"),&Animation::track_get_path);
+ ClassDB::bind_method(_MD("track_set_path","idx","path"),&Animation::track_set_path);
+ ClassDB::bind_method(_MD("find_track","path"),&Animation::find_track);
- ObjectTypeDB::bind_method(_MD("track_move_up","idx"),&Animation::track_move_up);
- ObjectTypeDB::bind_method(_MD("track_move_down","idx"),&Animation::track_move_down);
+ ClassDB::bind_method(_MD("track_move_up","idx"),&Animation::track_move_up);
+ ClassDB::bind_method(_MD("track_move_down","idx"),&Animation::track_move_down);
- ObjectTypeDB::bind_method(_MD("track_set_imported","idx","imported"),&Animation::track_set_imported);
- ObjectTypeDB::bind_method(_MD("track_is_imported","idx"),&Animation::track_is_imported);
+ ClassDB::bind_method(_MD("track_set_imported","idx","imported"),&Animation::track_set_imported);
+ ClassDB::bind_method(_MD("track_is_imported","idx"),&Animation::track_is_imported);
- ObjectTypeDB::bind_method(_MD("transform_track_insert_key","idx","time","loc","rot","scale"),&Animation::transform_track_insert_key);
- ObjectTypeDB::bind_method(_MD("track_insert_key","idx","time","key","transition"),&Animation::track_insert_key,DEFVAL(1));
- ObjectTypeDB::bind_method(_MD("track_remove_key","idx","key_idx"),&Animation::track_remove_key);
- ObjectTypeDB::bind_method(_MD("track_remove_key_at_pos","idx","pos"),&Animation::track_remove_key_at_pos);
- ObjectTypeDB::bind_method(_MD("track_set_key_value","idx","key","value"),&Animation::track_set_key_value);
- ObjectTypeDB::bind_method(_MD("track_set_key_transition","idx","key_idx","transition"),&Animation::track_set_key_transition);
- ObjectTypeDB::bind_method(_MD("track_get_key_transition","idx","key_idx"),&Animation::track_get_key_transition);
+ ClassDB::bind_method(_MD("transform_track_insert_key","idx","time","loc","rot","scale"),&Animation::transform_track_insert_key);
+ ClassDB::bind_method(_MD("track_insert_key","idx","time","key","transition"),&Animation::track_insert_key,DEFVAL(1));
+ ClassDB::bind_method(_MD("track_remove_key","idx","key_idx"),&Animation::track_remove_key);
+ ClassDB::bind_method(_MD("track_remove_key_at_pos","idx","pos"),&Animation::track_remove_key_at_pos);
+ ClassDB::bind_method(_MD("track_set_key_value","idx","key","value"),&Animation::track_set_key_value);
+ ClassDB::bind_method(_MD("track_set_key_transition","idx","key_idx","transition"),&Animation::track_set_key_transition);
+ ClassDB::bind_method(_MD("track_get_key_transition","idx","key_idx"),&Animation::track_get_key_transition);
- ObjectTypeDB::bind_method(_MD("track_get_key_count","idx"),&Animation::track_get_key_count);
- ObjectTypeDB::bind_method(_MD("track_get_key_value","idx","key_idx"),&Animation::track_get_key_value);
- ObjectTypeDB::bind_method(_MD("track_get_key_time","idx","key_idx"),&Animation::track_get_key_time);
- ObjectTypeDB::bind_method(_MD("track_find_key","idx","time","exact"),&Animation::track_find_key,DEFVAL(false));
+ ClassDB::bind_method(_MD("track_get_key_count","idx"),&Animation::track_get_key_count);
+ ClassDB::bind_method(_MD("track_get_key_value","idx","key_idx"),&Animation::track_get_key_value);
+ ClassDB::bind_method(_MD("track_get_key_time","idx","key_idx"),&Animation::track_get_key_time);
+ ClassDB::bind_method(_MD("track_find_key","idx","time","exact"),&Animation::track_find_key,DEFVAL(false));
- ObjectTypeDB::bind_method(_MD("track_set_interpolation_type","idx","interpolation"),&Animation::track_set_interpolation_type);
- ObjectTypeDB::bind_method(_MD("track_get_interpolation_type","idx"),&Animation::track_get_interpolation_type);
+ ClassDB::bind_method(_MD("track_set_interpolation_type","idx","interpolation"),&Animation::track_set_interpolation_type);
+ ClassDB::bind_method(_MD("track_get_interpolation_type","idx"),&Animation::track_get_interpolation_type);
- ObjectTypeDB::bind_method(_MD("transform_track_interpolate","idx","time_sec"),&Animation::_transform_track_interpolate);
- ObjectTypeDB::bind_method(_MD("value_track_set_update_mode","idx","mode"),&Animation::value_track_set_update_mode);
- ObjectTypeDB::bind_method(_MD("value_track_get_update_mode","idx"),&Animation::value_track_get_update_mode);
+ ClassDB::bind_method(_MD("transform_track_interpolate","idx","time_sec"),&Animation::_transform_track_interpolate);
+ ClassDB::bind_method(_MD("value_track_set_update_mode","idx","mode"),&Animation::value_track_set_update_mode);
+ ClassDB::bind_method(_MD("value_track_get_update_mode","idx"),&Animation::value_track_get_update_mode);
- ObjectTypeDB::bind_method(_MD("value_track_get_key_indices","idx","time_sec","delta"),&Animation::_value_track_get_key_indices);
+ ClassDB::bind_method(_MD("value_track_get_key_indices","idx","time_sec","delta"),&Animation::_value_track_get_key_indices);
- ObjectTypeDB::bind_method(_MD("method_track_get_key_indices","idx","time_sec","delta"),&Animation::_method_track_get_key_indices);
- ObjectTypeDB::bind_method(_MD("method_track_get_name","idx","key_idx"),&Animation::method_track_get_name);
- ObjectTypeDB::bind_method(_MD("method_track_get_params","idx","key_idx"),&Animation::method_track_get_params);
+ ClassDB::bind_method(_MD("method_track_get_key_indices","idx","time_sec","delta"),&Animation::_method_track_get_key_indices);
+ ClassDB::bind_method(_MD("method_track_get_name","idx","key_idx"),&Animation::method_track_get_name);
+ ClassDB::bind_method(_MD("method_track_get_params","idx","key_idx"),&Animation::method_track_get_params);
- ObjectTypeDB::bind_method(_MD("set_length","time_sec"),&Animation::set_length);
- ObjectTypeDB::bind_method(_MD("get_length"),&Animation::get_length);
+ ClassDB::bind_method(_MD("set_length","time_sec"),&Animation::set_length);
+ ClassDB::bind_method(_MD("get_length"),&Animation::get_length);
- ObjectTypeDB::bind_method(_MD("set_loop","enabled"),&Animation::set_loop);
- ObjectTypeDB::bind_method(_MD("has_loop"),&Animation::has_loop);
+ ClassDB::bind_method(_MD("set_loop","enabled"),&Animation::set_loop);
+ ClassDB::bind_method(_MD("has_loop"),&Animation::has_loop);
- ObjectTypeDB::bind_method(_MD("set_step","size_sec"),&Animation::set_step);
- ObjectTypeDB::bind_method(_MD("get_step"),&Animation::get_step);
+ ClassDB::bind_method(_MD("set_step","size_sec"),&Animation::set_step);
+ ClassDB::bind_method(_MD("get_step"),&Animation::get_step);
- ObjectTypeDB::bind_method(_MD("clear"),&Animation::clear);
+ ClassDB::bind_method(_MD("clear"),&Animation::clear);
BIND_CONSTANT( TYPE_VALUE );
BIND_CONSTANT( TYPE_TRANSFORM );
diff --git a/scene/resources/animation.h b/scene/resources/animation.h
index 6f39d069f4..90824d8c7b 100644
--- a/scene/resources/animation.h
+++ b/scene/resources/animation.h
@@ -35,7 +35,7 @@
*/
class Animation : public Resource {
- OBJ_TYPE( Animation, Resource );
+ GDCLASS( Animation, Resource );
RES_BASE_EXTENSION("anm");
public:
diff --git a/scene/resources/audio_stream.cpp b/scene/resources/audio_stream.cpp
index f6dc99b8a3..7c269de007 100644
--- a/scene/resources/audio_stream.cpp
+++ b/scene/resources/audio_stream.cpp
@@ -33,22 +33,22 @@
void AudioStreamPlayback::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("play","from_pos_sec"),&AudioStreamPlayback::play,DEFVAL(0));
- ObjectTypeDB::bind_method(_MD("stop"),&AudioStreamPlayback::stop);
- ObjectTypeDB::bind_method(_MD("is_playing"),&AudioStreamPlayback::is_playing);
+ ClassDB::bind_method(_MD("play","from_pos_sec"),&AudioStreamPlayback::play,DEFVAL(0));
+ ClassDB::bind_method(_MD("stop"),&AudioStreamPlayback::stop);
+ ClassDB::bind_method(_MD("is_playing"),&AudioStreamPlayback::is_playing);
- ObjectTypeDB::bind_method(_MD("set_loop","enabled"),&AudioStreamPlayback::set_loop);
- ObjectTypeDB::bind_method(_MD("has_loop"),&AudioStreamPlayback::has_loop);
+ ClassDB::bind_method(_MD("set_loop","enabled"),&AudioStreamPlayback::set_loop);
+ ClassDB::bind_method(_MD("has_loop"),&AudioStreamPlayback::has_loop);
- ObjectTypeDB::bind_method(_MD("get_loop_count"),&AudioStreamPlayback::get_loop_count);
+ ClassDB::bind_method(_MD("get_loop_count"),&AudioStreamPlayback::get_loop_count);
- ObjectTypeDB::bind_method(_MD("seek_pos","pos"),&AudioStreamPlayback::seek_pos);
- ObjectTypeDB::bind_method(_MD("get_pos"),&AudioStreamPlayback::get_pos);
+ ClassDB::bind_method(_MD("seek_pos","pos"),&AudioStreamPlayback::seek_pos);
+ ClassDB::bind_method(_MD("get_pos"),&AudioStreamPlayback::get_pos);
- ObjectTypeDB::bind_method(_MD("get_length"),&AudioStreamPlayback::get_length);
- ObjectTypeDB::bind_method(_MD("get_channels"),&AudioStreamPlayback::get_channels);
- ObjectTypeDB::bind_method(_MD("get_mix_rate"),&AudioStreamPlayback::get_mix_rate);
- ObjectTypeDB::bind_method(_MD("get_minimum_buffer_size"),&AudioStreamPlayback::get_minimum_buffer_size);
+ ClassDB::bind_method(_MD("get_length"),&AudioStreamPlayback::get_length);
+ ClassDB::bind_method(_MD("get_channels"),&AudioStreamPlayback::get_channels);
+ ClassDB::bind_method(_MD("get_mix_rate"),&AudioStreamPlayback::get_mix_rate);
+ ClassDB::bind_method(_MD("get_minimum_buffer_size"),&AudioStreamPlayback::get_minimum_buffer_size);
}
diff --git a/scene/resources/audio_stream.h b/scene/resources/audio_stream.h
index 2039c4e902..b79707cd32 100644
--- a/scene/resources/audio_stream.h
+++ b/scene/resources/audio_stream.h
@@ -34,7 +34,7 @@
class AudioStreamPlayback : public Reference {
- OBJ_TYPE( AudioStreamPlayback, Reference );
+ GDCLASS( AudioStreamPlayback, Reference );
protected:
static void _bind_methods();
public:
@@ -67,7 +67,7 @@ public:
class AudioStream : public Resource {
- OBJ_TYPE( AudioStream, Resource );
+ GDCLASS( AudioStream, Resource );
OBJ_SAVE_TYPE( AudioStream ); //children are all saved as AudioStream, so they can be exchanged
protected:
diff --git a/scene/resources/audio_stream_resampled.h b/scene/resources/audio_stream_resampled.h
index 70adc53fb0..761643b027 100644
--- a/scene/resources/audio_stream_resampled.h
+++ b/scene/resources/audio_stream_resampled.h
@@ -34,7 +34,7 @@
#if 0
class AudioStreamResampled : public AudioStream {
- OBJ_TYPE(AudioStreamResampled,AudioStream);
+ GDCLASS(AudioStreamResampled,AudioStream);
uint32_t rb_bits;
uint32_t rb_len;
diff --git a/scene/resources/bit_mask.cpp b/scene/resources/bit_mask.cpp
index 5763be2e08..81ba28fd26 100644
--- a/scene/resources/bit_mask.cpp
+++ b/scene/resources/bit_mask.cpp
@@ -177,19 +177,19 @@ Dictionary BitMap::_get_data() const{
void BitMap::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("create","size"),&BitMap::create);
- ObjectTypeDB::bind_method(_MD("create_from_image_alpha","image"),&BitMap::create_from_image_alpha);
+ ClassDB::bind_method(_MD("create","size"),&BitMap::create);
+ ClassDB::bind_method(_MD("create_from_image_alpha","image"),&BitMap::create_from_image_alpha);
- ObjectTypeDB::bind_method(_MD("set_bit","pos","bit"),&BitMap::set_bit);
- ObjectTypeDB::bind_method(_MD("get_bit","pos"),&BitMap::get_bit);
+ ClassDB::bind_method(_MD("set_bit","pos","bit"),&BitMap::set_bit);
+ ClassDB::bind_method(_MD("get_bit","pos"),&BitMap::get_bit);
- ObjectTypeDB::bind_method(_MD("set_bit_rect","p_rect","bit"),&BitMap::set_bit_rect);
- ObjectTypeDB::bind_method(_MD("get_true_bit_count"),&BitMap::get_true_bit_count);
+ ClassDB::bind_method(_MD("set_bit_rect","p_rect","bit"),&BitMap::set_bit_rect);
+ ClassDB::bind_method(_MD("get_true_bit_count"),&BitMap::get_true_bit_count);
- ObjectTypeDB::bind_method(_MD("get_size"),&BitMap::get_size);
+ ClassDB::bind_method(_MD("get_size"),&BitMap::get_size);
- ObjectTypeDB::bind_method(_MD("_set_data"),&BitMap::_set_data);
- ObjectTypeDB::bind_method(_MD("_get_data"),&BitMap::_get_data);
+ ClassDB::bind_method(_MD("_set_data"),&BitMap::_set_data);
+ ClassDB::bind_method(_MD("_get_data"),&BitMap::_get_data);
ADD_PROPERTY(PropertyInfo(Variant::DICTIONARY,"data",PROPERTY_HINT_NONE,"",PROPERTY_USAGE_NOEDITOR),_SCS("_set_data"),_SCS("_get_data"));
diff --git a/scene/resources/bit_mask.h b/scene/resources/bit_mask.h
index 1bc8688aaa..f749a53e34 100644
--- a/scene/resources/bit_mask.h
+++ b/scene/resources/bit_mask.h
@@ -35,7 +35,7 @@
class BitMap : public Resource {
- OBJ_TYPE(BitMap,Resource);
+ GDCLASS(BitMap,Resource);
OBJ_SAVE_TYPE(BitMap);
RES_BASE_EXTENSION("pbm");
diff --git a/scene/resources/bounds.cpp b/scene/resources/bounds.cpp
index d8f8745ae6..03d819451d 100644
--- a/scene/resources/bounds.cpp
+++ b/scene/resources/bounds.cpp
@@ -31,8 +31,8 @@
void Bounds::_bind_methods() {
- ObjectTypeDB::bind_method( _MD("set_bsp_tree","bsp_tree"),&Bounds::set_bsp_tree);
- ObjectTypeDB::bind_method( _MD("get_bsp_tree"),&Bounds::get_bsp_tree );
+ ClassDB::bind_method( _MD("set_bsp_tree","bsp_tree"),&Bounds::set_bsp_tree);
+ ClassDB::bind_method( _MD("get_bsp_tree"),&Bounds::get_bsp_tree );
ADD_PROPERTY( PropertyInfo( Variant::ARRAY, "bsp_tree" ), _SCS("set_bsp_tree"), _SCS("get_bsp_tree"));
diff --git a/scene/resources/bounds.h b/scene/resources/bounds.h
index aa7d248a05..bd5d996a36 100644
--- a/scene/resources/bounds.h
+++ b/scene/resources/bounds.h
@@ -34,7 +34,7 @@
class Bounds : public Resource {
- OBJ_TYPE(Bounds,Resource);
+ GDCLASS(Bounds,Resource);
BSP_Tree bsp_tree;
protected:
diff --git a/scene/resources/box_shape.cpp b/scene/resources/box_shape.cpp
index 3271022268..fa5b35ca41 100644
--- a/scene/resources/box_shape.cpp
+++ b/scene/resources/box_shape.cpp
@@ -70,8 +70,8 @@ Vector3 BoxShape::get_extents() const {
void BoxShape::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_extents","extents"),&BoxShape::set_extents);
- ObjectTypeDB::bind_method(_MD("get_extents"),&BoxShape::get_extents);
+ ClassDB::bind_method(_MD("set_extents","extents"),&BoxShape::set_extents);
+ ClassDB::bind_method(_MD("get_extents"),&BoxShape::get_extents);
ADD_PROPERTY( PropertyInfo(Variant::VECTOR3,"extents"), _SCS("set_extents"), _SCS("get_extents") );
diff --git a/scene/resources/box_shape.h b/scene/resources/box_shape.h
index 34918a9780..c17dd22015 100644
--- a/scene/resources/box_shape.h
+++ b/scene/resources/box_shape.h
@@ -33,7 +33,7 @@
class BoxShape : public Shape {
- OBJ_TYPE(BoxShape,Shape);
+ GDCLASS(BoxShape,Shape);
Vector3 extents;
protected:
diff --git a/scene/resources/canvas.h b/scene/resources/canvas.h
index 9ca840978c..960136ac14 100644
--- a/scene/resources/canvas.h
+++ b/scene/resources/canvas.h
@@ -34,7 +34,7 @@
class Canvas : public Resource {
- OBJ_TYPE(Canvas,Resource);
+ GDCLASS(Canvas,Resource);
RID canvas;
diff --git a/scene/resources/capsule_shape.cpp b/scene/resources/capsule_shape.cpp
index 5ed49c5b90..db83a20f38 100644
--- a/scene/resources/capsule_shape.cpp
+++ b/scene/resources/capsule_shape.cpp
@@ -107,10 +107,10 @@ float CapsuleShape::get_height() const {
void CapsuleShape::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_radius","radius"),&CapsuleShape::set_radius);
- ObjectTypeDB::bind_method(_MD("get_radius"),&CapsuleShape::get_radius);
- ObjectTypeDB::bind_method(_MD("set_height","height"),&CapsuleShape::set_height);
- ObjectTypeDB::bind_method(_MD("get_height"),&CapsuleShape::get_height);
+ ClassDB::bind_method(_MD("set_radius","radius"),&CapsuleShape::set_radius);
+ ClassDB::bind_method(_MD("get_radius"),&CapsuleShape::get_radius);
+ ClassDB::bind_method(_MD("set_height","height"),&CapsuleShape::set_height);
+ ClassDB::bind_method(_MD("get_height"),&CapsuleShape::get_height);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"radius",PROPERTY_HINT_RANGE,"0.01,4096,0.01"), _SCS("set_radius"),_SCS("get_radius") );
ADD_PROPERTY( PropertyInfo(Variant::REAL,"height",PROPERTY_HINT_RANGE,"0.01,4096,0.01"), _SCS("set_height"),_SCS("get_height") );
diff --git a/scene/resources/capsule_shape.h b/scene/resources/capsule_shape.h
index 8425d724fd..e788d9cfc5 100644
--- a/scene/resources/capsule_shape.h
+++ b/scene/resources/capsule_shape.h
@@ -33,7 +33,7 @@
class CapsuleShape : public Shape {
- OBJ_TYPE(CapsuleShape,Shape);
+ GDCLASS(CapsuleShape,Shape);
float radius;
float height;
diff --git a/scene/resources/capsule_shape_2d.cpp b/scene/resources/capsule_shape_2d.cpp
index 805666e7aa..27dcff0ce0 100644
--- a/scene/resources/capsule_shape_2d.cpp
+++ b/scene/resources/capsule_shape_2d.cpp
@@ -89,11 +89,11 @@ Rect2 CapsuleShape2D::get_rect() const {
void CapsuleShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_radius","radius"),&CapsuleShape2D::set_radius);
- ObjectTypeDB::bind_method(_MD("get_radius"),&CapsuleShape2D::get_radius);
+ ClassDB::bind_method(_MD("set_radius","radius"),&CapsuleShape2D::set_radius);
+ ClassDB::bind_method(_MD("get_radius"),&CapsuleShape2D::get_radius);
- ObjectTypeDB::bind_method(_MD("set_height","height"),&CapsuleShape2D::set_height);
- ObjectTypeDB::bind_method(_MD("get_height"),&CapsuleShape2D::get_height);
+ ClassDB::bind_method(_MD("set_height","height"),&CapsuleShape2D::set_height);
+ ClassDB::bind_method(_MD("get_height"),&CapsuleShape2D::get_height);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"radius"),_SCS("set_radius"),_SCS("get_radius") );
diff --git a/scene/resources/capsule_shape_2d.h b/scene/resources/capsule_shape_2d.h
index b17d3cec70..ef06072e14 100644
--- a/scene/resources/capsule_shape_2d.h
+++ b/scene/resources/capsule_shape_2d.h
@@ -32,7 +32,7 @@
#include "scene/resources/shape_2d.h"
class CapsuleShape2D : public Shape2D {
- OBJ_TYPE( CapsuleShape2D, Shape2D );
+ GDCLASS( CapsuleShape2D, Shape2D );
real_t height;
real_t radius;
diff --git a/scene/resources/circle_shape_2d.cpp b/scene/resources/circle_shape_2d.cpp
index 3aec7300d3..a82f3f5e2d 100644
--- a/scene/resources/circle_shape_2d.cpp
+++ b/scene/resources/circle_shape_2d.cpp
@@ -51,8 +51,8 @@ real_t CircleShape2D::get_radius() const {
void CircleShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_radius","radius"),&CircleShape2D::set_radius);
- ObjectTypeDB::bind_method(_MD("get_radius"),&CircleShape2D::get_radius);
+ ClassDB::bind_method(_MD("set_radius","radius"),&CircleShape2D::set_radius);
+ ClassDB::bind_method(_MD("get_radius"),&CircleShape2D::get_radius);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"radius",PROPERTY_HINT_RANGE,"0.01,16384,0.5"),_SCS("set_radius"),_SCS("get_radius") );
diff --git a/scene/resources/circle_shape_2d.h b/scene/resources/circle_shape_2d.h
index 9c728a22a4..ec11b55169 100644
--- a/scene/resources/circle_shape_2d.h
+++ b/scene/resources/circle_shape_2d.h
@@ -32,7 +32,7 @@
#include "scene/resources/shape_2d.h"
class CircleShape2D : public Shape2D {
- OBJ_TYPE( CircleShape2D, Shape2D );
+ GDCLASS( CircleShape2D, Shape2D );
real_t radius;
void _update_shape();
diff --git a/scene/resources/color_ramp.cpp b/scene/resources/color_ramp.cpp
index cdef4346ba..1144ea41f1 100644
--- a/scene/resources/color_ramp.cpp
+++ b/scene/resources/color_ramp.cpp
@@ -54,24 +54,24 @@ void ColorRamp::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("add_point","offset","color"),&ColorRamp::add_point);
- ObjectTypeDB::bind_method(_MD("remove_point","offset","color"),&ColorRamp::remove_point);
+ ClassDB::bind_method(_MD("add_point","offset","color"),&ColorRamp::add_point);
+ ClassDB::bind_method(_MD("remove_point","offset","color"),&ColorRamp::remove_point);
- ObjectTypeDB::bind_method(_MD("set_offset","point","offset"),&ColorRamp::set_offset);
- ObjectTypeDB::bind_method(_MD("get_offset","point"),&ColorRamp::get_offset);
+ ClassDB::bind_method(_MD("set_offset","point","offset"),&ColorRamp::set_offset);
+ ClassDB::bind_method(_MD("get_offset","point"),&ColorRamp::get_offset);
- ObjectTypeDB::bind_method(_MD("set_color","point","color"),&ColorRamp::set_color);
- ObjectTypeDB::bind_method(_MD("get_color","point"),&ColorRamp::get_color);
+ ClassDB::bind_method(_MD("set_color","point","color"),&ColorRamp::set_color);
+ ClassDB::bind_method(_MD("get_color","point"),&ColorRamp::get_color);
- ObjectTypeDB::bind_method(_MD("interpolate","offset"),&ColorRamp::get_color_at_offset);
+ ClassDB::bind_method(_MD("interpolate","offset"),&ColorRamp::get_color_at_offset);
- ObjectTypeDB::bind_method(_MD("get_point_count"),&ColorRamp::get_points_count);
+ ClassDB::bind_method(_MD("get_point_count"),&ColorRamp::get_points_count);
- ObjectTypeDB::bind_method(_MD(COLOR_RAMP_SET_OFFSETS,"offsets"),&ColorRamp::set_offsets);
- ObjectTypeDB::bind_method(_MD(COLOR_RAMP_GET_OFFSETS),&ColorRamp::get_offsets);
+ ClassDB::bind_method(_MD(COLOR_RAMP_SET_OFFSETS,"offsets"),&ColorRamp::set_offsets);
+ ClassDB::bind_method(_MD(COLOR_RAMP_GET_OFFSETS),&ColorRamp::get_offsets);
- ObjectTypeDB::bind_method(_MD(COLOR_RAMP_SET_COLORS,"colors"),&ColorRamp::set_colors);
- ObjectTypeDB::bind_method(_MD(COLOR_RAMP_GET_COLORS),&ColorRamp::get_colors);
+ ClassDB::bind_method(_MD(COLOR_RAMP_SET_COLORS,"colors"),&ColorRamp::set_colors);
+ ClassDB::bind_method(_MD(COLOR_RAMP_GET_COLORS),&ColorRamp::get_colors);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"offsets"),_SCS(COLOR_RAMP_SET_OFFSETS),_SCS(COLOR_RAMP_GET_OFFSETS) );
ADD_PROPERTY( PropertyInfo(Variant::REAL,"colors"),_SCS(COLOR_RAMP_SET_COLORS),_SCS(COLOR_RAMP_GET_COLORS) );
diff --git a/scene/resources/color_ramp.h b/scene/resources/color_ramp.h
index 7908956efd..b6ca56dbf5 100644
--- a/scene/resources/color_ramp.h
+++ b/scene/resources/color_ramp.h
@@ -32,7 +32,7 @@
#include "resource.h"
class ColorRamp: public Resource {
- OBJ_TYPE( ColorRamp, Resource );
+ GDCLASS( ColorRamp, Resource );
OBJ_SAVE_TYPE( ColorRamp );
public:
diff --git a/scene/resources/concave_polygon_shape.cpp b/scene/resources/concave_polygon_shape.cpp
index 0589a0928f..fc1a3a9961 100644
--- a/scene/resources/concave_polygon_shape.cpp
+++ b/scene/resources/concave_polygon_shape.cpp
@@ -110,8 +110,8 @@ DVector<Vector3> ConcavePolygonShape::get_faces() const {
void ConcavePolygonShape::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_faces","faces"),&ConcavePolygonShape::set_faces);
- ObjectTypeDB::bind_method(_MD("get_faces"),&ConcavePolygonShape::get_faces);
+ ClassDB::bind_method(_MD("set_faces","faces"),&ConcavePolygonShape::set_faces);
+ ClassDB::bind_method(_MD("get_faces"),&ConcavePolygonShape::get_faces);
}
ConcavePolygonShape::ConcavePolygonShape() : Shape( PhysicsServer::get_singleton()->shape_create(PhysicsServer::SHAPE_CONCAVE_POLYGON)) {
diff --git a/scene/resources/concave_polygon_shape.h b/scene/resources/concave_polygon_shape.h
index b4c07f189c..08d95da0ac 100644
--- a/scene/resources/concave_polygon_shape.h
+++ b/scene/resources/concave_polygon_shape.h
@@ -33,7 +33,7 @@
class ConcavePolygonShape : public Shape {
- OBJ_TYPE(ConcavePolygonShape,Shape);
+ GDCLASS(ConcavePolygonShape,Shape);
struct DrawEdge {
diff --git a/scene/resources/concave_polygon_shape_2d.cpp b/scene/resources/concave_polygon_shape_2d.cpp
index 4b16e924c0..4be95cb26d 100644
--- a/scene/resources/concave_polygon_shape_2d.cpp
+++ b/scene/resources/concave_polygon_shape_2d.cpp
@@ -82,8 +82,8 @@ Rect2 ConcavePolygonShape2D::get_rect() const {
void ConcavePolygonShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_segments","segments"),&ConcavePolygonShape2D::set_segments);
- ObjectTypeDB::bind_method(_MD("get_segments"),&ConcavePolygonShape2D::get_segments);
+ ClassDB::bind_method(_MD("set_segments","segments"),&ConcavePolygonShape2D::set_segments);
+ ClassDB::bind_method(_MD("get_segments"),&ConcavePolygonShape2D::get_segments);
ADD_PROPERTY( PropertyInfo(Variant::VECTOR2_ARRAY,"segments"),_SCS("set_segments"),_SCS("get_segments") );
diff --git a/scene/resources/concave_polygon_shape_2d.h b/scene/resources/concave_polygon_shape_2d.h
index cda36a7990..36c67254f3 100644
--- a/scene/resources/concave_polygon_shape_2d.h
+++ b/scene/resources/concave_polygon_shape_2d.h
@@ -32,7 +32,7 @@
#include "scene/resources/shape_2d.h"
class ConcavePolygonShape2D : public Shape2D {
- OBJ_TYPE( ConcavePolygonShape2D, Shape2D );
+ GDCLASS( ConcavePolygonShape2D, Shape2D );
protected:
static void _bind_methods();
diff --git a/scene/resources/convex_polygon_shape.cpp b/scene/resources/convex_polygon_shape.cpp
index ed2557ac7e..21e93e4b5c 100644
--- a/scene/resources/convex_polygon_shape.cpp
+++ b/scene/resources/convex_polygon_shape.cpp
@@ -79,8 +79,8 @@ DVector<Vector3> ConvexPolygonShape::get_points() const {
void ConvexPolygonShape::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_points","points"),&ConvexPolygonShape::set_points);
- ObjectTypeDB::bind_method(_MD("get_points"),&ConvexPolygonShape::get_points);
+ ClassDB::bind_method(_MD("set_points","points"),&ConvexPolygonShape::set_points);
+ ClassDB::bind_method(_MD("get_points"),&ConvexPolygonShape::get_points);
ADD_PROPERTY( PropertyInfo(Variant::ARRAY,"points"), _SCS("set_points"), _SCS("get_points") );
diff --git a/scene/resources/convex_polygon_shape.h b/scene/resources/convex_polygon_shape.h
index 33c60768a9..296a0ce4ca 100644
--- a/scene/resources/convex_polygon_shape.h
+++ b/scene/resources/convex_polygon_shape.h
@@ -33,7 +33,7 @@
class ConvexPolygonShape : public Shape {
- OBJ_TYPE(ConvexPolygonShape,Shape);
+ GDCLASS(ConvexPolygonShape,Shape);
DVector<Vector3> points;
protected:
diff --git a/scene/resources/convex_polygon_shape_2d.cpp b/scene/resources/convex_polygon_shape_2d.cpp
index 4550ea3311..cc3b0c063d 100644
--- a/scene/resources/convex_polygon_shape_2d.cpp
+++ b/scene/resources/convex_polygon_shape_2d.cpp
@@ -61,9 +61,9 @@ Vector<Vector2> ConvexPolygonShape2D::get_points() const {
void ConvexPolygonShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_point_cloud","point_cloud"),&ConvexPolygonShape2D::set_point_cloud);
- ObjectTypeDB::bind_method(_MD("set_points","points"),&ConvexPolygonShape2D::set_points);
- ObjectTypeDB::bind_method(_MD("get_points"),&ConvexPolygonShape2D::get_points);
+ ClassDB::bind_method(_MD("set_point_cloud","point_cloud"),&ConvexPolygonShape2D::set_point_cloud);
+ ClassDB::bind_method(_MD("set_points","points"),&ConvexPolygonShape2D::set_points);
+ ClassDB::bind_method(_MD("get_points"),&ConvexPolygonShape2D::get_points);
diff --git a/scene/resources/convex_polygon_shape_2d.h b/scene/resources/convex_polygon_shape_2d.h
index 886f4eab70..8a4ad0e6d8 100644
--- a/scene/resources/convex_polygon_shape_2d.h
+++ b/scene/resources/convex_polygon_shape_2d.h
@@ -32,7 +32,7 @@
#include "scene/resources/shape_2d.h"
class ConvexPolygonShape2D : public Shape2D {
- OBJ_TYPE( ConvexPolygonShape2D, Shape2D );
+ GDCLASS( ConvexPolygonShape2D, Shape2D );
Vector<Vector2> points;
void _update_shape();
diff --git a/scene/resources/curve.cpp b/scene/resources/curve.cpp
index 537f93c0f5..fd0e9be304 100644
--- a/scene/resources/curve.cpp
+++ b/scene/resources/curve.cpp
@@ -349,26 +349,26 @@ Vector2Array Curve2D::get_points_pos() const {
void Curve2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_point_count"),&Curve2D::get_point_count);
- ObjectTypeDB::bind_method(_MD("add_point","pos","in","out"),&Curve2D::add_point,DEFVAL(Vector2()),DEFVAL(Vector2()));
- ObjectTypeDB::bind_method(_MD("set_point_pos","idx","pos"),&Curve2D::set_point_pos);
- ObjectTypeDB::bind_method(_MD("get_point_pos","idx"),&Curve2D::get_point_pos);
- ObjectTypeDB::bind_method(_MD("set_point_in","idx","pos"),&Curve2D::set_point_in);
- ObjectTypeDB::bind_method(_MD("get_point_in","idx"),&Curve2D::get_point_in);
- ObjectTypeDB::bind_method(_MD("set_point_out","idx","pos"),&Curve2D::set_point_out);
- ObjectTypeDB::bind_method(_MD("get_point_out","idx"),&Curve2D::get_point_out);
- ObjectTypeDB::bind_method(_MD("remove_point","idx"),&Curve2D::remove_point);
- ObjectTypeDB::bind_method(_MD("interpolate","idx","t"),&Curve2D::interpolate);
- ObjectTypeDB::bind_method(_MD("bake","subdivs"),&Curve2D::bake,DEFVAL(10));
-
-
- ObjectTypeDB::bind_method(_MD("set_points_in"),&Curve2D::set_points_in);
- ObjectTypeDB::bind_method(_MD("set_points_out"),&Curve2D::set_points_out);
- ObjectTypeDB::bind_method(_MD("set_points_pos"),&Curve2D::set_points_pos);
-
- ObjectTypeDB::bind_method(_MD("get_points_in"),&Curve2D::get_points_in);
- ObjectTypeDB::bind_method(_MD("get_points_out"),&Curve2D::get_points_out);
- ObjectTypeDB::bind_method(_MD("get_points_pos"),&Curve2D::get_points_pos);
+ ClassDB::bind_method(_MD("get_point_count"),&Curve2D::get_point_count);
+ ClassDB::bind_method(_MD("add_point","pos","in","out"),&Curve2D::add_point,DEFVAL(Vector2()),DEFVAL(Vector2()));
+ ClassDB::bind_method(_MD("set_point_pos","idx","pos"),&Curve2D::set_point_pos);
+ ClassDB::bind_method(_MD("get_point_pos","idx"),&Curve2D::get_point_pos);
+ ClassDB::bind_method(_MD("set_point_in","idx","pos"),&Curve2D::set_point_in);
+ ClassDB::bind_method(_MD("get_point_in","idx"),&Curve2D::get_point_in);
+ ClassDB::bind_method(_MD("set_point_out","idx","pos"),&Curve2D::set_point_out);
+ ClassDB::bind_method(_MD("get_point_out","idx"),&Curve2D::get_point_out);
+ ClassDB::bind_method(_MD("remove_point","idx"),&Curve2D::remove_point);
+ ClassDB::bind_method(_MD("interpolate","idx","t"),&Curve2D::interpolate);
+ ClassDB::bind_method(_MD("bake","subdivs"),&Curve2D::bake,DEFVAL(10));
+
+
+ ClassDB::bind_method(_MD("set_points_in"),&Curve2D::set_points_in);
+ ClassDB::bind_method(_MD("set_points_out"),&Curve2D::set_points_out);
+ ClassDB::bind_method(_MD("set_points_pos"),&Curve2D::set_points_pos);
+
+ ClassDB::bind_method(_MD("get_points_in"),&Curve2D::get_points_in);
+ ClassDB::bind_method(_MD("get_points_out"),&Curve2D::get_points_out);
+ ClassDB::bind_method(_MD("get_points_pos"),&Curve2D::get_points_pos);
ADD_PROPERTY( PropertyInfo( Variant::VECTOR2_ARRAY, "points_in"), _SCS("set_points_in"),_SCS("get_points_in"));
ADD_PROPERTY( PropertyInfo( Variant::VECTOR2_ARRAY, "points_out"), _SCS("set_points_out"),_SCS("get_points_out"));
@@ -789,29 +789,29 @@ Vector2Array Curve2D::tesselate(int p_max_stages,float p_tolerance) const {
void Curve2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_point_count"),&Curve2D::get_point_count);
- ObjectTypeDB::bind_method(_MD("add_point","pos","in","out","atpos"),&Curve2D::add_point,DEFVAL(Vector2()),DEFVAL(Vector2()),DEFVAL(-1));
- ObjectTypeDB::bind_method(_MD("set_point_pos","idx","pos"),&Curve2D::set_point_pos);
- ObjectTypeDB::bind_method(_MD("get_point_pos","idx"),&Curve2D::get_point_pos);
- ObjectTypeDB::bind_method(_MD("set_point_in","idx","pos"),&Curve2D::set_point_in);
- ObjectTypeDB::bind_method(_MD("get_point_in","idx"),&Curve2D::get_point_in);
- ObjectTypeDB::bind_method(_MD("set_point_out","idx","pos"),&Curve2D::set_point_out);
- ObjectTypeDB::bind_method(_MD("get_point_out","idx"),&Curve2D::get_point_out);
- ObjectTypeDB::bind_method(_MD("remove_point","idx"),&Curve2D::remove_point);
- ObjectTypeDB::bind_method(_MD("clear_points"),&Curve2D::clear_points);
- ObjectTypeDB::bind_method(_MD("interpolate","idx","t"),&Curve2D::interpolate);
- ObjectTypeDB::bind_method(_MD("interpolatef","fofs"),&Curve2D::interpolatef);
- //ObjectTypeDB::bind_method(_MD("bake","subdivs"),&Curve2D::bake,DEFVAL(10));
- ObjectTypeDB::bind_method(_MD("set_bake_interval","distance"),&Curve2D::set_bake_interval);
- ObjectTypeDB::bind_method(_MD("get_bake_interval"),&Curve2D::get_bake_interval);
-
- ObjectTypeDB::bind_method(_MD("get_baked_length"),&Curve2D::get_baked_length);
- ObjectTypeDB::bind_method(_MD("interpolate_baked","offset","cubic"),&Curve2D::interpolate_baked,DEFVAL(false));
- ObjectTypeDB::bind_method(_MD("get_baked_points"),&Curve2D::get_baked_points);
- ObjectTypeDB::bind_method(_MD("tesselate","max_stages","tolerance_degrees"),&Curve2D::tesselate,DEFVAL(5),DEFVAL(4));
-
- ObjectTypeDB::bind_method(_MD("_get_data"),&Curve2D::_get_data);
- ObjectTypeDB::bind_method(_MD("_set_data"),&Curve2D::_set_data);
+ ClassDB::bind_method(_MD("get_point_count"),&Curve2D::get_point_count);
+ ClassDB::bind_method(_MD("add_point","pos","in","out","atpos"),&Curve2D::add_point,DEFVAL(Vector2()),DEFVAL(Vector2()),DEFVAL(-1));
+ ClassDB::bind_method(_MD("set_point_pos","idx","pos"),&Curve2D::set_point_pos);
+ ClassDB::bind_method(_MD("get_point_pos","idx"),&Curve2D::get_point_pos);
+ ClassDB::bind_method(_MD("set_point_in","idx","pos"),&Curve2D::set_point_in);
+ ClassDB::bind_method(_MD("get_point_in","idx"),&Curve2D::get_point_in);
+ ClassDB::bind_method(_MD("set_point_out","idx","pos"),&Curve2D::set_point_out);
+ ClassDB::bind_method(_MD("get_point_out","idx"),&Curve2D::get_point_out);
+ ClassDB::bind_method(_MD("remove_point","idx"),&Curve2D::remove_point);
+ ClassDB::bind_method(_MD("clear_points"),&Curve2D::clear_points);
+ ClassDB::bind_method(_MD("interpolate","idx","t"),&Curve2D::interpolate);
+ ClassDB::bind_method(_MD("interpolatef","fofs"),&Curve2D::interpolatef);
+ //ClassDB::bind_method(_MD("bake","subdivs"),&Curve2D::bake,DEFVAL(10));
+ ClassDB::bind_method(_MD("set_bake_interval","distance"),&Curve2D::set_bake_interval);
+ ClassDB::bind_method(_MD("get_bake_interval"),&Curve2D::get_bake_interval);
+
+ ClassDB::bind_method(_MD("get_baked_length"),&Curve2D::get_baked_length);
+ ClassDB::bind_method(_MD("interpolate_baked","offset","cubic"),&Curve2D::interpolate_baked,DEFVAL(false));
+ ClassDB::bind_method(_MD("get_baked_points"),&Curve2D::get_baked_points);
+ ClassDB::bind_method(_MD("tesselate","max_stages","tolerance_degrees"),&Curve2D::tesselate,DEFVAL(5),DEFVAL(4));
+
+ ClassDB::bind_method(_MD("_get_data"),&Curve2D::_get_data);
+ ClassDB::bind_method(_MD("_set_data"),&Curve2D::_set_data);
ADD_PROPERTY( PropertyInfo( Variant::REAL, "bake_interval",PROPERTY_HINT_RANGE,"0.01,512,0.01"), _SCS("set_bake_interval"),_SCS("get_bake_interval"));
@@ -1329,32 +1329,32 @@ Vector3Array Curve3D::tesselate(int p_max_stages,float p_tolerance) const {
void Curve3D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_point_count"),&Curve3D::get_point_count);
- ObjectTypeDB::bind_method(_MD("add_point","pos","in","out","atpos"),&Curve3D::add_point,DEFVAL(Vector3()),DEFVAL(Vector3()),DEFVAL(-1));
- ObjectTypeDB::bind_method(_MD("set_point_pos","idx","pos"),&Curve3D::set_point_pos);
- ObjectTypeDB::bind_method(_MD("get_point_pos","idx"),&Curve3D::get_point_pos);
- ObjectTypeDB::bind_method(_MD("set_point_tilt","idx","tilt"),&Curve3D::set_point_tilt);
- ObjectTypeDB::bind_method(_MD("get_point_tilt","idx"),&Curve3D::get_point_tilt);
- ObjectTypeDB::bind_method(_MD("set_point_in","idx","pos"),&Curve3D::set_point_in);
- ObjectTypeDB::bind_method(_MD("get_point_in","idx"),&Curve3D::get_point_in);
- ObjectTypeDB::bind_method(_MD("set_point_out","idx","pos"),&Curve3D::set_point_out);
- ObjectTypeDB::bind_method(_MD("get_point_out","idx"),&Curve3D::get_point_out);
- ObjectTypeDB::bind_method(_MD("remove_point","idx"),&Curve3D::remove_point);
- ObjectTypeDB::bind_method(_MD("clear_points"),&Curve3D::clear_points);
- ObjectTypeDB::bind_method(_MD("interpolate","idx","t"),&Curve3D::interpolate);
- ObjectTypeDB::bind_method(_MD("interpolatef","fofs"),&Curve3D::interpolatef);
- //ObjectTypeDB::bind_method(_MD("bake","subdivs"),&Curve3D::bake,DEFVAL(10));
- ObjectTypeDB::bind_method(_MD("set_bake_interval","distance"),&Curve3D::set_bake_interval);
- ObjectTypeDB::bind_method(_MD("get_bake_interval"),&Curve3D::get_bake_interval);
-
- ObjectTypeDB::bind_method(_MD("get_baked_length"),&Curve3D::get_baked_length);
- ObjectTypeDB::bind_method(_MD("interpolate_baked","offset","cubic"),&Curve3D::interpolate_baked,DEFVAL(false));
- ObjectTypeDB::bind_method(_MD("get_baked_points"),&Curve3D::get_baked_points);
- ObjectTypeDB::bind_method(_MD("get_baked_tilts"),&Curve3D::get_baked_tilts);
- ObjectTypeDB::bind_method(_MD("tesselate","max_stages","tolerance_degrees"),&Curve3D::tesselate,DEFVAL(5),DEFVAL(4));
-
- ObjectTypeDB::bind_method(_MD("_get_data"),&Curve3D::_get_data);
- ObjectTypeDB::bind_method(_MD("_set_data"),&Curve3D::_set_data);
+ ClassDB::bind_method(_MD("get_point_count"),&Curve3D::get_point_count);
+ ClassDB::bind_method(_MD("add_point","pos","in","out","atpos"),&Curve3D::add_point,DEFVAL(Vector3()),DEFVAL(Vector3()),DEFVAL(-1));
+ ClassDB::bind_method(_MD("set_point_pos","idx","pos"),&Curve3D::set_point_pos);
+ ClassDB::bind_method(_MD("get_point_pos","idx"),&Curve3D::get_point_pos);
+ ClassDB::bind_method(_MD("set_point_tilt","idx","tilt"),&Curve3D::set_point_tilt);
+ ClassDB::bind_method(_MD("get_point_tilt","idx"),&Curve3D::get_point_tilt);
+ ClassDB::bind_method(_MD("set_point_in","idx","pos"),&Curve3D::set_point_in);
+ ClassDB::bind_method(_MD("get_point_in","idx"),&Curve3D::get_point_in);
+ ClassDB::bind_method(_MD("set_point_out","idx","pos"),&Curve3D::set_point_out);
+ ClassDB::bind_method(_MD("get_point_out","idx"),&Curve3D::get_point_out);
+ ClassDB::bind_method(_MD("remove_point","idx"),&Curve3D::remove_point);
+ ClassDB::bind_method(_MD("clear_points"),&Curve3D::clear_points);
+ ClassDB::bind_method(_MD("interpolate","idx","t"),&Curve3D::interpolate);
+ ClassDB::bind_method(_MD("interpolatef","fofs"),&Curve3D::interpolatef);
+ //ClassDB::bind_method(_MD("bake","subdivs"),&Curve3D::bake,DEFVAL(10));
+ ClassDB::bind_method(_MD("set_bake_interval","distance"),&Curve3D::set_bake_interval);
+ ClassDB::bind_method(_MD("get_bake_interval"),&Curve3D::get_bake_interval);
+
+ ClassDB::bind_method(_MD("get_baked_length"),&Curve3D::get_baked_length);
+ ClassDB::bind_method(_MD("interpolate_baked","offset","cubic"),&Curve3D::interpolate_baked,DEFVAL(false));
+ ClassDB::bind_method(_MD("get_baked_points"),&Curve3D::get_baked_points);
+ ClassDB::bind_method(_MD("get_baked_tilts"),&Curve3D::get_baked_tilts);
+ ClassDB::bind_method(_MD("tesselate","max_stages","tolerance_degrees"),&Curve3D::tesselate,DEFVAL(5),DEFVAL(4));
+
+ ClassDB::bind_method(_MD("_get_data"),&Curve3D::_get_data);
+ ClassDB::bind_method(_MD("_set_data"),&Curve3D::_set_data);
ADD_PROPERTY( PropertyInfo( Variant::REAL, "bake_interval",PROPERTY_HINT_RANGE,"0.01,512,0.01"), _SCS("set_bake_interval"),_SCS("get_bake_interval"));
diff --git a/scene/resources/curve.h b/scene/resources/curve.h
index c842c03c03..289de50444 100644
--- a/scene/resources/curve.h
+++ b/scene/resources/curve.h
@@ -33,7 +33,7 @@
#if 0
class Curve2D : public Resource {
- OBJ_TYPE(Curve2D,Resource);
+ GDCLASS(Curve2D,Resource);
struct Point {
@@ -84,7 +84,7 @@ public:
class Curve2D : public Resource {
- OBJ_TYPE(Curve2D,Resource);
+ GDCLASS(Curve2D,Resource);
struct Point {
@@ -157,7 +157,7 @@ public:
class Curve3D : public Resource {
- OBJ_TYPE(Curve3D,Resource);
+ GDCLASS(Curve3D,Resource);
struct Point {
diff --git a/scene/resources/dynamic_font.cpp b/scene/resources/dynamic_font.cpp
index b661240fd3..e157ee46d0 100644
--- a/scene/resources/dynamic_font.cpp
+++ b/scene/resources/dynamic_font.cpp
@@ -84,8 +84,8 @@ void DynamicFontData::set_force_autohinter(bool p_force) {
}
void DynamicFontData::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_font_path","path"),&DynamicFontData::set_font_path);
- ObjectTypeDB::bind_method(_MD("get_font_path"),&DynamicFontData::get_font_path);
+ ClassDB::bind_method(_MD("set_font_path","path"),&DynamicFontData::set_font_path);
+ ClassDB::bind_method(_MD("get_font_path"),&DynamicFontData::get_font_path);
ADD_PROPERTY(PropertyInfo(Variant::STRING,"font_path",PROPERTY_HINT_FILE,"*.ttf,*.otf"),_SCS("set_font_path"),_SCS("get_font_path"));
}
@@ -879,24 +879,24 @@ void DynamicFont::_get_property_list( List<PropertyInfo> *p_list) const{
void DynamicFont::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_font_data","data:DynamicFontData"),&DynamicFont::set_font_data);
- ObjectTypeDB::bind_method(_MD("get_font_data:DynamicFontData"),&DynamicFont::get_font_data);
+ ClassDB::bind_method(_MD("set_font_data","data:DynamicFontData"),&DynamicFont::set_font_data);
+ ClassDB::bind_method(_MD("get_font_data:DynamicFontData"),&DynamicFont::get_font_data);
- ObjectTypeDB::bind_method(_MD("set_size","data"),&DynamicFont::set_size);
- ObjectTypeDB::bind_method(_MD("get_size"),&DynamicFont::get_size);
+ ClassDB::bind_method(_MD("set_size","data"),&DynamicFont::set_size);
+ ClassDB::bind_method(_MD("get_size"),&DynamicFont::get_size);
- ObjectTypeDB::bind_method(_MD("set_use_mipmaps","enable"),&DynamicFont::set_use_mipmaps);
- ObjectTypeDB::bind_method(_MD("get_use_mipmaps"),&DynamicFont::get_use_mipmaps);
- ObjectTypeDB::bind_method(_MD("set_use_filter","enable"),&DynamicFont::set_use_filter);
- ObjectTypeDB::bind_method(_MD("get_use_filter"),&DynamicFont::get_use_filter);
- ObjectTypeDB::bind_method(_MD("set_spacing","type","value"),&DynamicFont::set_spacing);
- ObjectTypeDB::bind_method(_MD("get_spacing","type"),&DynamicFont::get_spacing);
+ ClassDB::bind_method(_MD("set_use_mipmaps","enable"),&DynamicFont::set_use_mipmaps);
+ ClassDB::bind_method(_MD("get_use_mipmaps"),&DynamicFont::get_use_mipmaps);
+ ClassDB::bind_method(_MD("set_use_filter","enable"),&DynamicFont::set_use_filter);
+ ClassDB::bind_method(_MD("get_use_filter"),&DynamicFont::get_use_filter);
+ ClassDB::bind_method(_MD("set_spacing","type","value"),&DynamicFont::set_spacing);
+ ClassDB::bind_method(_MD("get_spacing","type"),&DynamicFont::get_spacing);
- ObjectTypeDB::bind_method(_MD("add_fallback","data:DynamicFontData"),&DynamicFont::add_fallback);
- ObjectTypeDB::bind_method(_MD("set_fallback","idx","data:DynamicFontData"),&DynamicFont::set_fallback);
- ObjectTypeDB::bind_method(_MD("get_fallback:DynamicFontData","idx"),&DynamicFont::get_fallback);
- ObjectTypeDB::bind_method(_MD("remove_fallback","idx"),&DynamicFont::remove_fallback);
- ObjectTypeDB::bind_method(_MD("get_fallback_count"),&DynamicFont::get_fallback_count);
+ ClassDB::bind_method(_MD("add_fallback","data:DynamicFontData"),&DynamicFont::add_fallback);
+ ClassDB::bind_method(_MD("set_fallback","idx","data:DynamicFontData"),&DynamicFont::set_fallback);
+ ClassDB::bind_method(_MD("get_fallback:DynamicFontData","idx"),&DynamicFont::get_fallback);
+ ClassDB::bind_method(_MD("remove_fallback","idx"),&DynamicFont::remove_fallback);
+ ClassDB::bind_method(_MD("get_fallback_count"),&DynamicFont::get_fallback_count);
ADD_PROPERTY(PropertyInfo(Variant::INT,"font/size"),_SCS("set_size"),_SCS("get_size"));
diff --git a/scene/resources/dynamic_font.h b/scene/resources/dynamic_font.h
index 131c3d3e8f..133d48bdea 100644
--- a/scene/resources/dynamic_font.h
+++ b/scene/resources/dynamic_font.h
@@ -43,7 +43,7 @@ class DynamicFont;
class DynamicFontData : public Resource {
- OBJ_TYPE(DynamicFontData,Resource);
+ GDCLASS(DynamicFontData,Resource);
public:
@@ -88,7 +88,7 @@ public:
class DynamicFontAtSize : public Reference {
- OBJ_TYPE(DynamicFontAtSize,Reference)
+ GDCLASS(DynamicFontAtSize,Reference)
_THREAD_SAFE_CLASS_
@@ -168,7 +168,7 @@ public:
class DynamicFont : public Font {
- OBJ_TYPE( DynamicFont, Font );
+ GDCLASS( DynamicFont, Font );
public:
diff --git a/scene/resources/dynamic_font_stb.cpp b/scene/resources/dynamic_font_stb.cpp
index d1efc0f705..c931b4d6c8 100644
--- a/scene/resources/dynamic_font_stb.cpp
+++ b/scene/resources/dynamic_font_stb.cpp
@@ -378,11 +378,11 @@ DynamicFontAtSize::~DynamicFontAtSize(){
void DynamicFont::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_font_data","data:DynamicFontData"),&DynamicFont::set_font_data);
- ObjectTypeDB::bind_method(_MD("get_font_data:DynamicFontData"),&DynamicFont::get_font_data);
+ ClassDB::bind_method(_MD("set_font_data","data:DynamicFontData"),&DynamicFont::set_font_data);
+ ClassDB::bind_method(_MD("get_font_data:DynamicFontData"),&DynamicFont::get_font_data);
- ObjectTypeDB::bind_method(_MD("set_size","data"),&DynamicFont::set_size);
- ObjectTypeDB::bind_method(_MD("get_size"),&DynamicFont::get_size);
+ ClassDB::bind_method(_MD("set_size","data"),&DynamicFont::set_size);
+ ClassDB::bind_method(_MD("get_size"),&DynamicFont::get_size);
ADD_PROPERTY(PropertyInfo(Variant::INT,"font/size"),_SCS("set_size"),_SCS("get_size"));
ADD_PROPERTY(PropertyInfo(Variant::OBJECT,"font/font",PROPERTY_HINT_RESOURCE_TYPE,"DynamicFontData"),_SCS("set_font_data"),_SCS("get_font_data"));
diff --git a/scene/resources/dynamic_font_stb.h b/scene/resources/dynamic_font_stb.h
index 136edff2fc..ad7ca0009d 100644
--- a/scene/resources/dynamic_font_stb.h
+++ b/scene/resources/dynamic_font_stb.h
@@ -14,7 +14,7 @@ class DynamicFont;
class DynamicFontData : public Resource {
- OBJ_TYPE(DynamicFontData,Resource);
+ GDCLASS(DynamicFontData,Resource);
bool valid;
@@ -64,7 +64,7 @@ public:
class DynamicFontAtSize : public Reference {
- OBJ_TYPE(DynamicFontAtSize,Reference);
+ GDCLASS(DynamicFontAtSize,Reference);
int rect_margin;
@@ -124,7 +124,7 @@ public:
class DynamicFont : public Font {
- OBJ_TYPE( DynamicFont, Font );
+ GDCLASS( DynamicFont, Font );
Ref<DynamicFontData> data;
Ref<DynamicFontAtSize> data_at_size;
diff --git a/scene/resources/environment.cpp b/scene/resources/environment.cpp
index 6e388e70ec..55c9bbeae4 100644
--- a/scene/resources/environment.cpp
+++ b/scene/resources/environment.cpp
@@ -701,26 +701,26 @@ Environment::DOFBlurQuality Environment::get_dof_blur_near_quality() const {
void Environment::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_background","mode"),&Environment::set_background);
- ObjectTypeDB::bind_method(_MD("set_skybox","skybox:CubeMap"),&Environment::set_skybox);
- ObjectTypeDB::bind_method(_MD("set_skybox_scale","scale"),&Environment::set_skybox_scale);
- ObjectTypeDB::bind_method(_MD("set_bg_color","color"),&Environment::set_bg_color);
- ObjectTypeDB::bind_method(_MD("set_bg_energy","energy"),&Environment::set_bg_energy);
- ObjectTypeDB::bind_method(_MD("set_canvas_max_layer","layer"),&Environment::set_canvas_max_layer);
- ObjectTypeDB::bind_method(_MD("set_ambient_light_color","color"),&Environment::set_ambient_light_color);
- ObjectTypeDB::bind_method(_MD("set_ambient_light_energy","energy"),&Environment::set_ambient_light_energy);
- ObjectTypeDB::bind_method(_MD("set_ambient_light_skybox_contribution","energy"),&Environment::set_ambient_light_skybox_contribution);
-
-
- ObjectTypeDB::bind_method(_MD("get_background"),&Environment::get_background);
- ObjectTypeDB::bind_method(_MD("get_skybox:CubeMap"),&Environment::get_skybox);
- ObjectTypeDB::bind_method(_MD("get_skybox_scale"),&Environment::get_skybox_scale);
- ObjectTypeDB::bind_method(_MD("get_bg_color"),&Environment::get_bg_color);
- ObjectTypeDB::bind_method(_MD("get_bg_energy"),&Environment::get_bg_energy);
- ObjectTypeDB::bind_method(_MD("get_canvas_max_layer"),&Environment::get_canvas_max_layer);
- ObjectTypeDB::bind_method(_MD("get_ambient_light_color"),&Environment::get_ambient_light_color);
- ObjectTypeDB::bind_method(_MD("get_ambient_light_energy"),&Environment::get_ambient_light_energy);
- ObjectTypeDB::bind_method(_MD("get_ambient_light_skybox_contribution"),&Environment::get_ambient_light_skybox_contribution);
+ ClassDB::bind_method(_MD("set_background","mode"),&Environment::set_background);
+ ClassDB::bind_method(_MD("set_skybox","skybox:CubeMap"),&Environment::set_skybox);
+ ClassDB::bind_method(_MD("set_skybox_scale","scale"),&Environment::set_skybox_scale);
+ ClassDB::bind_method(_MD("set_bg_color","color"),&Environment::set_bg_color);
+ ClassDB::bind_method(_MD("set_bg_energy","energy"),&Environment::set_bg_energy);
+ ClassDB::bind_method(_MD("set_canvas_max_layer","layer"),&Environment::set_canvas_max_layer);
+ ClassDB::bind_method(_MD("set_ambient_light_color","color"),&Environment::set_ambient_light_color);
+ ClassDB::bind_method(_MD("set_ambient_light_energy","energy"),&Environment::set_ambient_light_energy);
+ ClassDB::bind_method(_MD("set_ambient_light_skybox_contribution","energy"),&Environment::set_ambient_light_skybox_contribution);
+
+
+ ClassDB::bind_method(_MD("get_background"),&Environment::get_background);
+ ClassDB::bind_method(_MD("get_skybox:CubeMap"),&Environment::get_skybox);
+ ClassDB::bind_method(_MD("get_skybox_scale"),&Environment::get_skybox_scale);
+ ClassDB::bind_method(_MD("get_bg_color"),&Environment::get_bg_color);
+ ClassDB::bind_method(_MD("get_bg_energy"),&Environment::get_bg_energy);
+ ClassDB::bind_method(_MD("get_canvas_max_layer"),&Environment::get_canvas_max_layer);
+ ClassDB::bind_method(_MD("get_ambient_light_color"),&Environment::get_ambient_light_color);
+ ClassDB::bind_method(_MD("get_ambient_light_energy"),&Environment::get_ambient_light_energy);
+ ClassDB::bind_method(_MD("get_ambient_light_skybox_contribution"),&Environment::get_ambient_light_skybox_contribution);
ADD_PROPERTY(PropertyInfo(Variant::INT,"background/mode",PROPERTY_HINT_ENUM,"Clear Color,Custom Color,Skybox,Canvas,Keep"),_SCS("set_background"),_SCS("get_background") );
@@ -734,26 +734,26 @@ void Environment::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::REAL,"ambient_light/skybox_contribution",PROPERTY_HINT_RANGE,"0,1,0.01"),_SCS("set_ambient_light_skybox_contribution"),_SCS("get_ambient_light_skybox_contribution") );
- ObjectTypeDB::bind_method(_MD("set_ssr_enabled","enabled"),&Environment::set_ssr_enabled);
- ObjectTypeDB::bind_method(_MD("is_ssr_enabled"),&Environment::is_ssr_enabled);
+ ClassDB::bind_method(_MD("set_ssr_enabled","enabled"),&Environment::set_ssr_enabled);
+ ClassDB::bind_method(_MD("is_ssr_enabled"),&Environment::is_ssr_enabled);
- ObjectTypeDB::bind_method(_MD("set_ssr_max_steps","max_steps"),&Environment::set_ssr_max_steps);
- ObjectTypeDB::bind_method(_MD("get_ssr_max_steps"),&Environment::get_ssr_max_steps);
+ ClassDB::bind_method(_MD("set_ssr_max_steps","max_steps"),&Environment::set_ssr_max_steps);
+ ClassDB::bind_method(_MD("get_ssr_max_steps"),&Environment::get_ssr_max_steps);
- ObjectTypeDB::bind_method(_MD("set_ssr_accel","accel"),&Environment::set_ssr_accel);
- ObjectTypeDB::bind_method(_MD("get_ssr_accel"),&Environment::get_ssr_accel);
+ ClassDB::bind_method(_MD("set_ssr_accel","accel"),&Environment::set_ssr_accel);
+ ClassDB::bind_method(_MD("get_ssr_accel"),&Environment::get_ssr_accel);
- ObjectTypeDB::bind_method(_MD("set_ssr_fade","fade"),&Environment::set_ssr_fade);
- ObjectTypeDB::bind_method(_MD("get_ssr_fade"),&Environment::get_ssr_fade);
+ ClassDB::bind_method(_MD("set_ssr_fade","fade"),&Environment::set_ssr_fade);
+ ClassDB::bind_method(_MD("get_ssr_fade"),&Environment::get_ssr_fade);
- ObjectTypeDB::bind_method(_MD("set_ssr_depth_tolerance","depth_tolerance"),&Environment::set_ssr_depth_tolerance);
- ObjectTypeDB::bind_method(_MD("get_ssr_depth_tolerance"),&Environment::get_ssr_depth_tolerance);
+ ClassDB::bind_method(_MD("set_ssr_depth_tolerance","depth_tolerance"),&Environment::set_ssr_depth_tolerance);
+ ClassDB::bind_method(_MD("get_ssr_depth_tolerance"),&Environment::get_ssr_depth_tolerance);
- ObjectTypeDB::bind_method(_MD("set_ssr_smooth","smooth"),&Environment::set_ssr_smooth);
- ObjectTypeDB::bind_method(_MD("is_ssr_smooth"),&Environment::is_ssr_smooth);
+ ClassDB::bind_method(_MD("set_ssr_smooth","smooth"),&Environment::set_ssr_smooth);
+ ClassDB::bind_method(_MD("is_ssr_smooth"),&Environment::is_ssr_smooth);
- ObjectTypeDB::bind_method(_MD("set_ssr_rough","rough"),&Environment::set_ssr_rough);
- ObjectTypeDB::bind_method(_MD("is_ssr_rough"),&Environment::is_ssr_rough);
+ ClassDB::bind_method(_MD("set_ssr_rough","rough"),&Environment::set_ssr_rough);
+ ClassDB::bind_method(_MD("is_ssr_rough"),&Environment::is_ssr_rough);
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"ss_reflections/enabled"),_SCS("set_ssr_enabled"),_SCS("is_ssr_enabled") );
ADD_PROPERTY(PropertyInfo(Variant::INT,"ss_reflections/max_steps",PROPERTY_HINT_RANGE,"1,512,1"),_SCS("set_ssr_max_steps"),_SCS("get_ssr_max_steps") );
@@ -763,32 +763,32 @@ void Environment::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"ss_reflections/accel_smooth"),_SCS("set_ssr_smooth"),_SCS("is_ssr_smooth") );
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"ss_reflections/roughness"),_SCS("set_ssr_rough"),_SCS("is_ssr_rough") );
- ObjectTypeDB::bind_method(_MD("set_ssao_enabled","enabled"),&Environment::set_ssao_enabled);
- ObjectTypeDB::bind_method(_MD("is_ssao_enabled"),&Environment::is_ssao_enabled);
+ ClassDB::bind_method(_MD("set_ssao_enabled","enabled"),&Environment::set_ssao_enabled);
+ ClassDB::bind_method(_MD("is_ssao_enabled"),&Environment::is_ssao_enabled);
- ObjectTypeDB::bind_method(_MD("set_ssao_radius","radius"),&Environment::set_ssao_radius);
- ObjectTypeDB::bind_method(_MD("get_ssao_radius"),&Environment::get_ssao_radius);
+ ClassDB::bind_method(_MD("set_ssao_radius","radius"),&Environment::set_ssao_radius);
+ ClassDB::bind_method(_MD("get_ssao_radius"),&Environment::get_ssao_radius);
- ObjectTypeDB::bind_method(_MD("set_ssao_intensity","intensity"),&Environment::set_ssao_intensity);
- ObjectTypeDB::bind_method(_MD("get_ssao_intensity"),&Environment::get_ssao_intensity);
+ ClassDB::bind_method(_MD("set_ssao_intensity","intensity"),&Environment::set_ssao_intensity);
+ ClassDB::bind_method(_MD("get_ssao_intensity"),&Environment::get_ssao_intensity);
- ObjectTypeDB::bind_method(_MD("set_ssao_radius2","radius"),&Environment::set_ssao_radius2);
- ObjectTypeDB::bind_method(_MD("get_ssao_radius2"),&Environment::get_ssao_radius2);
+ ClassDB::bind_method(_MD("set_ssao_radius2","radius"),&Environment::set_ssao_radius2);
+ ClassDB::bind_method(_MD("get_ssao_radius2"),&Environment::get_ssao_radius2);
- ObjectTypeDB::bind_method(_MD("set_ssao_intensity2","intensity"),&Environment::set_ssao_intensity2);
- ObjectTypeDB::bind_method(_MD("get_ssao_intensity2"),&Environment::get_ssao_intensity2);
+ ClassDB::bind_method(_MD("set_ssao_intensity2","intensity"),&Environment::set_ssao_intensity2);
+ ClassDB::bind_method(_MD("get_ssao_intensity2"),&Environment::get_ssao_intensity2);
- ObjectTypeDB::bind_method(_MD("set_ssao_bias","bias"),&Environment::set_ssao_bias);
- ObjectTypeDB::bind_method(_MD("get_ssao_bias"),&Environment::get_ssao_bias);
+ ClassDB::bind_method(_MD("set_ssao_bias","bias"),&Environment::set_ssao_bias);
+ ClassDB::bind_method(_MD("get_ssao_bias"),&Environment::get_ssao_bias);
- ObjectTypeDB::bind_method(_MD("set_ssao_direct_light_affect","amount"),&Environment::set_ssao_direct_light_affect);
- ObjectTypeDB::bind_method(_MD("get_ssao_direct_light_affect"),&Environment::get_ssao_direct_light_affect);
+ ClassDB::bind_method(_MD("set_ssao_direct_light_affect","amount"),&Environment::set_ssao_direct_light_affect);
+ ClassDB::bind_method(_MD("get_ssao_direct_light_affect"),&Environment::get_ssao_direct_light_affect);
- ObjectTypeDB::bind_method(_MD("set_ssao_color","color"),&Environment::set_ssao_color);
- ObjectTypeDB::bind_method(_MD("get_ssao_color"),&Environment::get_ssao_color);
+ ClassDB::bind_method(_MD("set_ssao_color","color"),&Environment::set_ssao_color);
+ ClassDB::bind_method(_MD("get_ssao_color"),&Environment::get_ssao_color);
- ObjectTypeDB::bind_method(_MD("set_ssao_blur","enabled"),&Environment::set_ssao_blur);
- ObjectTypeDB::bind_method(_MD("is_ssao_blur_enabled"),&Environment::is_ssao_blur_enabled);
+ ClassDB::bind_method(_MD("set_ssao_blur","enabled"),&Environment::set_ssao_blur);
+ ClassDB::bind_method(_MD("is_ssao_blur_enabled"),&Environment::is_ssao_blur_enabled);
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"ambient_occlusion/enabled"),_SCS("set_ssao_enabled"),_SCS("is_ssao_enabled") );
ADD_PROPERTY(PropertyInfo(Variant::REAL,"ambient_occlusion/radius",PROPERTY_HINT_RANGE,"0.1,16,0.1"),_SCS("set_ssao_radius"),_SCS("get_ssao_radius") );
@@ -800,35 +800,35 @@ void Environment::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::COLOR,"ambient_occlusion/color",PROPERTY_HINT_COLOR_NO_ALPHA),_SCS("set_ssao_color"),_SCS("get_ssao_color") );
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"ambient_occlusion/blur"),_SCS("set_ssao_blur"),_SCS("is_ssao_blur_enabled") );
- ObjectTypeDB::bind_method(_MD("set_dof_blur_far_enabled","enabled"),&Environment::set_dof_blur_far_enabled);
- ObjectTypeDB::bind_method(_MD("is_dof_blur_far_enabled"),&Environment::is_dof_blur_far_enabled);
+ ClassDB::bind_method(_MD("set_dof_blur_far_enabled","enabled"),&Environment::set_dof_blur_far_enabled);
+ ClassDB::bind_method(_MD("is_dof_blur_far_enabled"),&Environment::is_dof_blur_far_enabled);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_far_distance","intensity"),&Environment::set_dof_blur_far_distance);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_far_distance"),&Environment::get_dof_blur_far_distance);
+ ClassDB::bind_method(_MD("set_dof_blur_far_distance","intensity"),&Environment::set_dof_blur_far_distance);
+ ClassDB::bind_method(_MD("get_dof_blur_far_distance"),&Environment::get_dof_blur_far_distance);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_far_transition","intensity"),&Environment::set_dof_blur_far_transition);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_far_transition"),&Environment::get_dof_blur_far_transition);
+ ClassDB::bind_method(_MD("set_dof_blur_far_transition","intensity"),&Environment::set_dof_blur_far_transition);
+ ClassDB::bind_method(_MD("get_dof_blur_far_transition"),&Environment::get_dof_blur_far_transition);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_far_amount","intensity"),&Environment::set_dof_blur_far_amount);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_far_amount"),&Environment::get_dof_blur_far_amount);
+ ClassDB::bind_method(_MD("set_dof_blur_far_amount","intensity"),&Environment::set_dof_blur_far_amount);
+ ClassDB::bind_method(_MD("get_dof_blur_far_amount"),&Environment::get_dof_blur_far_amount);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_far_quality","intensity"),&Environment::set_dof_blur_far_quality);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_far_quality"),&Environment::get_dof_blur_far_quality);
+ ClassDB::bind_method(_MD("set_dof_blur_far_quality","intensity"),&Environment::set_dof_blur_far_quality);
+ ClassDB::bind_method(_MD("get_dof_blur_far_quality"),&Environment::get_dof_blur_far_quality);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_near_enabled","enabled"),&Environment::set_dof_blur_near_enabled);
- ObjectTypeDB::bind_method(_MD("is_dof_blur_near_enabled"),&Environment::is_dof_blur_near_enabled);
+ ClassDB::bind_method(_MD("set_dof_blur_near_enabled","enabled"),&Environment::set_dof_blur_near_enabled);
+ ClassDB::bind_method(_MD("is_dof_blur_near_enabled"),&Environment::is_dof_blur_near_enabled);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_near_distance","intensity"),&Environment::set_dof_blur_near_distance);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_near_distance"),&Environment::get_dof_blur_near_distance);
+ ClassDB::bind_method(_MD("set_dof_blur_near_distance","intensity"),&Environment::set_dof_blur_near_distance);
+ ClassDB::bind_method(_MD("get_dof_blur_near_distance"),&Environment::get_dof_blur_near_distance);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_near_transition","intensity"),&Environment::set_dof_blur_near_transition);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_near_transition"),&Environment::get_dof_blur_near_transition);
+ ClassDB::bind_method(_MD("set_dof_blur_near_transition","intensity"),&Environment::set_dof_blur_near_transition);
+ ClassDB::bind_method(_MD("get_dof_blur_near_transition"),&Environment::get_dof_blur_near_transition);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_near_amount","intensity"),&Environment::set_dof_blur_near_amount);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_near_amount"),&Environment::get_dof_blur_near_amount);
+ ClassDB::bind_method(_MD("set_dof_blur_near_amount","intensity"),&Environment::set_dof_blur_near_amount);
+ ClassDB::bind_method(_MD("get_dof_blur_near_amount"),&Environment::get_dof_blur_near_amount);
- ObjectTypeDB::bind_method(_MD("set_dof_blur_near_quality","level"),&Environment::set_dof_blur_near_quality);
- ObjectTypeDB::bind_method(_MD("get_dof_blur_near_quality"),&Environment::get_dof_blur_near_quality);
+ ClassDB::bind_method(_MD("set_dof_blur_near_quality","level"),&Environment::set_dof_blur_near_quality);
+ ClassDB::bind_method(_MD("get_dof_blur_near_quality"),&Environment::get_dof_blur_near_quality);
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"dof_blur_far/enabled"),_SCS("set_dof_blur_far_enabled"),_SCS("is_dof_blur_far_enabled") );
ADD_PROPERTY(PropertyInfo(Variant::REAL,"dof_blur_far/distance",PROPERTY_HINT_EXP_RANGE,"0.01,8192,0.01"),_SCS("set_dof_blur_far_distance"),_SCS("get_dof_blur_far_distance") );
@@ -843,32 +843,32 @@ void Environment::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::INT,"dof_blur_near/quality",PROPERTY_HINT_ENUM,"Low,Medium,High"),_SCS("set_dof_blur_near_quality"),_SCS("get_dof_blur_near_quality") );
- ObjectTypeDB::bind_method(_MD("set_glow_enabled","enabled"),&Environment::set_glow_enabled);
- ObjectTypeDB::bind_method(_MD("is_glow_enabled"),&Environment::is_glow_enabled);
+ ClassDB::bind_method(_MD("set_glow_enabled","enabled"),&Environment::set_glow_enabled);
+ ClassDB::bind_method(_MD("is_glow_enabled"),&Environment::is_glow_enabled);
- ObjectTypeDB::bind_method(_MD("set_glow_level","idx","enabled"),&Environment::set_glow_level);
- ObjectTypeDB::bind_method(_MD("is_glow_level_enabled","idx"),&Environment::is_glow_level_enabled);
+ ClassDB::bind_method(_MD("set_glow_level","idx","enabled"),&Environment::set_glow_level);
+ ClassDB::bind_method(_MD("is_glow_level_enabled","idx"),&Environment::is_glow_level_enabled);
- ObjectTypeDB::bind_method(_MD("set_glow_intensity","intensity"),&Environment::set_glow_intensity);
- ObjectTypeDB::bind_method(_MD("get_glow_intensity"),&Environment::get_glow_intensity);
+ ClassDB::bind_method(_MD("set_glow_intensity","intensity"),&Environment::set_glow_intensity);
+ ClassDB::bind_method(_MD("get_glow_intensity"),&Environment::get_glow_intensity);
- ObjectTypeDB::bind_method(_MD("set_glow_strength","strength"),&Environment::set_glow_strength);
- ObjectTypeDB::bind_method(_MD("get_glow_strength"),&Environment::get_glow_strength);
+ ClassDB::bind_method(_MD("set_glow_strength","strength"),&Environment::set_glow_strength);
+ ClassDB::bind_method(_MD("get_glow_strength"),&Environment::get_glow_strength);
- ObjectTypeDB::bind_method(_MD("set_glow_bloom","amount"),&Environment::set_glow_bloom);
- ObjectTypeDB::bind_method(_MD("get_glow_bloom"),&Environment::get_glow_bloom);
+ ClassDB::bind_method(_MD("set_glow_bloom","amount"),&Environment::set_glow_bloom);
+ ClassDB::bind_method(_MD("get_glow_bloom"),&Environment::get_glow_bloom);
- ObjectTypeDB::bind_method(_MD("set_glow_blend_mode","mode"),&Environment::set_glow_blend_mode);
- ObjectTypeDB::bind_method(_MD("get_glow_blend_mode"),&Environment::get_glow_blend_mode);
+ ClassDB::bind_method(_MD("set_glow_blend_mode","mode"),&Environment::set_glow_blend_mode);
+ ClassDB::bind_method(_MD("get_glow_blend_mode"),&Environment::get_glow_blend_mode);
- ObjectTypeDB::bind_method(_MD("set_glow_hdr_bleed_treshold","treshold"),&Environment::set_glow_hdr_bleed_treshold);
- ObjectTypeDB::bind_method(_MD("get_glow_hdr_bleed_treshold"),&Environment::get_glow_hdr_bleed_treshold);
+ ClassDB::bind_method(_MD("set_glow_hdr_bleed_treshold","treshold"),&Environment::set_glow_hdr_bleed_treshold);
+ ClassDB::bind_method(_MD("get_glow_hdr_bleed_treshold"),&Environment::get_glow_hdr_bleed_treshold);
- ObjectTypeDB::bind_method(_MD("set_glow_hdr_bleed_scale","scale"),&Environment::set_glow_hdr_bleed_scale);
- ObjectTypeDB::bind_method(_MD("get_glow_hdr_bleed_scale"),&Environment::get_glow_hdr_bleed_scale);
+ ClassDB::bind_method(_MD("set_glow_hdr_bleed_scale","scale"),&Environment::set_glow_hdr_bleed_scale);
+ ClassDB::bind_method(_MD("get_glow_hdr_bleed_scale"),&Environment::get_glow_hdr_bleed_scale);
- ObjectTypeDB::bind_method(_MD("set_glow_bicubic_upscale","enabled"),&Environment::set_glow_bicubic_upscale);
- ObjectTypeDB::bind_method(_MD("is_glow_bicubic_upscale_enabled"),&Environment::is_glow_bicubic_upscale_enabled);
+ ClassDB::bind_method(_MD("set_glow_bicubic_upscale","enabled"),&Environment::set_glow_bicubic_upscale);
+ ClassDB::bind_method(_MD("is_glow_bicubic_upscale_enabled"),&Environment::is_glow_bicubic_upscale_enabled);
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"glow/enabled"),_SCS("set_glow_enabled"),_SCS("is_glow_enabled") );
ADD_PROPERTYI(PropertyInfo(Variant::BOOL,"glow/levels/1"),_SCS("set_glow_level"),_SCS("is_glow_level_enabled"),0 );
@@ -888,29 +888,29 @@ void Environment::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"glow/bicubic_upscale"),_SCS("set_glow_bicubic_upscale"),_SCS("is_glow_bicubic_upscale_enabled") );
- ObjectTypeDB::bind_method(_MD("set_tonemapper","mode"),&Environment::set_tonemapper);
- ObjectTypeDB::bind_method(_MD("get_tonemapper"),&Environment::get_tonemapper);
+ ClassDB::bind_method(_MD("set_tonemapper","mode"),&Environment::set_tonemapper);
+ ClassDB::bind_method(_MD("get_tonemapper"),&Environment::get_tonemapper);
- ObjectTypeDB::bind_method(_MD("set_tonemap_exposure","exposure"),&Environment::set_tonemap_exposure);
- ObjectTypeDB::bind_method(_MD("get_tonemap_exposure"),&Environment::get_tonemap_exposure);
+ ClassDB::bind_method(_MD("set_tonemap_exposure","exposure"),&Environment::set_tonemap_exposure);
+ ClassDB::bind_method(_MD("get_tonemap_exposure"),&Environment::get_tonemap_exposure);
- ObjectTypeDB::bind_method(_MD("set_tonemap_white","white"),&Environment::set_tonemap_white);
- ObjectTypeDB::bind_method(_MD("get_tonemap_white"),&Environment::get_tonemap_white);
+ ClassDB::bind_method(_MD("set_tonemap_white","white"),&Environment::set_tonemap_white);
+ ClassDB::bind_method(_MD("get_tonemap_white"),&Environment::get_tonemap_white);
- ObjectTypeDB::bind_method(_MD("set_tonemap_auto_exposure","auto_exposure"),&Environment::set_tonemap_auto_exposure);
- ObjectTypeDB::bind_method(_MD("get_tonemap_auto_exposure"),&Environment::get_tonemap_auto_exposure);
+ ClassDB::bind_method(_MD("set_tonemap_auto_exposure","auto_exposure"),&Environment::set_tonemap_auto_exposure);
+ ClassDB::bind_method(_MD("get_tonemap_auto_exposure"),&Environment::get_tonemap_auto_exposure);
- ObjectTypeDB::bind_method(_MD("set_tonemap_auto_exposure_max","exposure_max"),&Environment::set_tonemap_auto_exposure_max);
- ObjectTypeDB::bind_method(_MD("get_tonemap_auto_exposure_max"),&Environment::get_tonemap_auto_exposure_max);
+ ClassDB::bind_method(_MD("set_tonemap_auto_exposure_max","exposure_max"),&Environment::set_tonemap_auto_exposure_max);
+ ClassDB::bind_method(_MD("get_tonemap_auto_exposure_max"),&Environment::get_tonemap_auto_exposure_max);
- ObjectTypeDB::bind_method(_MD("set_tonemap_auto_exposure_min","exposure_min"),&Environment::set_tonemap_auto_exposure_min);
- ObjectTypeDB::bind_method(_MD("get_tonemap_auto_exposure_min"),&Environment::get_tonemap_auto_exposure_min);
+ ClassDB::bind_method(_MD("set_tonemap_auto_exposure_min","exposure_min"),&Environment::set_tonemap_auto_exposure_min);
+ ClassDB::bind_method(_MD("get_tonemap_auto_exposure_min"),&Environment::get_tonemap_auto_exposure_min);
- ObjectTypeDB::bind_method(_MD("set_tonemap_auto_exposure_speed","exposure_speed"),&Environment::set_tonemap_auto_exposure_speed);
- ObjectTypeDB::bind_method(_MD("get_tonemap_auto_exposure_speed"),&Environment::get_tonemap_auto_exposure_speed);
+ ClassDB::bind_method(_MD("set_tonemap_auto_exposure_speed","exposure_speed"),&Environment::set_tonemap_auto_exposure_speed);
+ ClassDB::bind_method(_MD("get_tonemap_auto_exposure_speed"),&Environment::get_tonemap_auto_exposure_speed);
- ObjectTypeDB::bind_method(_MD("set_tonemap_auto_exposure_grey","exposure_grey"),&Environment::set_tonemap_auto_exposure_grey);
- ObjectTypeDB::bind_method(_MD("get_tonemap_auto_exposure_grey"),&Environment::get_tonemap_auto_exposure_grey);
+ ClassDB::bind_method(_MD("set_tonemap_auto_exposure_grey","exposure_grey"),&Environment::set_tonemap_auto_exposure_grey);
+ ClassDB::bind_method(_MD("get_tonemap_auto_exposure_grey"),&Environment::get_tonemap_auto_exposure_grey);
ADD_PROPERTY(PropertyInfo(Variant::INT,"tonemap/mode",PROPERTY_HINT_ENUM,"Linear,Reindhart,Filmic,Aces"),_SCS("set_tonemapper"),_SCS("get_tonemapper") );
@@ -922,20 +922,20 @@ void Environment::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::REAL,"auto_exposure/max_luma",PROPERTY_HINT_RANGE,"0,16,0.01"),_SCS("set_tonemap_auto_exposure_max"),_SCS("get_tonemap_auto_exposure_max") );
ADD_PROPERTY(PropertyInfo(Variant::REAL,"auto_exposure/speed",PROPERTY_HINT_RANGE,"0.01,64,0.01"),_SCS("set_tonemap_auto_exposure_speed"),_SCS("get_tonemap_auto_exposure_speed") );
- ObjectTypeDB::bind_method(_MD("set_adjustment_enable","enabled"),&Environment::set_adjustment_enable);
- ObjectTypeDB::bind_method(_MD("is_adjustment_enabled"),&Environment::is_adjustment_enabled);
+ ClassDB::bind_method(_MD("set_adjustment_enable","enabled"),&Environment::set_adjustment_enable);
+ ClassDB::bind_method(_MD("is_adjustment_enabled"),&Environment::is_adjustment_enabled);
- ObjectTypeDB::bind_method(_MD("set_adjustment_brightness","brightness"),&Environment::set_adjustment_brightness);
- ObjectTypeDB::bind_method(_MD("get_adjustment_brightness"),&Environment::get_adjustment_brightness);
+ ClassDB::bind_method(_MD("set_adjustment_brightness","brightness"),&Environment::set_adjustment_brightness);
+ ClassDB::bind_method(_MD("get_adjustment_brightness"),&Environment::get_adjustment_brightness);
- ObjectTypeDB::bind_method(_MD("set_adjustment_contrast","contrast"),&Environment::set_adjustment_contrast);
- ObjectTypeDB::bind_method(_MD("get_adjustment_contrast"),&Environment::get_adjustment_contrast);
+ ClassDB::bind_method(_MD("set_adjustment_contrast","contrast"),&Environment::set_adjustment_contrast);
+ ClassDB::bind_method(_MD("get_adjustment_contrast"),&Environment::get_adjustment_contrast);
- ObjectTypeDB::bind_method(_MD("set_adjustment_saturation","saturation"),&Environment::set_adjustment_saturation);
- ObjectTypeDB::bind_method(_MD("get_adjustment_saturation"),&Environment::get_adjustment_saturation);
+ ClassDB::bind_method(_MD("set_adjustment_saturation","saturation"),&Environment::set_adjustment_saturation);
+ ClassDB::bind_method(_MD("get_adjustment_saturation"),&Environment::get_adjustment_saturation);
- ObjectTypeDB::bind_method(_MD("set_adjustment_color_correction","color_correction"),&Environment::set_adjustment_color_correction);
- ObjectTypeDB::bind_method(_MD("get_adjustment_color_correction"),&Environment::get_adjustment_color_correction);
+ ClassDB::bind_method(_MD("set_adjustment_color_correction","color_correction"),&Environment::set_adjustment_color_correction);
+ ClassDB::bind_method(_MD("get_adjustment_color_correction"),&Environment::get_adjustment_color_correction);
ADD_PROPERTY(PropertyInfo(Variant::BOOL,"adjustment/enabled"),_SCS("set_adjustment_enable"),_SCS("is_adjustment_enabled") );
ADD_PROPERTY(PropertyInfo(Variant::REAL,"adjustment/brightness",PROPERTY_HINT_RANGE,"0.01,8,0.01"),_SCS("set_adjustment_brightness"),_SCS("get_adjustment_brightness") );
diff --git a/scene/resources/environment.h b/scene/resources/environment.h
index 8f2e4532a4..b8c243b588 100644
--- a/scene/resources/environment.h
+++ b/scene/resources/environment.h
@@ -36,7 +36,7 @@
class Environment : public Resource {
- OBJ_TYPE(Environment,Resource);
+ GDCLASS(Environment,Resource);
public:
enum BGMode {
diff --git a/scene/resources/event_stream.h b/scene/resources/event_stream.h
index 82a59ebab5..40af78fcce 100644
--- a/scene/resources/event_stream.h
+++ b/scene/resources/event_stream.h
@@ -34,7 +34,7 @@
class EventStreamPlayback : public Reference {
- OBJ_TYPE(EventStreamPlayback,Reference);
+ GDCLASS(EventStreamPlayback,Reference);
class InternalEventStream : public AudioServer::EventStream {
public:
@@ -99,7 +99,7 @@ public:
class EventStream : public Resource {
- OBJ_TYPE(EventStream,Resource);
+ GDCLASS(EventStream,Resource);
OBJ_SAVE_TYPE( EventStream ); //children are all saved as EventStream, so they can be exchanged
public:
diff --git a/scene/resources/font.cpp b/scene/resources/font.cpp
index 743a0b1fc5..d4e18c58b8 100644
--- a/scene/resources/font.cpp
+++ b/scene/resources/font.cpp
@@ -78,14 +78,14 @@ void Font::update_changes() {
void Font::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("draw","canvas_item","pos","string","modulate","clip_w"),&Font::draw,DEFVAL(Color(1,1,1)),DEFVAL(-1));
- ObjectTypeDB::bind_method(_MD("get_ascent"),&Font::get_ascent);
- ObjectTypeDB::bind_method(_MD("get_descent"),&Font::get_descent);
- ObjectTypeDB::bind_method(_MD("get_height"),&Font::get_height);
- ObjectTypeDB::bind_method(_MD("is_distance_field_hint"),&Font::is_distance_field_hint);
- ObjectTypeDB::bind_method(_MD("get_string_size","string"),&Font::get_string_size);
- ObjectTypeDB::bind_method(_MD("draw_char","canvas_item","pos","char","next","modulate"),&Font::draw_char,DEFVAL(-1),DEFVAL(Color(1,1,1)));
- ObjectTypeDB::bind_method(_MD("update_changes"),&Font::update_changes);
+ ClassDB::bind_method(_MD("draw","canvas_item","pos","string","modulate","clip_w"),&Font::draw,DEFVAL(Color(1,1,1)),DEFVAL(-1));
+ ClassDB::bind_method(_MD("get_ascent"),&Font::get_ascent);
+ ClassDB::bind_method(_MD("get_descent"),&Font::get_descent);
+ ClassDB::bind_method(_MD("get_height"),&Font::get_height);
+ ClassDB::bind_method(_MD("is_distance_field_hint"),&Font::is_distance_field_hint);
+ ClassDB::bind_method(_MD("get_string_size","string"),&Font::get_string_size);
+ ClassDB::bind_method(_MD("draw_char","canvas_item","pos","char","next","modulate"),&Font::draw_char,DEFVAL(-1),DEFVAL(Color(1,1,1)));
+ ClassDB::bind_method(_MD("update_changes"),&Font::update_changes);
}
@@ -564,39 +564,39 @@ Size2 BitmapFont::get_char_size(CharType p_char,CharType p_next) const {
void BitmapFont::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("create_from_fnt","path"),&BitmapFont::create_from_fnt);
- ObjectTypeDB::bind_method(_MD("set_height","px"),&BitmapFont::set_height);
+ ClassDB::bind_method(_MD("create_from_fnt","path"),&BitmapFont::create_from_fnt);
+ ClassDB::bind_method(_MD("set_height","px"),&BitmapFont::set_height);
- ObjectTypeDB::bind_method(_MD("set_ascent","px"),&BitmapFont::set_ascent);
+ ClassDB::bind_method(_MD("set_ascent","px"),&BitmapFont::set_ascent);
- ObjectTypeDB::bind_method(_MD("add_kerning_pair","char_a","char_b","kerning"),&BitmapFont::add_kerning_pair);
- ObjectTypeDB::bind_method(_MD("get_kerning_pair","char_a","char_b"),&BitmapFont::get_kerning_pair);
+ ClassDB::bind_method(_MD("add_kerning_pair","char_a","char_b","kerning"),&BitmapFont::add_kerning_pair);
+ ClassDB::bind_method(_MD("get_kerning_pair","char_a","char_b"),&BitmapFont::get_kerning_pair);
- ObjectTypeDB::bind_method(_MD("add_texture","texture:Texture"),&BitmapFont::add_texture);
- ObjectTypeDB::bind_method(_MD("add_char","character","texture","rect","align","advance"),&BitmapFont::add_char,DEFVAL(Point2()),DEFVAL(-1));
+ ClassDB::bind_method(_MD("add_texture","texture:Texture"),&BitmapFont::add_texture);
+ ClassDB::bind_method(_MD("add_char","character","texture","rect","align","advance"),&BitmapFont::add_char,DEFVAL(Point2()),DEFVAL(-1));
- ObjectTypeDB::bind_method(_MD("get_texture_count"),&BitmapFont::get_texture_count);
- ObjectTypeDB::bind_method(_MD("get_texture:Texture","idx"),&BitmapFont::get_texture);
+ ClassDB::bind_method(_MD("get_texture_count"),&BitmapFont::get_texture_count);
+ ClassDB::bind_method(_MD("get_texture:Texture","idx"),&BitmapFont::get_texture);
- ObjectTypeDB::bind_method(_MD("get_char_size","char","next"),&BitmapFont::get_char_size,DEFVAL(0));
+ ClassDB::bind_method(_MD("get_char_size","char","next"),&BitmapFont::get_char_size,DEFVAL(0));
- ObjectTypeDB::bind_method(_MD("set_distance_field_hint","enable"),&BitmapFont::set_distance_field_hint);
+ ClassDB::bind_method(_MD("set_distance_field_hint","enable"),&BitmapFont::set_distance_field_hint);
- ObjectTypeDB::bind_method(_MD("clear"),&BitmapFont::clear);
+ ClassDB::bind_method(_MD("clear"),&BitmapFont::clear);
- ObjectTypeDB::bind_method(_MD("_set_chars"),&BitmapFont::_set_chars);
- ObjectTypeDB::bind_method(_MD("_get_chars"),&BitmapFont::_get_chars);
+ ClassDB::bind_method(_MD("_set_chars"),&BitmapFont::_set_chars);
+ ClassDB::bind_method(_MD("_get_chars"),&BitmapFont::_get_chars);
- ObjectTypeDB::bind_method(_MD("_set_kernings"),&BitmapFont::_set_kernings);
- ObjectTypeDB::bind_method(_MD("_get_kernings"),&BitmapFont::_get_kernings);
+ ClassDB::bind_method(_MD("_set_kernings"),&BitmapFont::_set_kernings);
+ ClassDB::bind_method(_MD("_get_kernings"),&BitmapFont::_get_kernings);
- ObjectTypeDB::bind_method(_MD("_set_textures"),&BitmapFont::_set_textures);
- ObjectTypeDB::bind_method(_MD("_get_textures"),&BitmapFont::_get_textures);
+ ClassDB::bind_method(_MD("_set_textures"),&BitmapFont::_set_textures);
+ ClassDB::bind_method(_MD("_get_textures"),&BitmapFont::_get_textures);
- ObjectTypeDB::bind_method(_MD("set_fallback","fallback"),&BitmapFont::set_fallback);
- ObjectTypeDB::bind_method(_MD("get_fallback"),&BitmapFont::get_fallback);
+ ClassDB::bind_method(_MD("set_fallback","fallback"),&BitmapFont::set_fallback);
+ ClassDB::bind_method(_MD("get_fallback"),&BitmapFont::get_fallback);
ADD_PROPERTY( PropertyInfo( Variant::ARRAY, "textures", PROPERTY_HINT_NONE,"", PROPERTY_USAGE_NOEDITOR ), _SCS("_set_textures"), _SCS("_get_textures") );
ADD_PROPERTY( PropertyInfo( Variant::INT_ARRAY, "chars", PROPERTY_HINT_NONE,"", PROPERTY_USAGE_NOEDITOR ), _SCS("_set_chars"), _SCS("_get_chars") );
diff --git a/scene/resources/font.h b/scene/resources/font.h
index f311796559..397d48cbb0 100644
--- a/scene/resources/font.h
+++ b/scene/resources/font.h
@@ -39,7 +39,7 @@
class Font : public Resource {
- OBJ_TYPE( Font, Resource );
+ GDCLASS( Font, Resource );
protected:
@@ -69,7 +69,7 @@ public:
class BitmapFont : public Font {
- OBJ_TYPE( BitmapFont, Font );
+ GDCLASS( BitmapFont, Font );
RES_BASE_EXTENSION("fnt");
Vector< Ref<Texture> > textures;
diff --git a/scene/resources/gibberish_stream.cpp b/scene/resources/gibberish_stream.cpp
index 2c3bc9de60..3a6a6df7ea 100644
--- a/scene/resources/gibberish_stream.cpp
+++ b/scene/resources/gibberish_stream.cpp
@@ -305,17 +305,17 @@ float AudioStreamGibberish::get_pitch_random_scale() const {
void AudioStreamGibberish::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_phonemes","phonemes"),&AudioStreamGibberish::set_phonemes);
- ObjectTypeDB::bind_method(_MD("get_phonemes"),&AudioStreamGibberish::get_phonemes);
+ ClassDB::bind_method(_MD("set_phonemes","phonemes"),&AudioStreamGibberish::set_phonemes);
+ ClassDB::bind_method(_MD("get_phonemes"),&AudioStreamGibberish::get_phonemes);
- ObjectTypeDB::bind_method(_MD("set_pitch_scale","pitch_scale"),&AudioStreamGibberish::set_pitch_scale);
- ObjectTypeDB::bind_method(_MD("get_pitch_scale"),&AudioStreamGibberish::get_pitch_scale);
+ ClassDB::bind_method(_MD("set_pitch_scale","pitch_scale"),&AudioStreamGibberish::set_pitch_scale);
+ ClassDB::bind_method(_MD("get_pitch_scale"),&AudioStreamGibberish::get_pitch_scale);
- ObjectTypeDB::bind_method(_MD("set_pitch_random_scale","pitch_random_scale"),&AudioStreamGibberish::set_pitch_random_scale);
- ObjectTypeDB::bind_method(_MD("get_pitch_random_scale"),&AudioStreamGibberish::get_pitch_random_scale);
+ ClassDB::bind_method(_MD("set_pitch_random_scale","pitch_random_scale"),&AudioStreamGibberish::set_pitch_random_scale);
+ ClassDB::bind_method(_MD("get_pitch_random_scale"),&AudioStreamGibberish::get_pitch_random_scale);
- ObjectTypeDB::bind_method(_MD("set_xfade_time","sec"),&AudioStreamGibberish::set_xfade_time);
- ObjectTypeDB::bind_method(_MD("get_xfade_time"),&AudioStreamGibberish::get_xfade_time);
+ ClassDB::bind_method(_MD("set_xfade_time","sec"),&AudioStreamGibberish::set_xfade_time);
+ ClassDB::bind_method(_MD("get_xfade_time"),&AudioStreamGibberish::get_xfade_time);
ADD_PROPERTY( PropertyInfo(Variant::OBJECT,"phonemes",PROPERTY_HINT_RESOURCE_TYPE,"SampleLibrary"),_SCS("set_phonemes"),_SCS("get_phonemes"));
ADD_PROPERTY( PropertyInfo(Variant::REAL,"pitch_scale",PROPERTY_HINT_RANGE,"0.01,64,0.01"),_SCS("set_pitch_scale"),_SCS("get_pitch_scale"));
diff --git a/scene/resources/gibberish_stream.h b/scene/resources/gibberish_stream.h
index 557e78fc09..257a1faebf 100644
--- a/scene/resources/gibberish_stream.h
+++ b/scene/resources/gibberish_stream.h
@@ -37,7 +37,7 @@
#include "scene/resources/sample_library.h"
class AudioStreamGibberish : public AudioStream {
- OBJ_TYPE( AudioStreamGibberish, AudioStream );
+ GDCLASS( AudioStreamGibberish, AudioStream );
enum {
diff --git a/scene/resources/material.cpp b/scene/resources/material.cpp
index a6136b2741..d36705b4bb 100644
--- a/scene/resources/material.cpp
+++ b/scene/resources/material.cpp
@@ -831,101 +831,101 @@ Vector2 FixedSpatialMaterial::get_uv2_offset() const{
void FixedSpatialMaterial::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_albedo","albedo"),&FixedSpatialMaterial::set_albedo);
- ObjectTypeDB::bind_method(_MD("get_albedo"),&FixedSpatialMaterial::get_albedo);
+ ClassDB::bind_method(_MD("set_albedo","albedo"),&FixedSpatialMaterial::set_albedo);
+ ClassDB::bind_method(_MD("get_albedo"),&FixedSpatialMaterial::get_albedo);
- ObjectTypeDB::bind_method(_MD("set_specular_mode","specular_mode"),&FixedSpatialMaterial::set_specular_mode);
- ObjectTypeDB::bind_method(_MD("get_specular_mode"),&FixedSpatialMaterial::get_specular_mode);
+ ClassDB::bind_method(_MD("set_specular_mode","specular_mode"),&FixedSpatialMaterial::set_specular_mode);
+ ClassDB::bind_method(_MD("get_specular_mode"),&FixedSpatialMaterial::get_specular_mode);
- ObjectTypeDB::bind_method(_MD("set_specular","specular"),&FixedSpatialMaterial::set_specular);
- ObjectTypeDB::bind_method(_MD("get_specular"),&FixedSpatialMaterial::get_specular);
+ ClassDB::bind_method(_MD("set_specular","specular"),&FixedSpatialMaterial::set_specular);
+ ClassDB::bind_method(_MD("get_specular"),&FixedSpatialMaterial::get_specular);
- ObjectTypeDB::bind_method(_MD("set_metalness","metalness"),&FixedSpatialMaterial::set_metalness);
- ObjectTypeDB::bind_method(_MD("get_metalness"),&FixedSpatialMaterial::get_metalness);
+ ClassDB::bind_method(_MD("set_metalness","metalness"),&FixedSpatialMaterial::set_metalness);
+ ClassDB::bind_method(_MD("get_metalness"),&FixedSpatialMaterial::get_metalness);
- ObjectTypeDB::bind_method(_MD("set_roughness","roughness"),&FixedSpatialMaterial::set_roughness);
- ObjectTypeDB::bind_method(_MD("get_roughness"),&FixedSpatialMaterial::get_roughness);
+ ClassDB::bind_method(_MD("set_roughness","roughness"),&FixedSpatialMaterial::set_roughness);
+ ClassDB::bind_method(_MD("get_roughness"),&FixedSpatialMaterial::get_roughness);
- ObjectTypeDB::bind_method(_MD("set_emission","emission"),&FixedSpatialMaterial::set_emission);
- ObjectTypeDB::bind_method(_MD("get_emission"),&FixedSpatialMaterial::get_emission);
+ ClassDB::bind_method(_MD("set_emission","emission"),&FixedSpatialMaterial::set_emission);
+ ClassDB::bind_method(_MD("get_emission"),&FixedSpatialMaterial::get_emission);
- ObjectTypeDB::bind_method(_MD("set_emission_energy","emission_energy"),&FixedSpatialMaterial::set_emission_energy);
- ObjectTypeDB::bind_method(_MD("get_emission_energy"),&FixedSpatialMaterial::get_emission_energy);
+ ClassDB::bind_method(_MD("set_emission_energy","emission_energy"),&FixedSpatialMaterial::set_emission_energy);
+ ClassDB::bind_method(_MD("get_emission_energy"),&FixedSpatialMaterial::get_emission_energy);
- ObjectTypeDB::bind_method(_MD("set_normal_scale","normal_scale"),&FixedSpatialMaterial::set_normal_scale);
- ObjectTypeDB::bind_method(_MD("get_normal_scale"),&FixedSpatialMaterial::get_normal_scale);
+ ClassDB::bind_method(_MD("set_normal_scale","normal_scale"),&FixedSpatialMaterial::set_normal_scale);
+ ClassDB::bind_method(_MD("get_normal_scale"),&FixedSpatialMaterial::get_normal_scale);
- ObjectTypeDB::bind_method(_MD("set_rim","rim"),&FixedSpatialMaterial::set_rim);
- ObjectTypeDB::bind_method(_MD("get_rim"),&FixedSpatialMaterial::get_rim);
+ ClassDB::bind_method(_MD("set_rim","rim"),&FixedSpatialMaterial::set_rim);
+ ClassDB::bind_method(_MD("get_rim"),&FixedSpatialMaterial::get_rim);
- ObjectTypeDB::bind_method(_MD("set_rim_tint","rim_tint"),&FixedSpatialMaterial::set_rim_tint);
- ObjectTypeDB::bind_method(_MD("get_rim_tint"),&FixedSpatialMaterial::get_rim_tint);
+ ClassDB::bind_method(_MD("set_rim_tint","rim_tint"),&FixedSpatialMaterial::set_rim_tint);
+ ClassDB::bind_method(_MD("get_rim_tint"),&FixedSpatialMaterial::get_rim_tint);
- ObjectTypeDB::bind_method(_MD("set_clearcoat","clearcoat"),&FixedSpatialMaterial::set_clearcoat);
- ObjectTypeDB::bind_method(_MD("get_clearcoat"),&FixedSpatialMaterial::get_clearcoat);
+ ClassDB::bind_method(_MD("set_clearcoat","clearcoat"),&FixedSpatialMaterial::set_clearcoat);
+ ClassDB::bind_method(_MD("get_clearcoat"),&FixedSpatialMaterial::get_clearcoat);
- ObjectTypeDB::bind_method(_MD("set_clearcoat_gloss","clearcoat_gloss"),&FixedSpatialMaterial::set_clearcoat_gloss);
- ObjectTypeDB::bind_method(_MD("get_clearcoat_gloss"),&FixedSpatialMaterial::get_clearcoat_gloss);
+ ClassDB::bind_method(_MD("set_clearcoat_gloss","clearcoat_gloss"),&FixedSpatialMaterial::set_clearcoat_gloss);
+ ClassDB::bind_method(_MD("get_clearcoat_gloss"),&FixedSpatialMaterial::get_clearcoat_gloss);
- ObjectTypeDB::bind_method(_MD("set_anisotropy","anisotropy"),&FixedSpatialMaterial::set_anisotropy);
- ObjectTypeDB::bind_method(_MD("get_anisotropy"),&FixedSpatialMaterial::get_anisotropy);
+ ClassDB::bind_method(_MD("set_anisotropy","anisotropy"),&FixedSpatialMaterial::set_anisotropy);
+ ClassDB::bind_method(_MD("get_anisotropy"),&FixedSpatialMaterial::get_anisotropy);
- ObjectTypeDB::bind_method(_MD("set_height_scale","height_scale"),&FixedSpatialMaterial::set_height_scale);
- ObjectTypeDB::bind_method(_MD("get_height_scale"),&FixedSpatialMaterial::get_height_scale);
+ ClassDB::bind_method(_MD("set_height_scale","height_scale"),&FixedSpatialMaterial::set_height_scale);
+ ClassDB::bind_method(_MD("get_height_scale"),&FixedSpatialMaterial::get_height_scale);
- ObjectTypeDB::bind_method(_MD("set_subsurface_scattering_strength","strength"),&FixedSpatialMaterial::set_subsurface_scattering_strength);
- ObjectTypeDB::bind_method(_MD("get_subsurface_scattering_strength"),&FixedSpatialMaterial::get_subsurface_scattering_strength);
+ ClassDB::bind_method(_MD("set_subsurface_scattering_strength","strength"),&FixedSpatialMaterial::set_subsurface_scattering_strength);
+ ClassDB::bind_method(_MD("get_subsurface_scattering_strength"),&FixedSpatialMaterial::get_subsurface_scattering_strength);
- ObjectTypeDB::bind_method(_MD("set_refraction","refraction"),&FixedSpatialMaterial::set_refraction);
- ObjectTypeDB::bind_method(_MD("get_refraction"),&FixedSpatialMaterial::get_refraction);
+ ClassDB::bind_method(_MD("set_refraction","refraction"),&FixedSpatialMaterial::set_refraction);
+ ClassDB::bind_method(_MD("get_refraction"),&FixedSpatialMaterial::get_refraction);
- ObjectTypeDB::bind_method(_MD("set_refraction_roughness","refraction_roughness"),&FixedSpatialMaterial::set_refraction_roughness);
- ObjectTypeDB::bind_method(_MD("get_refraction_roughness"),&FixedSpatialMaterial::get_refraction_roughness);
+ ClassDB::bind_method(_MD("set_refraction_roughness","refraction_roughness"),&FixedSpatialMaterial::set_refraction_roughness);
+ ClassDB::bind_method(_MD("get_refraction_roughness"),&FixedSpatialMaterial::get_refraction_roughness);
- ObjectTypeDB::bind_method(_MD("set_line_width","line_width"),&FixedSpatialMaterial::set_line_width);
- ObjectTypeDB::bind_method(_MD("get_line_width"),&FixedSpatialMaterial::get_line_width);
+ ClassDB::bind_method(_MD("set_line_width","line_width"),&FixedSpatialMaterial::set_line_width);
+ ClassDB::bind_method(_MD("get_line_width"),&FixedSpatialMaterial::get_line_width);
- ObjectTypeDB::bind_method(_MD("set_point_size","point_size"),&FixedSpatialMaterial::set_point_size);
- ObjectTypeDB::bind_method(_MD("get_point_size"),&FixedSpatialMaterial::get_point_size);
+ ClassDB::bind_method(_MD("set_point_size","point_size"),&FixedSpatialMaterial::set_point_size);
+ ClassDB::bind_method(_MD("get_point_size"),&FixedSpatialMaterial::get_point_size);
- ObjectTypeDB::bind_method(_MD("set_detail_uv","detail_uv"),&FixedSpatialMaterial::set_detail_uv);
- ObjectTypeDB::bind_method(_MD("get_detail_uv"),&FixedSpatialMaterial::get_detail_uv);
+ ClassDB::bind_method(_MD("set_detail_uv","detail_uv"),&FixedSpatialMaterial::set_detail_uv);
+ ClassDB::bind_method(_MD("get_detail_uv"),&FixedSpatialMaterial::get_detail_uv);
- ObjectTypeDB::bind_method(_MD("set_blend_mode","blend_mode"),&FixedSpatialMaterial::set_blend_mode);
- ObjectTypeDB::bind_method(_MD("get_blend_mode"),&FixedSpatialMaterial::get_blend_mode);
+ ClassDB::bind_method(_MD("set_blend_mode","blend_mode"),&FixedSpatialMaterial::set_blend_mode);
+ ClassDB::bind_method(_MD("get_blend_mode"),&FixedSpatialMaterial::get_blend_mode);
- ObjectTypeDB::bind_method(_MD("set_depth_draw_mode","depth_draw_mode"),&FixedSpatialMaterial::set_depth_draw_mode);
- ObjectTypeDB::bind_method(_MD("get_depth_draw_mode"),&FixedSpatialMaterial::get_depth_draw_mode);
+ ClassDB::bind_method(_MD("set_depth_draw_mode","depth_draw_mode"),&FixedSpatialMaterial::set_depth_draw_mode);
+ ClassDB::bind_method(_MD("get_depth_draw_mode"),&FixedSpatialMaterial::get_depth_draw_mode);
- ObjectTypeDB::bind_method(_MD("set_cull_mode","cull_mode"),&FixedSpatialMaterial::set_cull_mode);
- ObjectTypeDB::bind_method(_MD("get_cull_mode"),&FixedSpatialMaterial::get_cull_mode);
+ ClassDB::bind_method(_MD("set_cull_mode","cull_mode"),&FixedSpatialMaterial::set_cull_mode);
+ ClassDB::bind_method(_MD("get_cull_mode"),&FixedSpatialMaterial::get_cull_mode);
- ObjectTypeDB::bind_method(_MD("set_diffuse_mode","diffuse_mode"),&FixedSpatialMaterial::set_diffuse_mode);
- ObjectTypeDB::bind_method(_MD("get_diffuse_mode"),&FixedSpatialMaterial::get_diffuse_mode);
+ ClassDB::bind_method(_MD("set_diffuse_mode","diffuse_mode"),&FixedSpatialMaterial::set_diffuse_mode);
+ ClassDB::bind_method(_MD("get_diffuse_mode"),&FixedSpatialMaterial::get_diffuse_mode);
- ObjectTypeDB::bind_method(_MD("set_flag","flag","enable"),&FixedSpatialMaterial::set_flag);
- ObjectTypeDB::bind_method(_MD("get_flag"),&FixedSpatialMaterial::get_flag);
+ ClassDB::bind_method(_MD("set_flag","flag","enable"),&FixedSpatialMaterial::set_flag);
+ ClassDB::bind_method(_MD("get_flag"),&FixedSpatialMaterial::get_flag);
- ObjectTypeDB::bind_method(_MD("set_feature","feature","enable"),&FixedSpatialMaterial::set_feature);
- ObjectTypeDB::bind_method(_MD("get_feature","feature"),&FixedSpatialMaterial::get_feature);
+ ClassDB::bind_method(_MD("set_feature","feature","enable"),&FixedSpatialMaterial::set_feature);
+ ClassDB::bind_method(_MD("get_feature","feature"),&FixedSpatialMaterial::get_feature);
- ObjectTypeDB::bind_method(_MD("set_texture","param:Texture","texture"),&FixedSpatialMaterial::set_texture);
- ObjectTypeDB::bind_method(_MD("get_texture:Texture","param:Texture"),&FixedSpatialMaterial::get_texture);
+ ClassDB::bind_method(_MD("set_texture","param:Texture","texture"),&FixedSpatialMaterial::set_texture);
+ ClassDB::bind_method(_MD("get_texture:Texture","param:Texture"),&FixedSpatialMaterial::get_texture);
- ObjectTypeDB::bind_method(_MD("set_detail_blend_mode","detail_blend_mode"),&FixedSpatialMaterial::set_detail_blend_mode);
- ObjectTypeDB::bind_method(_MD("get_detail_blend_mode"),&FixedSpatialMaterial::get_detail_blend_mode);
+ ClassDB::bind_method(_MD("set_detail_blend_mode","detail_blend_mode"),&FixedSpatialMaterial::set_detail_blend_mode);
+ ClassDB::bind_method(_MD("get_detail_blend_mode"),&FixedSpatialMaterial::get_detail_blend_mode);
- ObjectTypeDB::bind_method(_MD("set_uv1_scale","scale"),&FixedSpatialMaterial::set_uv1_scale);
- ObjectTypeDB::bind_method(_MD("get_uv1_scale"),&FixedSpatialMaterial::get_uv1_scale);
+ ClassDB::bind_method(_MD("set_uv1_scale","scale"),&FixedSpatialMaterial::set_uv1_scale);
+ ClassDB::bind_method(_MD("get_uv1_scale"),&FixedSpatialMaterial::get_uv1_scale);
- ObjectTypeDB::bind_method(_MD("set_uv1_offset","offset"),&FixedSpatialMaterial::set_uv1_offset);
- ObjectTypeDB::bind_method(_MD("get_uv1_offset"),&FixedSpatialMaterial::get_uv1_offset);
+ ClassDB::bind_method(_MD("set_uv1_offset","offset"),&FixedSpatialMaterial::set_uv1_offset);
+ ClassDB::bind_method(_MD("get_uv1_offset"),&FixedSpatialMaterial::get_uv1_offset);
- ObjectTypeDB::bind_method(_MD("set_uv2_scale","scale"),&FixedSpatialMaterial::set_uv2_scale);
- ObjectTypeDB::bind_method(_MD("get_uv2_scale"),&FixedSpatialMaterial::get_uv2_scale);
+ ClassDB::bind_method(_MD("set_uv2_scale","scale"),&FixedSpatialMaterial::set_uv2_scale);
+ ClassDB::bind_method(_MD("get_uv2_scale"),&FixedSpatialMaterial::get_uv2_scale);
- ObjectTypeDB::bind_method(_MD("set_uv2_offset","offset"),&FixedSpatialMaterial::set_uv2_offset);
- ObjectTypeDB::bind_method(_MD("get_uv2_offset"),&FixedSpatialMaterial::get_uv2_offset);
+ ClassDB::bind_method(_MD("set_uv2_offset","offset"),&FixedSpatialMaterial::set_uv2_offset);
+ ClassDB::bind_method(_MD("get_uv2_offset"),&FixedSpatialMaterial::get_uv2_offset);
ADD_PROPERTYI(PropertyInfo(Variant::BOOL,"flags/transparent"),_SCS("set_feature"),_SCS("get_feature"),FEATURE_TRANSPARENT);
ADD_PROPERTYI(PropertyInfo(Variant::BOOL,"flags/unshaded"),_SCS("set_flag"),_SCS("get_flag"),FLAG_UNSHADED);
diff --git a/scene/resources/material.h b/scene/resources/material.h
index c2659c4fc4..6b957d0203 100644
--- a/scene/resources/material.h
+++ b/scene/resources/material.h
@@ -41,7 +41,7 @@
class Material : public Resource {
- OBJ_TYPE(Material,Resource);
+ GDCLASS(Material,Resource);
RES_BASE_EXTENSION("mtl");
OBJ_SAVE_TYPE( Material );
@@ -59,7 +59,7 @@ public:
class FixedSpatialMaterial : public Material {
- OBJ_TYPE(FixedSpatialMaterial,Material)
+ GDCLASS(FixedSpatialMaterial,Material)
public:
diff --git a/scene/resources/mesh.cpp b/scene/resources/mesh.cpp
index 58c2d08eec..ed35eb0216 100644
--- a/scene/resources/mesh.cpp
+++ b/scene/resources/mesh.cpp
@@ -1019,31 +1019,31 @@ Ref<Mesh> Mesh::create_outline(float p_margin) const {
void Mesh::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("add_morph_target","name"),&Mesh::add_morph_target);
- ObjectTypeDB::bind_method(_MD("get_morph_target_count"),&Mesh::get_morph_target_count);
- ObjectTypeDB::bind_method(_MD("get_morph_target_name","index"),&Mesh::get_morph_target_name);
- ObjectTypeDB::bind_method(_MD("clear_morph_targets"),&Mesh::clear_morph_targets);
- ObjectTypeDB::bind_method(_MD("set_morph_target_mode","mode"),&Mesh::set_morph_target_mode);
- ObjectTypeDB::bind_method(_MD("get_morph_target_mode"),&Mesh::get_morph_target_mode);
-
- ObjectTypeDB::bind_method(_MD("add_surface_from_arrays","primitive","arrays","blend_shapes","compress_flags"),&Mesh::add_surface_from_arrays,DEFVAL(Array()),DEFVAL(ARRAY_COMPRESS_DEFAULT));
- ObjectTypeDB::bind_method(_MD("get_surface_count"),&Mesh::get_surface_count);
- ObjectTypeDB::bind_method(_MD("surface_remove","surf_idx"),&Mesh::surface_remove);
- ObjectTypeDB::bind_method(_MD("surface_get_array_len","surf_idx"),&Mesh::surface_get_array_len);
- ObjectTypeDB::bind_method(_MD("surface_get_array_index_len","surf_idx"),&Mesh::surface_get_array_index_len);
- ObjectTypeDB::bind_method(_MD("surface_get_format","surf_idx"),&Mesh::surface_get_format);
- ObjectTypeDB::bind_method(_MD("surface_get_primitive_type","surf_idx"),&Mesh::surface_get_primitive_type);
- ObjectTypeDB::bind_method(_MD("surface_set_material","surf_idx","material:Material"),&Mesh::surface_set_material);
- ObjectTypeDB::bind_method(_MD("surface_get_material:Material","surf_idx"),&Mesh::surface_get_material);
- ObjectTypeDB::bind_method(_MD("surface_set_name","surf_idx","name"),&Mesh::surface_set_name);
- ObjectTypeDB::bind_method(_MD("surface_get_name","surf_idx"),&Mesh::surface_get_name);
- ObjectTypeDB::bind_method(_MD("center_geometry"),&Mesh::center_geometry);
- ObjectTypeDB::set_method_flags(get_type_static(),_SCS("center_geometry"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
- ObjectTypeDB::bind_method(_MD("regen_normalmaps"),&Mesh::regen_normalmaps);
- ObjectTypeDB::set_method_flags(get_type_static(),_SCS("regen_normalmaps"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
-
- ObjectTypeDB::bind_method(_MD("set_custom_aabb","aabb"),&Mesh::set_custom_aabb);
- ObjectTypeDB::bind_method(_MD("get_custom_aabb"),&Mesh::get_custom_aabb);
+ ClassDB::bind_method(_MD("add_morph_target","name"),&Mesh::add_morph_target);
+ ClassDB::bind_method(_MD("get_morph_target_count"),&Mesh::get_morph_target_count);
+ ClassDB::bind_method(_MD("get_morph_target_name","index"),&Mesh::get_morph_target_name);
+ ClassDB::bind_method(_MD("clear_morph_targets"),&Mesh::clear_morph_targets);
+ ClassDB::bind_method(_MD("set_morph_target_mode","mode"),&Mesh::set_morph_target_mode);
+ ClassDB::bind_method(_MD("get_morph_target_mode"),&Mesh::get_morph_target_mode);
+
+ ClassDB::bind_method(_MD("add_surface_from_arrays","primitive","arrays","blend_shapes","compress_flags"),&Mesh::add_surface_from_arrays,DEFVAL(Array()),DEFVAL(ARRAY_COMPRESS_DEFAULT));
+ ClassDB::bind_method(_MD("get_surface_count"),&Mesh::get_surface_count);
+ ClassDB::bind_method(_MD("surface_remove","surf_idx"),&Mesh::surface_remove);
+ ClassDB::bind_method(_MD("surface_get_array_len","surf_idx"),&Mesh::surface_get_array_len);
+ ClassDB::bind_method(_MD("surface_get_array_index_len","surf_idx"),&Mesh::surface_get_array_index_len);
+ ClassDB::bind_method(_MD("surface_get_format","surf_idx"),&Mesh::surface_get_format);
+ ClassDB::bind_method(_MD("surface_get_primitive_type","surf_idx"),&Mesh::surface_get_primitive_type);
+ ClassDB::bind_method(_MD("surface_set_material","surf_idx","material:Material"),&Mesh::surface_set_material);
+ ClassDB::bind_method(_MD("surface_get_material:Material","surf_idx"),&Mesh::surface_get_material);
+ ClassDB::bind_method(_MD("surface_set_name","surf_idx","name"),&Mesh::surface_set_name);
+ ClassDB::bind_method(_MD("surface_get_name","surf_idx"),&Mesh::surface_get_name);
+ ClassDB::bind_method(_MD("center_geometry"),&Mesh::center_geometry);
+ ClassDB::set_method_flags(get_class_static(),_SCS("center_geometry"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
+ ClassDB::bind_method(_MD("regen_normalmaps"),&Mesh::regen_normalmaps);
+ ClassDB::set_method_flags(get_class_static(),_SCS("regen_normalmaps"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
+
+ ClassDB::bind_method(_MD("set_custom_aabb","aabb"),&Mesh::set_custom_aabb);
+ ClassDB::bind_method(_MD("get_custom_aabb"),&Mesh::get_custom_aabb);
BIND_CONSTANT( NO_INDEX_ARRAY );
diff --git a/scene/resources/mesh.h b/scene/resources/mesh.h
index 399cd8921f..9be90b6436 100644
--- a/scene/resources/mesh.h
+++ b/scene/resources/mesh.h
@@ -39,7 +39,7 @@
*/
class Mesh : public Resource {
- OBJ_TYPE( Mesh, Resource );
+ GDCLASS( Mesh, Resource );
RES_BASE_EXTENSION("msh");
public:
diff --git a/scene/resources/mesh_data_tool.cpp b/scene/resources/mesh_data_tool.cpp
index e06ff6fd52..4a753e6c09 100644
--- a/scene/resources/mesh_data_tool.cpp
+++ b/scene/resources/mesh_data_tool.cpp
@@ -565,62 +565,62 @@ void MeshDataTool::set_material(const Ref<Material> &p_material) {
void MeshDataTool::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("clear"),&MeshDataTool::clear);
- ObjectTypeDB::bind_method(_MD("create_from_surface","mesh","surface"),&MeshDataTool::create_from_surface);
- ObjectTypeDB::bind_method(_MD("commit_to_surface","mesh"),&MeshDataTool::commit_to_surface);
+ ClassDB::bind_method(_MD("clear"),&MeshDataTool::clear);
+ ClassDB::bind_method(_MD("create_from_surface","mesh","surface"),&MeshDataTool::create_from_surface);
+ ClassDB::bind_method(_MD("commit_to_surface","mesh"),&MeshDataTool::commit_to_surface);
- ObjectTypeDB::bind_method(_MD("get_format"),&MeshDataTool::get_format);
+ ClassDB::bind_method(_MD("get_format"),&MeshDataTool::get_format);
- ObjectTypeDB::bind_method(_MD("get_vertex_count"),&MeshDataTool::get_vertex_count);
- ObjectTypeDB::bind_method(_MD("get_edge_count"),&MeshDataTool::get_edge_count);
- ObjectTypeDB::bind_method(_MD("get_face_count"),&MeshDataTool::get_face_count);
+ ClassDB::bind_method(_MD("get_vertex_count"),&MeshDataTool::get_vertex_count);
+ ClassDB::bind_method(_MD("get_edge_count"),&MeshDataTool::get_edge_count);
+ ClassDB::bind_method(_MD("get_face_count"),&MeshDataTool::get_face_count);
- ObjectTypeDB::bind_method(_MD("set_vertex","idx","vertex"),&MeshDataTool::set_vertex);
- ObjectTypeDB::bind_method(_MD("get_vertex","idx"),&MeshDataTool::get_vertex);
+ ClassDB::bind_method(_MD("set_vertex","idx","vertex"),&MeshDataTool::set_vertex);
+ ClassDB::bind_method(_MD("get_vertex","idx"),&MeshDataTool::get_vertex);
- ObjectTypeDB::bind_method(_MD("set_vertex_normal","idx","normal"),&MeshDataTool::set_vertex_normal);
- ObjectTypeDB::bind_method(_MD("get_vertex_normal","idx"),&MeshDataTool::get_vertex_normal);
+ ClassDB::bind_method(_MD("set_vertex_normal","idx","normal"),&MeshDataTool::set_vertex_normal);
+ ClassDB::bind_method(_MD("get_vertex_normal","idx"),&MeshDataTool::get_vertex_normal);
- ObjectTypeDB::bind_method(_MD("set_vertex_tangent","idx","tangent"),&MeshDataTool::set_vertex_tangent);
- ObjectTypeDB::bind_method(_MD("get_vertex_tangent","idx"),&MeshDataTool::get_vertex_tangent);
+ ClassDB::bind_method(_MD("set_vertex_tangent","idx","tangent"),&MeshDataTool::set_vertex_tangent);
+ ClassDB::bind_method(_MD("get_vertex_tangent","idx"),&MeshDataTool::get_vertex_tangent);
- ObjectTypeDB::bind_method(_MD("set_vertex_uv","idx","uv"),&MeshDataTool::set_vertex_uv);
- ObjectTypeDB::bind_method(_MD("get_vertex_uv","idx"),&MeshDataTool::get_vertex_uv);
+ ClassDB::bind_method(_MD("set_vertex_uv","idx","uv"),&MeshDataTool::set_vertex_uv);
+ ClassDB::bind_method(_MD("get_vertex_uv","idx"),&MeshDataTool::get_vertex_uv);
- ObjectTypeDB::bind_method(_MD("set_vertex_uv2","idx","uv2"),&MeshDataTool::set_vertex_uv2);
- ObjectTypeDB::bind_method(_MD("get_vertex_uv2","idx"),&MeshDataTool::get_vertex_uv2);
+ ClassDB::bind_method(_MD("set_vertex_uv2","idx","uv2"),&MeshDataTool::set_vertex_uv2);
+ ClassDB::bind_method(_MD("get_vertex_uv2","idx"),&MeshDataTool::get_vertex_uv2);
- ObjectTypeDB::bind_method(_MD("set_vertex_color","idx","color"),&MeshDataTool::set_vertex_color);
- ObjectTypeDB::bind_method(_MD("get_vertex_color","idx"),&MeshDataTool::get_vertex_color);
+ ClassDB::bind_method(_MD("set_vertex_color","idx","color"),&MeshDataTool::set_vertex_color);
+ ClassDB::bind_method(_MD("get_vertex_color","idx"),&MeshDataTool::get_vertex_color);
- ObjectTypeDB::bind_method(_MD("set_vertex_bones","idx","bones"),&MeshDataTool::set_vertex_bones);
- ObjectTypeDB::bind_method(_MD("get_vertex_bones","idx"),&MeshDataTool::get_vertex_bones);
+ ClassDB::bind_method(_MD("set_vertex_bones","idx","bones"),&MeshDataTool::set_vertex_bones);
+ ClassDB::bind_method(_MD("get_vertex_bones","idx"),&MeshDataTool::get_vertex_bones);
- ObjectTypeDB::bind_method(_MD("set_vertex_weights","idx","weights"),&MeshDataTool::set_vertex_weights);
- ObjectTypeDB::bind_method(_MD("get_vertex_weights","idx"),&MeshDataTool::get_vertex_weights);
+ ClassDB::bind_method(_MD("set_vertex_weights","idx","weights"),&MeshDataTool::set_vertex_weights);
+ ClassDB::bind_method(_MD("get_vertex_weights","idx"),&MeshDataTool::get_vertex_weights);
- ObjectTypeDB::bind_method(_MD("set_vertex_meta","idx","meta"),&MeshDataTool::set_vertex_meta);
- ObjectTypeDB::bind_method(_MD("get_vertex_meta","idx"),&MeshDataTool::get_vertex_meta);
+ ClassDB::bind_method(_MD("set_vertex_meta","idx","meta"),&MeshDataTool::set_vertex_meta);
+ ClassDB::bind_method(_MD("get_vertex_meta","idx"),&MeshDataTool::get_vertex_meta);
- ObjectTypeDB::bind_method(_MD("get_vertex_edges","idx"),&MeshDataTool::get_vertex_edges);
- ObjectTypeDB::bind_method(_MD("get_vertex_faces","idx"),&MeshDataTool::get_vertex_faces);
+ ClassDB::bind_method(_MD("get_vertex_edges","idx"),&MeshDataTool::get_vertex_edges);
+ ClassDB::bind_method(_MD("get_vertex_faces","idx"),&MeshDataTool::get_vertex_faces);
- ObjectTypeDB::bind_method(_MD("get_edge_vertex","idx","vertex"),&MeshDataTool::get_edge_vertex);
- ObjectTypeDB::bind_method(_MD("get_edge_faces","idx","faces"),&MeshDataTool::get_edge_faces);
+ ClassDB::bind_method(_MD("get_edge_vertex","idx","vertex"),&MeshDataTool::get_edge_vertex);
+ ClassDB::bind_method(_MD("get_edge_faces","idx","faces"),&MeshDataTool::get_edge_faces);
- ObjectTypeDB::bind_method(_MD("set_edge_meta","idx","meta"),&MeshDataTool::set_edge_meta);
- ObjectTypeDB::bind_method(_MD("get_edge_meta","idx"),&MeshDataTool::get_edge_meta);
+ ClassDB::bind_method(_MD("set_edge_meta","idx","meta"),&MeshDataTool::set_edge_meta);
+ ClassDB::bind_method(_MD("get_edge_meta","idx"),&MeshDataTool::get_edge_meta);
- ObjectTypeDB::bind_method(_MD("get_face_vertex","idx","vertex"),&MeshDataTool::get_face_vertex);
- ObjectTypeDB::bind_method(_MD("get_face_edge","idx","edge"),&MeshDataTool::get_face_edge);
+ ClassDB::bind_method(_MD("get_face_vertex","idx","vertex"),&MeshDataTool::get_face_vertex);
+ ClassDB::bind_method(_MD("get_face_edge","idx","edge"),&MeshDataTool::get_face_edge);
- ObjectTypeDB::bind_method(_MD("set_face_meta","idx","meta"),&MeshDataTool::set_face_meta);
- ObjectTypeDB::bind_method(_MD("get_face_meta","idx"),&MeshDataTool::get_face_meta);
+ ClassDB::bind_method(_MD("set_face_meta","idx","meta"),&MeshDataTool::set_face_meta);
+ ClassDB::bind_method(_MD("get_face_meta","idx"),&MeshDataTool::get_face_meta);
- ObjectTypeDB::bind_method(_MD("get_face_normal","idx"),&MeshDataTool::get_face_normal);
+ ClassDB::bind_method(_MD("get_face_normal","idx"),&MeshDataTool::get_face_normal);
- ObjectTypeDB::bind_method(_MD("set_material","material:Material"),&MeshDataTool::set_material);
- ObjectTypeDB::bind_method(_MD("get_material","material"),&MeshDataTool::get_material);
+ ClassDB::bind_method(_MD("set_material","material:Material"),&MeshDataTool::set_material);
+ ClassDB::bind_method(_MD("get_material","material"),&MeshDataTool::get_material);
}
MeshDataTool::MeshDataTool(){
diff --git a/scene/resources/mesh_data_tool.h b/scene/resources/mesh_data_tool.h
index c0eb4c4b83..fa9c50d2ec 100644
--- a/scene/resources/mesh_data_tool.h
+++ b/scene/resources/mesh_data_tool.h
@@ -33,7 +33,7 @@
class MeshDataTool : public Reference {
- OBJ_TYPE(MeshDataTool,Reference);
+ GDCLASS(MeshDataTool,Reference);
int format;
diff --git a/scene/resources/mesh_library.cpp b/scene/resources/mesh_library.cpp
index 329874767a..cc357c4d9b 100644
--- a/scene/resources/mesh_library.cpp
+++ b/scene/resources/mesh_library.cpp
@@ -244,19 +244,19 @@ int MeshLibrary::get_last_unused_item_id() const {
void MeshLibrary::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("create_item","id"),&MeshLibrary::create_item);
- ObjectTypeDB::bind_method(_MD("set_item_name","id","name"),&MeshLibrary::set_item_name);
- ObjectTypeDB::bind_method(_MD("set_item_mesh","id","mesh:Mesh"),&MeshLibrary::set_item_mesh);
- ObjectTypeDB::bind_method(_MD("set_item_navmesh","id","navmesh:NavigationMesh"),&MeshLibrary::set_item_navmesh);
- ObjectTypeDB::bind_method(_MD("set_item_shape","id","shape:Shape"),&MeshLibrary::set_item_shape);
- ObjectTypeDB::bind_method(_MD("get_item_name","id"),&MeshLibrary::get_item_name);
- ObjectTypeDB::bind_method(_MD("get_item_mesh:Mesh","id"),&MeshLibrary::get_item_mesh);
- ObjectTypeDB::bind_method(_MD("get_item_navmesh:NavigationMesh","id"),&MeshLibrary::get_item_navmesh);
- ObjectTypeDB::bind_method(_MD("get_item_shape:Shape","id"),&MeshLibrary::get_item_shape);
- ObjectTypeDB::bind_method(_MD("remove_item","id"),&MeshLibrary::remove_item);
- ObjectTypeDB::bind_method(_MD("clear"),&MeshLibrary::clear);
- ObjectTypeDB::bind_method(_MD("get_item_list"),&MeshLibrary::get_item_list);
- ObjectTypeDB::bind_method(_MD("get_last_unused_item_id"),&MeshLibrary::get_last_unused_item_id);
+ ClassDB::bind_method(_MD("create_item","id"),&MeshLibrary::create_item);
+ ClassDB::bind_method(_MD("set_item_name","id","name"),&MeshLibrary::set_item_name);
+ ClassDB::bind_method(_MD("set_item_mesh","id","mesh:Mesh"),&MeshLibrary::set_item_mesh);
+ ClassDB::bind_method(_MD("set_item_navmesh","id","navmesh:NavigationMesh"),&MeshLibrary::set_item_navmesh);
+ ClassDB::bind_method(_MD("set_item_shape","id","shape:Shape"),&MeshLibrary::set_item_shape);
+ ClassDB::bind_method(_MD("get_item_name","id"),&MeshLibrary::get_item_name);
+ ClassDB::bind_method(_MD("get_item_mesh:Mesh","id"),&MeshLibrary::get_item_mesh);
+ ClassDB::bind_method(_MD("get_item_navmesh:NavigationMesh","id"),&MeshLibrary::get_item_navmesh);
+ ClassDB::bind_method(_MD("get_item_shape:Shape","id"),&MeshLibrary::get_item_shape);
+ ClassDB::bind_method(_MD("remove_item","id"),&MeshLibrary::remove_item);
+ ClassDB::bind_method(_MD("clear"),&MeshLibrary::clear);
+ ClassDB::bind_method(_MD("get_item_list"),&MeshLibrary::get_item_list);
+ ClassDB::bind_method(_MD("get_last_unused_item_id"),&MeshLibrary::get_last_unused_item_id);
}
MeshLibrary::MeshLibrary() {
diff --git a/scene/resources/mesh_library.h b/scene/resources/mesh_library.h
index 66b688ab22..bb8012d3ff 100644
--- a/scene/resources/mesh_library.h
+++ b/scene/resources/mesh_library.h
@@ -37,7 +37,7 @@
class MeshLibrary : public Resource {
- OBJ_TYPE(MeshLibrary,Resource);
+ GDCLASS(MeshLibrary,Resource);
RES_BASE_EXTENSION("gt");
struct Item {
diff --git a/scene/resources/multimesh.cpp b/scene/resources/multimesh.cpp
index b96ad155c0..802f58e8ca 100644
--- a/scene/resources/multimesh.cpp
+++ b/scene/resources/multimesh.cpp
@@ -211,26 +211,26 @@ MultiMesh::TransformFormat MultiMesh::get_transform_format() const{
void MultiMesh::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_mesh","mesh:Mesh"),&MultiMesh::set_mesh);
- ObjectTypeDB::bind_method(_MD("get_mesh:Mesh"),&MultiMesh::get_mesh);
- ObjectTypeDB::bind_method(_MD("set_color_format","format"),&MultiMesh::set_color_format);
- ObjectTypeDB::bind_method(_MD("get_color_format"),&MultiMesh::get_color_format);
- ObjectTypeDB::bind_method(_MD("set_transform_format","format"),&MultiMesh::set_transform_format);
- ObjectTypeDB::bind_method(_MD("get_transform_format"),&MultiMesh::get_transform_format);
-
- ObjectTypeDB::bind_method(_MD("set_instance_count","count"),&MultiMesh::set_instance_count);
- ObjectTypeDB::bind_method(_MD("get_instance_count"),&MultiMesh::get_instance_count);
- ObjectTypeDB::bind_method(_MD("set_instance_transform","instance","transform"),&MultiMesh::set_instance_transform);
- ObjectTypeDB::bind_method(_MD("get_instance_transform","instance"),&MultiMesh::get_instance_transform);
- ObjectTypeDB::bind_method(_MD("set_instance_color","instance","color"),&MultiMesh::set_instance_color);
- ObjectTypeDB::bind_method(_MD("get_instance_color","instance"),&MultiMesh::get_instance_color);
- ObjectTypeDB::bind_method(_MD("get_aabb"),&MultiMesh::get_aabb);
-
-
- ObjectTypeDB::bind_method(_MD("_set_transform_array"),&MultiMesh::_set_transform_array);
- ObjectTypeDB::bind_method(_MD("_get_transform_array"),&MultiMesh::_get_transform_array);
- ObjectTypeDB::bind_method(_MD("_set_color_array"),&MultiMesh::_set_color_array);
- ObjectTypeDB::bind_method(_MD("_get_color_array"),&MultiMesh::_get_color_array);
+ ClassDB::bind_method(_MD("set_mesh","mesh:Mesh"),&MultiMesh::set_mesh);
+ ClassDB::bind_method(_MD("get_mesh:Mesh"),&MultiMesh::get_mesh);
+ ClassDB::bind_method(_MD("set_color_format","format"),&MultiMesh::set_color_format);
+ ClassDB::bind_method(_MD("get_color_format"),&MultiMesh::get_color_format);
+ ClassDB::bind_method(_MD("set_transform_format","format"),&MultiMesh::set_transform_format);
+ ClassDB::bind_method(_MD("get_transform_format"),&MultiMesh::get_transform_format);
+
+ ClassDB::bind_method(_MD("set_instance_count","count"),&MultiMesh::set_instance_count);
+ ClassDB::bind_method(_MD("get_instance_count"),&MultiMesh::get_instance_count);
+ ClassDB::bind_method(_MD("set_instance_transform","instance","transform"),&MultiMesh::set_instance_transform);
+ ClassDB::bind_method(_MD("get_instance_transform","instance"),&MultiMesh::get_instance_transform);
+ ClassDB::bind_method(_MD("set_instance_color","instance","color"),&MultiMesh::set_instance_color);
+ ClassDB::bind_method(_MD("get_instance_color","instance"),&MultiMesh::get_instance_color);
+ ClassDB::bind_method(_MD("get_aabb"),&MultiMesh::get_aabb);
+
+
+ ClassDB::bind_method(_MD("_set_transform_array"),&MultiMesh::_set_transform_array);
+ ClassDB::bind_method(_MD("_get_transform_array"),&MultiMesh::_get_transform_array);
+ ClassDB::bind_method(_MD("_set_color_array"),&MultiMesh::_set_color_array);
+ ClassDB::bind_method(_MD("_get_color_array"),&MultiMesh::_get_color_array);
ADD_PROPERTY(PropertyInfo(Variant::INT,"color_format",PROPERTY_HINT_ENUM,"None,Byte,Float"), _SCS("set_color_format"), _SCS("get_color_format"));
diff --git a/scene/resources/multimesh.h b/scene/resources/multimesh.h
index 85c8718aa7..ab2ef59214 100644
--- a/scene/resources/multimesh.h
+++ b/scene/resources/multimesh.h
@@ -34,7 +34,7 @@
class MultiMesh : public Resource {
- OBJ_TYPE( MultiMesh, Resource );
+ GDCLASS( MultiMesh, Resource );
RES_BASE_EXTENSION("mmsh");
public:
diff --git a/scene/resources/packed_scene.cpp b/scene/resources/packed_scene.cpp
index 83b61af8fc..7d86513c51 100644
--- a/scene/resources/packed_scene.cpp
+++ b/scene/resources/packed_scene.cpp
@@ -148,10 +148,10 @@ Node *SceneState::instance(bool p_gen_edit_state) const {
}
#endif
}
- } else if (ObjectTypeDB::is_type_enabled(snames[n.type])) {
+ } else if (ClassDB::is_class_enabled(snames[n.type])) {
//print_line("created");
//node belongs to this scene and must be created
- Object * obj = ObjectTypeDB::instance(snames[ n.type ]);
+ Object * obj = ClassDB::instance(snames[ n.type ]);
if (!obj || !obj->cast_to<Node>()) {
if (obj) {
memdelete(obj);
@@ -639,7 +639,7 @@ Error SceneState::_parse_node(Node *p_owner,Node *p_node,int p_parent_idx, Map<S
// then flag that the node should not be created but reused
if (pack_state_stack.empty()) {
//this node is not part of an instancing process, so save the type
- nd.type=_nm_get_string(p_node->get_type(),name_map);
+ nd.type=_nm_get_string(p_node->get_class(),name_map);
} else {
// this node is part of an instanced process, so do not save the type.
// instead, save that it was instanced
@@ -1674,25 +1674,25 @@ void SceneState::_bind_methods() {
//unbuild API
- ObjectTypeDB::bind_method(_MD("get_node_count"),&SceneState::get_node_count);
- ObjectTypeDB::bind_method(_MD("get_node_type","idx"),&SceneState::get_node_type);
- ObjectTypeDB::bind_method(_MD("get_node_name","idx"),&SceneState::get_node_name);
- ObjectTypeDB::bind_method(_MD("get_node_path","idx","for_parent"),&SceneState::get_node_path,DEFVAL(false));
- ObjectTypeDB::bind_method(_MD("get_node_owner_path","idx"),&SceneState::get_node_owner_path);
- ObjectTypeDB::bind_method(_MD("is_node_instance_placeholder","idx"),&SceneState::is_node_instance_placeholder);
- ObjectTypeDB::bind_method(_MD("get_node_instance_placeholder","idx"),&SceneState::get_node_instance_placeholder);
- ObjectTypeDB::bind_method(_MD("get_node_instance:PackedScene","idx"),&SceneState::get_node_instance);
- ObjectTypeDB::bind_method(_MD("get_node_groups","idx"),&SceneState::_get_node_groups);
- ObjectTypeDB::bind_method(_MD("get_node_property_count","idx"),&SceneState::get_node_property_count);
- ObjectTypeDB::bind_method(_MD("get_node_property_name","idx","prop_idx"),&SceneState::get_node_property_name);
- ObjectTypeDB::bind_method(_MD("get_node_property_value","idx","prop_idx"),&SceneState::get_node_property_value);
- ObjectTypeDB::bind_method(_MD("get_connection_count"),&SceneState::get_connection_count);
- ObjectTypeDB::bind_method(_MD("get_connection_source","idx"),&SceneState::get_connection_source);
- ObjectTypeDB::bind_method(_MD("get_connection_signal","idx"),&SceneState::get_connection_signal);
- ObjectTypeDB::bind_method(_MD("get_connection_target","idx"),&SceneState::get_connection_target);
- ObjectTypeDB::bind_method(_MD("get_connection_method","idx"),&SceneState::get_connection_method);
- ObjectTypeDB::bind_method(_MD("get_connection_flags","idx"),&SceneState::get_connection_flags);
- ObjectTypeDB::bind_method(_MD("get_connection_binds","idx"),&SceneState::get_connection_binds);
+ ClassDB::bind_method(_MD("get_node_count"),&SceneState::get_node_count);
+ ClassDB::bind_method(_MD("get_node_type","idx"),&SceneState::get_node_type);
+ ClassDB::bind_method(_MD("get_node_name","idx"),&SceneState::get_node_name);
+ ClassDB::bind_method(_MD("get_node_path","idx","for_parent"),&SceneState::get_node_path,DEFVAL(false));
+ ClassDB::bind_method(_MD("get_node_owner_path","idx"),&SceneState::get_node_owner_path);
+ ClassDB::bind_method(_MD("is_node_instance_placeholder","idx"),&SceneState::is_node_instance_placeholder);
+ ClassDB::bind_method(_MD("get_node_instance_placeholder","idx"),&SceneState::get_node_instance_placeholder);
+ ClassDB::bind_method(_MD("get_node_instance:PackedScene","idx"),&SceneState::get_node_instance);
+ ClassDB::bind_method(_MD("get_node_groups","idx"),&SceneState::_get_node_groups);
+ ClassDB::bind_method(_MD("get_node_property_count","idx"),&SceneState::get_node_property_count);
+ ClassDB::bind_method(_MD("get_node_property_name","idx","prop_idx"),&SceneState::get_node_property_name);
+ ClassDB::bind_method(_MD("get_node_property_value","idx","prop_idx"),&SceneState::get_node_property_value);
+ ClassDB::bind_method(_MD("get_connection_count"),&SceneState::get_connection_count);
+ ClassDB::bind_method(_MD("get_connection_source","idx"),&SceneState::get_connection_source);
+ ClassDB::bind_method(_MD("get_connection_signal","idx"),&SceneState::get_connection_signal);
+ ClassDB::bind_method(_MD("get_connection_target","idx"),&SceneState::get_connection_target);
+ ClassDB::bind_method(_MD("get_connection_method","idx"),&SceneState::get_connection_method);
+ ClassDB::bind_method(_MD("get_connection_flags","idx"),&SceneState::get_connection_flags);
+ ClassDB::bind_method(_MD("get_connection_binds","idx"),&SceneState::get_connection_binds);
}
SceneState::SceneState() {
@@ -1791,12 +1791,12 @@ void PackedScene::set_path(const String& p_path,bool p_take_over) {
void PackedScene::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("pack","path:Node"),&PackedScene::pack);
- ObjectTypeDB::bind_method(_MD("instance:Node","gen_edit_state"),&PackedScene::instance,DEFVAL(false));
- ObjectTypeDB::bind_method(_MD("can_instance"),&PackedScene::can_instance);
- ObjectTypeDB::bind_method(_MD("_set_bundled_scene"),&PackedScene::_set_bundled_scene);
- ObjectTypeDB::bind_method(_MD("_get_bundled_scene"),&PackedScene::_get_bundled_scene);
- ObjectTypeDB::bind_method(_MD("get_state:SceneState"),&PackedScene::get_state);
+ ClassDB::bind_method(_MD("pack","path:Node"),&PackedScene::pack);
+ ClassDB::bind_method(_MD("instance:Node","gen_edit_state"),&PackedScene::instance,DEFVAL(false));
+ ClassDB::bind_method(_MD("can_instance"),&PackedScene::can_instance);
+ ClassDB::bind_method(_MD("_set_bundled_scene"),&PackedScene::_set_bundled_scene);
+ ClassDB::bind_method(_MD("_get_bundled_scene"),&PackedScene::_get_bundled_scene);
+ ClassDB::bind_method(_MD("get_state:SceneState"),&PackedScene::get_state);
ADD_PROPERTY( PropertyInfo(Variant::DICTIONARY,"_bundled"),_SCS("_set_bundled_scene"),_SCS("_get_bundled_scene"));
diff --git a/scene/resources/packed_scene.h b/scene/resources/packed_scene.h
index 186324edbe..2eda624dc3 100644
--- a/scene/resources/packed_scene.h
+++ b/scene/resources/packed_scene.h
@@ -35,7 +35,7 @@
class SceneState : public Reference {
- OBJ_TYPE( SceneState, Reference );
+ GDCLASS( SceneState, Reference );
Vector<StringName> names;
@@ -189,7 +189,7 @@ public:
class PackedScene : public Resource {
- OBJ_TYPE(PackedScene, Resource );
+ GDCLASS(PackedScene, Resource );
RES_BASE_EXTENSION("scn");
Ref<SceneState> state;
diff --git a/scene/resources/plane_shape.cpp b/scene/resources/plane_shape.cpp
index c739d24da8..1814eea66c 100644
--- a/scene/resources/plane_shape.cpp
+++ b/scene/resources/plane_shape.cpp
@@ -80,8 +80,8 @@ Plane PlaneShape::get_plane() const {
void PlaneShape::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_plane","plane"),&PlaneShape::set_plane);
- ObjectTypeDB::bind_method(_MD("get_plane"),&PlaneShape::get_plane);
+ ClassDB::bind_method(_MD("set_plane","plane"),&PlaneShape::set_plane);
+ ClassDB::bind_method(_MD("get_plane"),&PlaneShape::get_plane);
ADD_PROPERTY( PropertyInfo(Variant::PLANE,"plane"), _SCS("set_plane"), _SCS("get_plane") );
diff --git a/scene/resources/plane_shape.h b/scene/resources/plane_shape.h
index d911ce78af..88f3a04f05 100644
--- a/scene/resources/plane_shape.h
+++ b/scene/resources/plane_shape.h
@@ -33,7 +33,7 @@
class PlaneShape : public Shape {
- OBJ_TYPE(PlaneShape,Shape);
+ GDCLASS(PlaneShape,Shape);
Plane plane;
protected:
diff --git a/scene/resources/polygon_path_finder.cpp b/scene/resources/polygon_path_finder.cpp
index a4afe160f4..3dc3e6005a 100644
--- a/scene/resources/polygon_path_finder.cpp
+++ b/scene/resources/polygon_path_finder.cpp
@@ -618,17 +618,17 @@ float PolygonPathFinder::get_point_penalty(int p_point) const {
void PolygonPathFinder::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("setup","points","connections"),&PolygonPathFinder::setup);
- ObjectTypeDB::bind_method(_MD("find_path","from","to"),&PolygonPathFinder::find_path);
- ObjectTypeDB::bind_method(_MD("get_intersections","from","to"),&PolygonPathFinder::get_intersections);
- ObjectTypeDB::bind_method(_MD("get_closest_point","point"),&PolygonPathFinder::get_closest_point);
- ObjectTypeDB::bind_method(_MD("is_point_inside","point"),&PolygonPathFinder::is_point_inside);
- ObjectTypeDB::bind_method(_MD("set_point_penalty","idx","penalty"),&PolygonPathFinder::set_point_penalty);
- ObjectTypeDB::bind_method(_MD("get_point_penalty","idx"),&PolygonPathFinder::get_point_penalty);
-
- ObjectTypeDB::bind_method(_MD("get_bounds"),&PolygonPathFinder::get_bounds);
- ObjectTypeDB::bind_method(_MD("_set_data"),&PolygonPathFinder::_set_data);
- ObjectTypeDB::bind_method(_MD("_get_data"),&PolygonPathFinder::_get_data);
+ ClassDB::bind_method(_MD("setup","points","connections"),&PolygonPathFinder::setup);
+ ClassDB::bind_method(_MD("find_path","from","to"),&PolygonPathFinder::find_path);
+ ClassDB::bind_method(_MD("get_intersections","from","to"),&PolygonPathFinder::get_intersections);
+ ClassDB::bind_method(_MD("get_closest_point","point"),&PolygonPathFinder::get_closest_point);
+ ClassDB::bind_method(_MD("is_point_inside","point"),&PolygonPathFinder::is_point_inside);
+ ClassDB::bind_method(_MD("set_point_penalty","idx","penalty"),&PolygonPathFinder::set_point_penalty);
+ ClassDB::bind_method(_MD("get_point_penalty","idx"),&PolygonPathFinder::get_point_penalty);
+
+ ClassDB::bind_method(_MD("get_bounds"),&PolygonPathFinder::get_bounds);
+ ClassDB::bind_method(_MD("_set_data"),&PolygonPathFinder::_set_data);
+ ClassDB::bind_method(_MD("_get_data"),&PolygonPathFinder::_get_data);
ADD_PROPERTY(PropertyInfo(Variant::DICTIONARY,"data",PROPERTY_HINT_NONE,"",PROPERTY_USAGE_NOEDITOR),_SCS("_set_data"),_SCS("_get_data"));
diff --git a/scene/resources/polygon_path_finder.h b/scene/resources/polygon_path_finder.h
index 2459704ac2..58b8023843 100644
--- a/scene/resources/polygon_path_finder.h
+++ b/scene/resources/polygon_path_finder.h
@@ -33,7 +33,7 @@
class PolygonPathFinder : public Resource {
- OBJ_TYPE(PolygonPathFinder,Resource);
+ GDCLASS(PolygonPathFinder,Resource);
struct Point {
Vector2 pos;
diff --git a/scene/resources/ray_shape.cpp b/scene/resources/ray_shape.cpp
index cbf9c2c179..226062bed3 100644
--- a/scene/resources/ray_shape.cpp
+++ b/scene/resources/ray_shape.cpp
@@ -60,8 +60,8 @@ float RayShape::get_length() const {
void RayShape::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_length","length"),&RayShape::set_length);
- ObjectTypeDB::bind_method(_MD("get_length"),&RayShape::get_length);
+ ClassDB::bind_method(_MD("set_length","length"),&RayShape::set_length);
+ ClassDB::bind_method(_MD("get_length"),&RayShape::get_length);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"length",PROPERTY_HINT_RANGE,"0,4096,0.01"), _SCS("set_length"), _SCS("get_length") );
diff --git a/scene/resources/ray_shape.h b/scene/resources/ray_shape.h
index ee56adde73..9ee59d5f91 100644
--- a/scene/resources/ray_shape.h
+++ b/scene/resources/ray_shape.h
@@ -32,7 +32,7 @@
class RayShape : public Shape {
- OBJ_TYPE(RayShape,Shape);
+ GDCLASS(RayShape,Shape);
float length;
protected:
diff --git a/scene/resources/rectangle_shape_2d.cpp b/scene/resources/rectangle_shape_2d.cpp
index 04a26bc54d..3272125b33 100644
--- a/scene/resources/rectangle_shape_2d.cpp
+++ b/scene/resources/rectangle_shape_2d.cpp
@@ -64,8 +64,8 @@ Rect2 RectangleShape2D::get_rect() const {
void RectangleShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_extents","extents"),&RectangleShape2D::set_extents);
- ObjectTypeDB::bind_method(_MD("get_extents"),&RectangleShape2D::get_extents);
+ ClassDB::bind_method(_MD("set_extents","extents"),&RectangleShape2D::set_extents);
+ ClassDB::bind_method(_MD("get_extents"),&RectangleShape2D::get_extents);
diff --git a/scene/resources/rectangle_shape_2d.h b/scene/resources/rectangle_shape_2d.h
index 2c9ee04e07..6682b67de0 100644
--- a/scene/resources/rectangle_shape_2d.h
+++ b/scene/resources/rectangle_shape_2d.h
@@ -32,7 +32,7 @@
#include "scene/resources/shape_2d.h"
class RectangleShape2D : public Shape2D {
- OBJ_TYPE( RectangleShape2D, Shape2D );
+ GDCLASS( RectangleShape2D, Shape2D );
Vector2 extents;
void _update_shape();
diff --git a/scene/resources/room.cpp b/scene/resources/room.cpp
index dd833a3f2a..c4d11b94d1 100644
--- a/scene/resources/room.cpp
+++ b/scene/resources/room.cpp
@@ -52,8 +52,8 @@ DVector<Face3> RoomBounds::get_geometry_hint() const {
void RoomBounds::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_geometry_hint","triangles"),&RoomBounds::set_geometry_hint);
- ObjectTypeDB::bind_method(_MD("get_geometry_hint"),&RoomBounds::get_geometry_hint);
+ ClassDB::bind_method(_MD("set_geometry_hint","triangles"),&RoomBounds::set_geometry_hint);
+ ClassDB::bind_method(_MD("get_geometry_hint"),&RoomBounds::get_geometry_hint);
//ADD_PROPERTY( PropertyInfo( Variant::DICTIONARY, "bounds"), _SCS("set_bounds"),_SCS("get_bounds") );
ADD_PROPERTY( PropertyInfo( Variant::VECTOR3_ARRAY, "geometry_hint"),_SCS("set_geometry_hint"),_SCS("get_geometry_hint") );
diff --git a/scene/resources/room.h b/scene/resources/room.h
index 6ecd7e846d..6a8deac8b3 100644
--- a/scene/resources/room.h
+++ b/scene/resources/room.h
@@ -37,7 +37,7 @@
class RoomBounds : public Resource {
- OBJ_TYPE( RoomBounds, Resource );
+ GDCLASS( RoomBounds, Resource );
RES_BASE_EXTENSION("room");
RID area;
diff --git a/scene/resources/sample.cpp b/scene/resources/sample.cpp
index 995dc42901..8ea02ac943 100644
--- a/scene/resources/sample.cpp
+++ b/scene/resources/sample.cpp
@@ -192,23 +192,23 @@ RID Sample::get_rid() const {
void Sample::_bind_methods(){
- ObjectTypeDB::bind_method(_MD("create","format","stereo","length"),&Sample::create);
- ObjectTypeDB::bind_method(_MD("get_format"),&Sample::get_format);
- ObjectTypeDB::bind_method(_MD("is_stereo"),&Sample::is_stereo);
- ObjectTypeDB::bind_method(_MD("get_length"),&Sample::get_length);
- ObjectTypeDB::bind_method(_MD("set_data","data"),&Sample::set_data);
- ObjectTypeDB::bind_method(_MD("get_data"),&Sample::get_data);
- ObjectTypeDB::bind_method(_MD("set_mix_rate","hz"),&Sample::set_mix_rate);
- ObjectTypeDB::bind_method(_MD("get_mix_rate"),&Sample::get_mix_rate);
- ObjectTypeDB::bind_method(_MD("set_loop_format","format"),&Sample::set_loop_format);
- ObjectTypeDB::bind_method(_MD("get_loop_format"),&Sample::get_loop_format);
- ObjectTypeDB::bind_method(_MD("set_loop_begin","pos"),&Sample::set_loop_begin);
- ObjectTypeDB::bind_method(_MD("get_loop_begin"),&Sample::get_loop_begin);
- ObjectTypeDB::bind_method(_MD("set_loop_end","pos"),&Sample::set_loop_end);
- ObjectTypeDB::bind_method(_MD("get_loop_end"),&Sample::get_loop_end);
-
- ObjectTypeDB::bind_method(_MD("_set_data"),&Sample::_set_data);
- ObjectTypeDB::bind_method(_MD("_get_data"),&Sample::_get_data);
+ ClassDB::bind_method(_MD("create","format","stereo","length"),&Sample::create);
+ ClassDB::bind_method(_MD("get_format"),&Sample::get_format);
+ ClassDB::bind_method(_MD("is_stereo"),&Sample::is_stereo);
+ ClassDB::bind_method(_MD("get_length"),&Sample::get_length);
+ ClassDB::bind_method(_MD("set_data","data"),&Sample::set_data);
+ ClassDB::bind_method(_MD("get_data"),&Sample::get_data);
+ ClassDB::bind_method(_MD("set_mix_rate","hz"),&Sample::set_mix_rate);
+ ClassDB::bind_method(_MD("get_mix_rate"),&Sample::get_mix_rate);
+ ClassDB::bind_method(_MD("set_loop_format","format"),&Sample::set_loop_format);
+ ClassDB::bind_method(_MD("get_loop_format"),&Sample::get_loop_format);
+ ClassDB::bind_method(_MD("set_loop_begin","pos"),&Sample::set_loop_begin);
+ ClassDB::bind_method(_MD("get_loop_begin"),&Sample::get_loop_begin);
+ ClassDB::bind_method(_MD("set_loop_end","pos"),&Sample::set_loop_end);
+ ClassDB::bind_method(_MD("get_loop_end"),&Sample::get_loop_end);
+
+ ClassDB::bind_method(_MD("_set_data"),&Sample::_set_data);
+ ClassDB::bind_method(_MD("_get_data"),&Sample::_get_data);
ADD_PROPERTY( PropertyInfo( Variant::DICTIONARY, "data", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), _SCS("_set_data"), _SCS("_get_data") );
ADD_PROPERTY( PropertyInfo( Variant::BOOL, "stereo"), _SCS(""), _SCS("is_stereo") );
diff --git a/scene/resources/sample.h b/scene/resources/sample.h
index a59c52fd96..c011f63144 100644
--- a/scene/resources/sample.h
+++ b/scene/resources/sample.h
@@ -34,7 +34,7 @@
class Sample : public Resource {
- OBJ_TYPE(Sample, Resource );
+ GDCLASS(Sample, Resource );
RES_BASE_EXTENSION("smp");
public:
diff --git a/scene/resources/sample_library.cpp b/scene/resources/sample_library.cpp
index 7de646b6e8..44895df8fa 100644
--- a/scene/resources/sample_library.cpp
+++ b/scene/resources/sample_library.cpp
@@ -194,18 +194,18 @@ Array SampleLibrary::_get_sample_list() const {
void SampleLibrary::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("add_sample","name","sample:Sample"),&SampleLibrary::add_sample );
- ObjectTypeDB::bind_method(_MD("get_sample:Sample","name"),&SampleLibrary::get_sample );
- ObjectTypeDB::bind_method(_MD("has_sample","name"),&SampleLibrary::has_sample );
- ObjectTypeDB::bind_method(_MD("remove_sample","name"),&SampleLibrary::remove_sample );
+ ClassDB::bind_method(_MD("add_sample","name","sample:Sample"),&SampleLibrary::add_sample );
+ ClassDB::bind_method(_MD("get_sample:Sample","name"),&SampleLibrary::get_sample );
+ ClassDB::bind_method(_MD("has_sample","name"),&SampleLibrary::has_sample );
+ ClassDB::bind_method(_MD("remove_sample","name"),&SampleLibrary::remove_sample );
- ObjectTypeDB::bind_method(_MD("get_sample_list"),&SampleLibrary::_get_sample_list );
+ ClassDB::bind_method(_MD("get_sample_list"),&SampleLibrary::_get_sample_list );
- ObjectTypeDB::bind_method(_MD("sample_set_volume_db","name","db"),&SampleLibrary::sample_set_volume_db );
- ObjectTypeDB::bind_method(_MD("sample_get_volume_db","name"),&SampleLibrary::sample_get_volume_db );
+ ClassDB::bind_method(_MD("sample_set_volume_db","name","db"),&SampleLibrary::sample_set_volume_db );
+ ClassDB::bind_method(_MD("sample_get_volume_db","name"),&SampleLibrary::sample_get_volume_db );
- ObjectTypeDB::bind_method(_MD("sample_set_pitch_scale","name","pitch"),&SampleLibrary::sample_set_pitch_scale );
- ObjectTypeDB::bind_method(_MD("sample_get_pitch_scale","name"),&SampleLibrary::sample_get_pitch_scale );
+ ClassDB::bind_method(_MD("sample_set_pitch_scale","name","pitch"),&SampleLibrary::sample_set_pitch_scale );
+ ClassDB::bind_method(_MD("sample_get_pitch_scale","name"),&SampleLibrary::sample_get_pitch_scale );
}
diff --git a/scene/resources/sample_library.h b/scene/resources/sample_library.h
index 0cb6186fd5..d09eea64c5 100644
--- a/scene/resources/sample_library.h
+++ b/scene/resources/sample_library.h
@@ -35,7 +35,7 @@
class SampleLibrary : public Resource {
- OBJ_TYPE(SampleLibrary,Resource);
+ GDCLASS(SampleLibrary,Resource);
struct SampleData {
diff --git a/scene/resources/scene_format_text.cpp b/scene/resources/scene_format_text.cpp
index 799c31e46e..8bbc6ff32b 100644
--- a/scene/resources/scene_format_text.cpp
+++ b/scene/resources/scene_format_text.cpp
@@ -240,7 +240,7 @@ Error ResourceInteractiveLoaderText::poll() {
if ( !ResourceCache::has(path)) { //only if it doesn't exist
- Object *obj = ObjectTypeDB::instance(type);
+ Object *obj = ClassDB::instance(type);
if (!obj) {
error_text+="Can't create sub resource of type: "+type;
@@ -310,7 +310,7 @@ Error ResourceInteractiveLoaderText::poll() {
return error;
}
- Object *obj = ObjectTypeDB::instance(res_type);
+ Object *obj = ClassDB::instance(res_type);
if (!obj) {
error_text+="Can't create sub resource of type: "+res_type;
@@ -1206,7 +1206,7 @@ Error ResourceFormatSaverTextInstance::save(const String &p_path,const RES& p_re
{
String title=packed_scene.is_valid()?"[gd_scene ":"[gd_resource ";
if (packed_scene.is_null())
- title+="type=\""+p_resource->get_type()+"\" ";
+ title+="type=\""+p_resource->get_class()+"\" ";
int load_steps=saved_resources.size()+external_resources.size();
//if (packed_scene.is_valid()) {
// load_steps+=packed_scene->get_node_count();
@@ -1235,7 +1235,7 @@ Error ResourceFormatSaverTextInstance::save(const String &p_path,const RES& p_re
for(int i=0;i<sorted_er.size();i++) {
String p = sorted_er[i]->get_path();
- f->store_string("[ext_resource path=\""+p+"\" type=\""+sorted_er[i]->get_save_type()+"\" id="+itos(i+1)+"]\n"); //bundled
+ f->store_string("[ext_resource path=\""+p+"\" type=\""+sorted_er[i]->get_save_class()+"\" id="+itos(i+1)+"]\n"); //bundled
}
if (external_resources.size())
@@ -1282,7 +1282,7 @@ Error ResourceFormatSaverTextInstance::save(const String &p_path,const RES& p_re
}
int idx = res->get_subindex();
- line+="type=\""+res->get_type()+"\" id="+itos(idx);
+ line+="type=\""+res->get_class()+"\" id="+itos(idx);
f->store_line(line+"]\n");
if (takeover_paths) {
res->set_path(p_path+"::"+itos(idx),true);
@@ -1451,7 +1451,7 @@ Error ResourceFormatSaverTextInstance::save(const String &p_path,const RES& p_re
Error ResourceFormatSaverText::save(const String &p_path,const RES& p_resource,uint32_t p_flags) {
- if (p_path.ends_with(".sct") && p_resource->get_type()!="PackedScene") {
+ if (p_path.ends_with(".sct") && p_resource->get_class()!="PackedScene") {
return ERR_FILE_UNRECOGNIZED;
}
@@ -1467,7 +1467,7 @@ bool ResourceFormatSaverText::recognize(const RES& p_resource) const {
}
void ResourceFormatSaverText::get_recognized_extensions(const RES& p_resource,List<String> *p_extensions) const {
- if (p_resource->get_type()=="PackedScene")
+ if (p_resource->get_class()=="PackedScene")
p_extensions->push_back("tscn"); //text scene
else
p_extensions->push_back("tres"); //text resource
diff --git a/scene/resources/scene_preloader.cpp b/scene/resources/scene_preloader.cpp
index 6fa4e059e1..575c188009 100644
--- a/scene/resources/scene_preloader.cpp
+++ b/scene/resources/scene_preloader.cpp
@@ -60,12 +60,12 @@ Node *ScenePreloader::instance() const {
const NodeData &n=nd[i];
- if (!ObjectTypeDB::is_type_enabled(snames[n.type])) {
+ if (!ClassDB::is_class_enabled(snames[n.type])) {
ret_nodes[i]=NULL;
continue;
}
- Object * obj = ObjectTypeDB::instance(snames[ n.type ]);
+ Object * obj = ClassDB::instance(snames[ n.type ]);
ERR_FAIL_COND_V(!obj,NULL);
Node *node = obj->cast_to<Node>();
ERR_FAIL_COND_V(!node,NULL);
@@ -149,7 +149,7 @@ void ScenePreloader::_parse_node(Node *p_owner,Node *p_node,int p_parent_idx, Ma
NodeData nd;
nd.name=_nm_get_string(p_node->get_name(),name_map);
- nd.type=_nm_get_string(p_node->get_type(),name_map);
+ nd.type=_nm_get_string(p_node->get_class(),name_map);
nd.parent=p_parent_idx;
List<PropertyInfo> plist;
@@ -423,12 +423,12 @@ Dictionary ScenePreloader::_get_bundled_scene() const {
void ScenePreloader::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("load_scene","path"),&ScenePreloader::load_scene);
- ObjectTypeDB::bind_method(_MD("get_scene_path"),&ScenePreloader::get_scene_path);
- ObjectTypeDB::bind_method(_MD("instance:Node"),&ScenePreloader::instance);
- ObjectTypeDB::bind_method(_MD("can_instance"),&ScenePreloader::can_instance);
- ObjectTypeDB::bind_method(_MD("_set_bundled_scene"),&ScenePreloader::_set_bundled_scene);
- ObjectTypeDB::bind_method(_MD("_get_bundled_scene"),&ScenePreloader::_get_bundled_scene);
+ ClassDB::bind_method(_MD("load_scene","path"),&ScenePreloader::load_scene);
+ ClassDB::bind_method(_MD("get_scene_path"),&ScenePreloader::get_scene_path);
+ ClassDB::bind_method(_MD("instance:Node"),&ScenePreloader::instance);
+ ClassDB::bind_method(_MD("can_instance"),&ScenePreloader::can_instance);
+ ClassDB::bind_method(_MD("_set_bundled_scene"),&ScenePreloader::_set_bundled_scene);
+ ClassDB::bind_method(_MD("_get_bundled_scene"),&ScenePreloader::_get_bundled_scene);
ADD_PROPERTY( PropertyInfo(Variant::DICTIONARY,"_bundled",PROPERTY_HINT_NONE,"",PROPERTY_USAGE_BUNDLE),_SCS("_set_bundled_scene"),_SCS("_get_bundled_scene"));
#if 0
diff --git a/scene/resources/scene_preloader.h b/scene/resources/scene_preloader.h
index 6fe975bb7a..315d6be6b1 100644
--- a/scene/resources/scene_preloader.h
+++ b/scene/resources/scene_preloader.h
@@ -34,7 +34,7 @@
class ScenePreloader : public Resource {
- OBJ_TYPE( ScenePreloader, Resource );
+ GDCLASS( ScenePreloader, Resource );
Vector<StringName> names;
Vector<Variant> variants;
diff --git a/scene/resources/segment_shape_2d.cpp b/scene/resources/segment_shape_2d.cpp
index d0ae791905..71d5a8efa8 100644
--- a/scene/resources/segment_shape_2d.cpp
+++ b/scene/resources/segment_shape_2d.cpp
@@ -82,11 +82,11 @@ Rect2 SegmentShape2D::get_rect() const{
void SegmentShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_a","a"),&SegmentShape2D::set_a);
- ObjectTypeDB::bind_method(_MD("get_a"),&SegmentShape2D::get_a);
+ ClassDB::bind_method(_MD("set_a","a"),&SegmentShape2D::set_a);
+ ClassDB::bind_method(_MD("get_a"),&SegmentShape2D::get_a);
- ObjectTypeDB::bind_method(_MD("set_b","b"),&SegmentShape2D::set_b);
- ObjectTypeDB::bind_method(_MD("get_b"),&SegmentShape2D::get_b);
+ ClassDB::bind_method(_MD("set_b","b"),&SegmentShape2D::set_b);
+ ClassDB::bind_method(_MD("get_b"),&SegmentShape2D::get_b);
ADD_PROPERTY( PropertyInfo(Variant::VECTOR2,"a"),_SCS("set_a"),_SCS("get_a") );
@@ -145,8 +145,8 @@ Rect2 RayShape2D::get_rect() const {
void RayShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_length","length"),&RayShape2D::set_length);
- ObjectTypeDB::bind_method(_MD("get_length"),&RayShape2D::get_length);
+ ClassDB::bind_method(_MD("set_length","length"),&RayShape2D::set_length);
+ ClassDB::bind_method(_MD("get_length"),&RayShape2D::get_length);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"length"),_SCS("set_length"),_SCS("get_length") );
diff --git a/scene/resources/segment_shape_2d.h b/scene/resources/segment_shape_2d.h
index 0a9de96f0f..775bdabe9d 100644
--- a/scene/resources/segment_shape_2d.h
+++ b/scene/resources/segment_shape_2d.h
@@ -32,7 +32,7 @@
#include "scene/resources/shape_2d.h"
class SegmentShape2D : public Shape2D {
- OBJ_TYPE( SegmentShape2D, Shape2D );
+ GDCLASS( SegmentShape2D, Shape2D );
Vector2 a;
Vector2 b;
@@ -57,7 +57,7 @@ public:
class RayShape2D : public Shape2D {
- OBJ_TYPE( RayShape2D, Shape2D );
+ GDCLASS( RayShape2D, Shape2D );
real_t length;
diff --git a/scene/resources/shader.cpp b/scene/resources/shader.cpp
index 3ce1a00af4..6afbf32c35 100644
--- a/scene/resources/shader.cpp
+++ b/scene/resources/shader.cpp
@@ -116,17 +116,17 @@ bool Shader::has_param(const StringName& p_param) const {
void Shader::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_mode"),&Shader::get_mode);
+ ClassDB::bind_method(_MD("get_mode"),&Shader::get_mode);
- ObjectTypeDB::bind_method(_MD("set_code","code"),&Shader::set_code);
- ObjectTypeDB::bind_method(_MD("get_code"),&Shader::get_code);
+ ClassDB::bind_method(_MD("set_code","code"),&Shader::set_code);
+ ClassDB::bind_method(_MD("get_code"),&Shader::get_code);
- ObjectTypeDB::bind_method(_MD("set_default_texture_param","param","texture:Texture"),&Shader::set_default_texture_param);
- ObjectTypeDB::bind_method(_MD("get_default_texture_param:Texture","param"),&Shader::get_default_texture_param);
+ ClassDB::bind_method(_MD("set_default_texture_param","param","texture:Texture"),&Shader::set_default_texture_param);
+ ClassDB::bind_method(_MD("get_default_texture_param:Texture","param"),&Shader::get_default_texture_param);
- ObjectTypeDB::bind_method(_MD("has_param","name"),&Shader::has_param);
+ ClassDB::bind_method(_MD("has_param","name"),&Shader::has_param);
- //ObjectTypeDB::bind_method(_MD("get_param_list"),&Shader::get_fragment_code);
+ //ClassDB::bind_method(_MD("get_param_list"),&Shader::get_fragment_code);
ADD_PROPERTY( PropertyInfo(Variant::STRING, "code",PROPERTY_HINT_NONE,"",PROPERTY_USAGE_NOEDITOR), _SCS("set_code"), _SCS("get_code") );
diff --git a/scene/resources/shader.h b/scene/resources/shader.h
index 279cf5b7c9..59d7601d98 100644
--- a/scene/resources/shader.h
+++ b/scene/resources/shader.h
@@ -35,7 +35,7 @@
class Shader : public Resource {
- OBJ_TYPE(Shader,Resource);
+ GDCLASS(Shader,Resource);
OBJ_SAVE_TYPE( Shader );
RES_BASE_EXTENSION("shd");
@@ -102,7 +102,7 @@ VARIANT_ENUM_CAST( Shader::Mode );
class SpatialShader : public Shader {
- OBJ_TYPE(SpatialShader,Shader);
+ GDCLASS(SpatialShader,Shader);
public:
@@ -111,7 +111,7 @@ public:
class CanvasItemShader : public Shader {
- OBJ_TYPE(CanvasItemShader,Shader);
+ GDCLASS(CanvasItemShader,Shader);
public:
@@ -121,7 +121,7 @@ public:
class ParticlesShader : public Shader {
- OBJ_TYPE(ParticlesShader,Shader);
+ GDCLASS(ParticlesShader,Shader);
public:
diff --git a/scene/resources/shader_graph.cpp b/scene/resources/shader_graph.cpp
index f56aa8dbc1..0c31e1406f 100644
--- a/scene/resources/shader_graph.cpp
+++ b/scene/resources/shader_graph.cpp
@@ -165,106 +165,106 @@ int ShaderGraph::node_count(ShaderType p_which, int p_type)
void ShaderGraph::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("_update_shader"),&ShaderGraph::_update_shader);
+ ClassDB::bind_method(_MD("_update_shader"),&ShaderGraph::_update_shader);
- ObjectTypeDB::bind_method(_MD("node_add","shader_type","node_type","id"),&ShaderGraph::node_add);
- ObjectTypeDB::bind_method(_MD("node_remove","shader_type","id"),&ShaderGraph::node_remove);
- ObjectTypeDB::bind_method(_MD("node_set_pos","shader_type","id","pos"),&ShaderGraph::node_set_pos);
- ObjectTypeDB::bind_method(_MD("node_get_pos","shader_type","id"),&ShaderGraph::node_get_pos);
+ ClassDB::bind_method(_MD("node_add","shader_type","node_type","id"),&ShaderGraph::node_add);
+ ClassDB::bind_method(_MD("node_remove","shader_type","id"),&ShaderGraph::node_remove);
+ ClassDB::bind_method(_MD("node_set_pos","shader_type","id","pos"),&ShaderGraph::node_set_pos);
+ ClassDB::bind_method(_MD("node_get_pos","shader_type","id"),&ShaderGraph::node_get_pos);
- ObjectTypeDB::bind_method(_MD("node_get_type","shader_type","id"),&ShaderGraph::node_get_type);
+ ClassDB::bind_method(_MD("node_get_type","shader_type","id"),&ShaderGraph::node_get_type);
- ObjectTypeDB::bind_method(_MD("get_node_list","shader_type"),&ShaderGraph::_get_node_list);
+ ClassDB::bind_method(_MD("get_node_list","shader_type"),&ShaderGraph::_get_node_list);
- ObjectTypeDB::bind_method(_MD("default_set_value","shader_type","id","param_id","value"), &ShaderGraph::default_set_value);
- ObjectTypeDB::bind_method(_MD("default_get_value","shader_type","id","param_id"), &ShaderGraph::default_get_value);
+ ClassDB::bind_method(_MD("default_set_value","shader_type","id","param_id","value"), &ShaderGraph::default_set_value);
+ ClassDB::bind_method(_MD("default_get_value","shader_type","id","param_id"), &ShaderGraph::default_get_value);
- ObjectTypeDB::bind_method(_MD("scalar_const_node_set_value","shader_type","id","value"),&ShaderGraph::scalar_const_node_set_value);
- ObjectTypeDB::bind_method(_MD("scalar_const_node_get_value","shader_type","id"),&ShaderGraph::scalar_const_node_get_value);
+ ClassDB::bind_method(_MD("scalar_const_node_set_value","shader_type","id","value"),&ShaderGraph::scalar_const_node_set_value);
+ ClassDB::bind_method(_MD("scalar_const_node_get_value","shader_type","id"),&ShaderGraph::scalar_const_node_get_value);
- ObjectTypeDB::bind_method(_MD("vec_const_node_set_value","shader_type","id","value"),&ShaderGraph::vec_const_node_set_value);
- ObjectTypeDB::bind_method(_MD("vec_const_node_get_value","shader_type","id"),&ShaderGraph::vec_const_node_get_value);
+ ClassDB::bind_method(_MD("vec_const_node_set_value","shader_type","id","value"),&ShaderGraph::vec_const_node_set_value);
+ ClassDB::bind_method(_MD("vec_const_node_get_value","shader_type","id"),&ShaderGraph::vec_const_node_get_value);
- ObjectTypeDB::bind_method(_MD("rgb_const_node_set_value","shader_type","id","value"),&ShaderGraph::rgb_const_node_set_value);
- ObjectTypeDB::bind_method(_MD("rgb_const_node_get_value","shader_type","id"),&ShaderGraph::rgb_const_node_get_value);
+ ClassDB::bind_method(_MD("rgb_const_node_set_value","shader_type","id","value"),&ShaderGraph::rgb_const_node_set_value);
+ ClassDB::bind_method(_MD("rgb_const_node_get_value","shader_type","id"),&ShaderGraph::rgb_const_node_get_value);
- ObjectTypeDB::bind_method(_MD("xform_const_node_set_value","shader_type","id","value"),&ShaderGraph::xform_const_node_set_value);
- ObjectTypeDB::bind_method(_MD("xform_const_node_get_value","shader_type","id"),&ShaderGraph::xform_const_node_get_value);
+ ClassDB::bind_method(_MD("xform_const_node_set_value","shader_type","id","value"),&ShaderGraph::xform_const_node_set_value);
+ ClassDB::bind_method(_MD("xform_const_node_get_value","shader_type","id"),&ShaderGraph::xform_const_node_get_value);
// void get_node_list(ShaderType p_which,List<int> *p_node_list) const;
- ObjectTypeDB::bind_method(_MD("texture_node_set_filter_size","shader_type","id","filter_size"),&ShaderGraph::texture_node_set_filter_size);
- ObjectTypeDB::bind_method(_MD("texture_node_get_filter_size","shader_type","id"),&ShaderGraph::texture_node_get_filter_size);
+ ClassDB::bind_method(_MD("texture_node_set_filter_size","shader_type","id","filter_size"),&ShaderGraph::texture_node_set_filter_size);
+ ClassDB::bind_method(_MD("texture_node_get_filter_size","shader_type","id"),&ShaderGraph::texture_node_get_filter_size);
- ObjectTypeDB::bind_method(_MD("texture_node_set_filter_strength","shader_type","id","filter_strength"),&ShaderGraph::texture_node_set_filter_strength);
- ObjectTypeDB::bind_method(_MD("texture_node_get_filter_strength","shader_type","id"),&ShaderGraph::texture_node_get_filter_strength);
+ ClassDB::bind_method(_MD("texture_node_set_filter_strength","shader_type","id","filter_strength"),&ShaderGraph::texture_node_set_filter_strength);
+ ClassDB::bind_method(_MD("texture_node_get_filter_strength","shader_type","id"),&ShaderGraph::texture_node_get_filter_strength);
- ObjectTypeDB::bind_method(_MD("scalar_op_node_set_op","shader_type","id","op"),&ShaderGraph::scalar_op_node_set_op);
- ObjectTypeDB::bind_method(_MD("scalar_op_node_get_op","shader_type","id"),&ShaderGraph::scalar_op_node_get_op);
+ ClassDB::bind_method(_MD("scalar_op_node_set_op","shader_type","id","op"),&ShaderGraph::scalar_op_node_set_op);
+ ClassDB::bind_method(_MD("scalar_op_node_get_op","shader_type","id"),&ShaderGraph::scalar_op_node_get_op);
- ObjectTypeDB::bind_method(_MD("vec_op_node_set_op","shader_type","id","op"),&ShaderGraph::vec_op_node_set_op);
- ObjectTypeDB::bind_method(_MD("vec_op_node_get_op","shader_type","id"),&ShaderGraph::vec_op_node_get_op);
+ ClassDB::bind_method(_MD("vec_op_node_set_op","shader_type","id","op"),&ShaderGraph::vec_op_node_set_op);
+ ClassDB::bind_method(_MD("vec_op_node_get_op","shader_type","id"),&ShaderGraph::vec_op_node_get_op);
- ObjectTypeDB::bind_method(_MD("vec_scalar_op_node_set_op","shader_type","id","op"),&ShaderGraph::vec_scalar_op_node_set_op);
- ObjectTypeDB::bind_method(_MD("vec_scalar_op_node_get_op","shader_type","id"),&ShaderGraph::vec_scalar_op_node_get_op);
+ ClassDB::bind_method(_MD("vec_scalar_op_node_set_op","shader_type","id","op"),&ShaderGraph::vec_scalar_op_node_set_op);
+ ClassDB::bind_method(_MD("vec_scalar_op_node_get_op","shader_type","id"),&ShaderGraph::vec_scalar_op_node_get_op);
- ObjectTypeDB::bind_method(_MD("rgb_op_node_set_op","shader_type","id","op"),&ShaderGraph::rgb_op_node_set_op);
- ObjectTypeDB::bind_method(_MD("rgb_op_node_get_op","shader_type","id"),&ShaderGraph::rgb_op_node_get_op);
+ ClassDB::bind_method(_MD("rgb_op_node_set_op","shader_type","id","op"),&ShaderGraph::rgb_op_node_set_op);
+ ClassDB::bind_method(_MD("rgb_op_node_get_op","shader_type","id"),&ShaderGraph::rgb_op_node_get_op);
- ObjectTypeDB::bind_method(_MD("xform_vec_mult_node_set_no_translation","shader_type","id","disable"),&ShaderGraph::xform_vec_mult_node_set_no_translation);
- ObjectTypeDB::bind_method(_MD("xform_vec_mult_node_get_no_translation","shader_type","id"),&ShaderGraph::xform_vec_mult_node_get_no_translation);
+ ClassDB::bind_method(_MD("xform_vec_mult_node_set_no_translation","shader_type","id","disable"),&ShaderGraph::xform_vec_mult_node_set_no_translation);
+ ClassDB::bind_method(_MD("xform_vec_mult_node_get_no_translation","shader_type","id"),&ShaderGraph::xform_vec_mult_node_get_no_translation);
- ObjectTypeDB::bind_method(_MD("scalar_func_node_set_function","shader_type","id","func"),&ShaderGraph::scalar_func_node_set_function);
- ObjectTypeDB::bind_method(_MD("scalar_func_node_get_function","shader_type","id"),&ShaderGraph::scalar_func_node_get_function);
+ ClassDB::bind_method(_MD("scalar_func_node_set_function","shader_type","id","func"),&ShaderGraph::scalar_func_node_set_function);
+ ClassDB::bind_method(_MD("scalar_func_node_get_function","shader_type","id"),&ShaderGraph::scalar_func_node_get_function);
- ObjectTypeDB::bind_method(_MD("vec_func_node_set_function","shader_type","id","func"),&ShaderGraph::vec_func_node_set_function);
- ObjectTypeDB::bind_method(_MD("vec_func_node_get_function","shader_type","id"),&ShaderGraph::vec_func_node_get_function);
+ ClassDB::bind_method(_MD("vec_func_node_set_function","shader_type","id","func"),&ShaderGraph::vec_func_node_set_function);
+ ClassDB::bind_method(_MD("vec_func_node_get_function","shader_type","id"),&ShaderGraph::vec_func_node_get_function);
- ObjectTypeDB::bind_method(_MD("input_node_set_name","shader_type","id","name"),&ShaderGraph::input_node_set_name);
- ObjectTypeDB::bind_method(_MD("input_node_get_name","shader_type","id"),&ShaderGraph::input_node_get_name);
+ ClassDB::bind_method(_MD("input_node_set_name","shader_type","id","name"),&ShaderGraph::input_node_set_name);
+ ClassDB::bind_method(_MD("input_node_get_name","shader_type","id"),&ShaderGraph::input_node_get_name);
- ObjectTypeDB::bind_method(_MD("scalar_input_node_set_value","shader_type","id","value"),&ShaderGraph::scalar_input_node_set_value);
- ObjectTypeDB::bind_method(_MD("scalar_input_node_get_value","shader_type","id"),&ShaderGraph::scalar_input_node_get_value);
+ ClassDB::bind_method(_MD("scalar_input_node_set_value","shader_type","id","value"),&ShaderGraph::scalar_input_node_set_value);
+ ClassDB::bind_method(_MD("scalar_input_node_get_value","shader_type","id"),&ShaderGraph::scalar_input_node_get_value);
- ObjectTypeDB::bind_method(_MD("vec_input_node_set_value","shader_type","id","value"),&ShaderGraph::vec_input_node_set_value);
- ObjectTypeDB::bind_method(_MD("vec_input_node_get_value","shader_type","id"),&ShaderGraph::vec_input_node_get_value);
+ ClassDB::bind_method(_MD("vec_input_node_set_value","shader_type","id","value"),&ShaderGraph::vec_input_node_set_value);
+ ClassDB::bind_method(_MD("vec_input_node_get_value","shader_type","id"),&ShaderGraph::vec_input_node_get_value);
- ObjectTypeDB::bind_method(_MD("rgb_input_node_set_value","shader_type","id","value"),&ShaderGraph::rgb_input_node_set_value);
- ObjectTypeDB::bind_method(_MD("rgb_input_node_get_value","shader_type","id"),&ShaderGraph::rgb_input_node_get_value);
+ ClassDB::bind_method(_MD("rgb_input_node_set_value","shader_type","id","value"),&ShaderGraph::rgb_input_node_set_value);
+ ClassDB::bind_method(_MD("rgb_input_node_get_value","shader_type","id"),&ShaderGraph::rgb_input_node_get_value);
- ObjectTypeDB::bind_method(_MD("xform_input_node_set_value","shader_type","id","value"),&ShaderGraph::xform_input_node_set_value);
- ObjectTypeDB::bind_method(_MD("xform_input_node_get_value","shader_type","id"),&ShaderGraph::xform_input_node_get_value);
+ ClassDB::bind_method(_MD("xform_input_node_set_value","shader_type","id","value"),&ShaderGraph::xform_input_node_set_value);
+ ClassDB::bind_method(_MD("xform_input_node_get_value","shader_type","id"),&ShaderGraph::xform_input_node_get_value);
- ObjectTypeDB::bind_method(_MD("texture_input_node_set_value","shader_type","id","value:Texture"),&ShaderGraph::texture_input_node_set_value);
- ObjectTypeDB::bind_method(_MD("texture_input_node_get_value:Texture","shader_type","id"),&ShaderGraph::texture_input_node_get_value);
+ ClassDB::bind_method(_MD("texture_input_node_set_value","shader_type","id","value:Texture"),&ShaderGraph::texture_input_node_set_value);
+ ClassDB::bind_method(_MD("texture_input_node_get_value:Texture","shader_type","id"),&ShaderGraph::texture_input_node_get_value);
- ObjectTypeDB::bind_method(_MD("cubemap_input_node_set_value","shader_type","id","value:CubeMap"),&ShaderGraph::cubemap_input_node_set_value);
- ObjectTypeDB::bind_method(_MD("cubemap_input_node_get_value:CubeMap","shader_type","id"),&ShaderGraph::cubemap_input_node_get_value);
+ ClassDB::bind_method(_MD("cubemap_input_node_set_value","shader_type","id","value:CubeMap"),&ShaderGraph::cubemap_input_node_set_value);
+ ClassDB::bind_method(_MD("cubemap_input_node_get_value:CubeMap","shader_type","id"),&ShaderGraph::cubemap_input_node_get_value);
- ObjectTypeDB::bind_method(_MD("comment_node_set_text","shader_type","id","text"),&ShaderGraph::comment_node_set_text);
- ObjectTypeDB::bind_method(_MD("comment_node_get_text","shader_type","id"),&ShaderGraph::comment_node_get_text);
+ ClassDB::bind_method(_MD("comment_node_set_text","shader_type","id","text"),&ShaderGraph::comment_node_set_text);
+ ClassDB::bind_method(_MD("comment_node_get_text","shader_type","id"),&ShaderGraph::comment_node_get_text);
- ObjectTypeDB::bind_method(_MD("color_ramp_node_set_ramp","shader_type","id","colors","offsets"),&ShaderGraph::color_ramp_node_set_ramp);
- ObjectTypeDB::bind_method(_MD("color_ramp_node_get_colors","shader_type","id"),&ShaderGraph::color_ramp_node_get_colors);
- ObjectTypeDB::bind_method(_MD("color_ramp_node_get_offsets","shader_type","id"),&ShaderGraph::color_ramp_node_get_offsets);
+ ClassDB::bind_method(_MD("color_ramp_node_set_ramp","shader_type","id","colors","offsets"),&ShaderGraph::color_ramp_node_set_ramp);
+ ClassDB::bind_method(_MD("color_ramp_node_get_colors","shader_type","id"),&ShaderGraph::color_ramp_node_get_colors);
+ ClassDB::bind_method(_MD("color_ramp_node_get_offsets","shader_type","id"),&ShaderGraph::color_ramp_node_get_offsets);
- ObjectTypeDB::bind_method(_MD("curve_map_node_set_points","shader_type","id","points"),&ShaderGraph::curve_map_node_set_points);
- ObjectTypeDB::bind_method(_MD("curve_map_node_get_points","shader_type","id"),&ShaderGraph::curve_map_node_get_points);
+ ClassDB::bind_method(_MD("curve_map_node_set_points","shader_type","id","points"),&ShaderGraph::curve_map_node_set_points);
+ ClassDB::bind_method(_MD("curve_map_node_get_points","shader_type","id"),&ShaderGraph::curve_map_node_get_points);
- ObjectTypeDB::bind_method(_MD("connect_node:Error","shader_type","src_id","src_slot","dst_id","dst_slot"),&ShaderGraph::connect_node);
- ObjectTypeDB::bind_method(_MD("is_node_connected","shader_type","src_id","src_slot","dst_id","dst_slot"),&ShaderGraph::is_node_connected);
- ObjectTypeDB::bind_method(_MD("disconnect_node","shader_type","src_id","src_slot","dst_id","dst_slot"),&ShaderGraph::disconnect_node);
- ObjectTypeDB::bind_method(_MD("get_node_connections","shader_type"),&ShaderGraph::_get_connections);
+ ClassDB::bind_method(_MD("connect_node:Error","shader_type","src_id","src_slot","dst_id","dst_slot"),&ShaderGraph::connect_node);
+ ClassDB::bind_method(_MD("is_node_connected","shader_type","src_id","src_slot","dst_id","dst_slot"),&ShaderGraph::is_node_connected);
+ ClassDB::bind_method(_MD("disconnect_node","shader_type","src_id","src_slot","dst_id","dst_slot"),&ShaderGraph::disconnect_node);
+ ClassDB::bind_method(_MD("get_node_connections","shader_type"),&ShaderGraph::_get_connections);
- ObjectTypeDB::bind_method(_MD("clear","shader_type"),&ShaderGraph::clear);
+ ClassDB::bind_method(_MD("clear","shader_type"),&ShaderGraph::clear);
- ObjectTypeDB::bind_method(_MD("node_set_state","shader_type","id","state"),&ShaderGraph::node_set_state);
- ObjectTypeDB::bind_method(_MD("node_get_state:Variant","shader_type","id"),&ShaderGraph::node_get_state);
+ ClassDB::bind_method(_MD("node_set_state","shader_type","id","state"),&ShaderGraph::node_set_state);
+ ClassDB::bind_method(_MD("node_get_state:Variant","shader_type","id"),&ShaderGraph::node_get_state);
- ObjectTypeDB::bind_method(_MD("_set_data"),&ShaderGraph::_set_data);
- ObjectTypeDB::bind_method(_MD("_get_data"),&ShaderGraph::_get_data);
+ ClassDB::bind_method(_MD("_set_data"),&ShaderGraph::_set_data);
+ ClassDB::bind_method(_MD("_get_data"),&ShaderGraph::_get_data);
ADD_PROPERTY( PropertyInfo(Variant::DICTIONARY,"_data",PROPERTY_HINT_NONE,"",PROPERTY_USAGE_NOEDITOR), _SCS("_set_data"),_SCS("_get_data"));
@@ -399,21 +399,21 @@ void ShaderGraph::_bind_methods() {
#if 0
- ObjectTypeDB::bind_method(_MD("node_add"),&ShaderGraph::node_add );
- ObjectTypeDB::bind_method(_MD("node_remove"),&ShaderGraph::node_remove );
- ObjectTypeDB::bind_method(_MD("node_set_param"),&ShaderGraph::node_set_param );
- ObjectTypeDB::bind_method(_MD("node_set_pos"),&ShaderGraph::node_set_pos );
+ ClassDB::bind_method(_MD("node_add"),&ShaderGraph::node_add );
+ ClassDB::bind_method(_MD("node_remove"),&ShaderGraph::node_remove );
+ ClassDB::bind_method(_MD("node_set_param"),&ShaderGraph::node_set_param );
+ ClassDB::bind_method(_MD("node_set_pos"),&ShaderGraph::node_set_pos );
- ObjectTypeDB::bind_method(_MD("node_get_pos"),&ShaderGraph::node_get_pos );
- ObjectTypeDB::bind_method(_MD("node_get_param"),&ShaderGraph::node_get_param);
- ObjectTypeDB::bind_method(_MD("node_get_type"),&ShaderGraph::node_get_type);
+ ClassDB::bind_method(_MD("node_get_pos"),&ShaderGraph::node_get_pos );
+ ClassDB::bind_method(_MD("node_get_param"),&ShaderGraph::node_get_param);
+ ClassDB::bind_method(_MD("node_get_type"),&ShaderGraph::node_get_type);
- ObjectTypeDB::bind_method(_MD("connect"),&ShaderGraph::connect );
- ObjectTypeDB::bind_method(_MD("disconnect"),&ShaderGraph::disconnect );
+ ClassDB::bind_method(_MD("connect"),&ShaderGraph::connect );
+ ClassDB::bind_method(_MD("disconnect"),&ShaderGraph::disconnect );
- ObjectTypeDB::bind_method(_MD("get_connections"),&ShaderGraph::_get_connections_helper );
+ ClassDB::bind_method(_MD("get_connections"),&ShaderGraph::_get_connections_helper );
- ObjectTypeDB::bind_method(_MD("clear"),&ShaderGraph::clear );
+ ClassDB::bind_method(_MD("clear"),&ShaderGraph::clear );
BIND_CONSTANT( NODE_IN ); ///< param 0: name
BIND_CONSTANT( NODE_OUT ); ///< param 0: name
diff --git a/scene/resources/shader_graph.h b/scene/resources/shader_graph.h
index c8d0d3d715..57893f27c0 100644
--- a/scene/resources/shader_graph.h
+++ b/scene/resources/shader_graph.h
@@ -36,7 +36,7 @@
class ShaderGraph : public Shader {
- OBJ_TYPE( ShaderGraph, Shader );
+ GDCLASS( ShaderGraph, Shader );
RES_BASE_EXTENSION("sgp");
public:
@@ -418,7 +418,7 @@ VARIANT_ENUM_CAST( ShaderGraph::GraphError );
class MaterialShaderGraph : public ShaderGraph {
- OBJ_TYPE( MaterialShaderGraph, ShaderGraph );
+ GDCLASS( MaterialShaderGraph, ShaderGraph );
public:
@@ -430,7 +430,7 @@ public:
class CanvasItemShaderGraph : public ShaderGraph {
- OBJ_TYPE( CanvasItemShaderGraph, ShaderGraph );
+ GDCLASS( CanvasItemShaderGraph, ShaderGraph );
public:
diff --git a/scene/resources/shape.h b/scene/resources/shape.h
index 8d8e3d35c5..94a8ec7075 100644
--- a/scene/resources/shape.h
+++ b/scene/resources/shape.h
@@ -34,7 +34,7 @@ class Mesh;
class Shape : public Resource {
- OBJ_TYPE( Shape, Resource );
+ GDCLASS( Shape, Resource );
OBJ_SAVE_TYPE( Shape );
RES_BASE_EXTENSION("shp");
RID shape;
diff --git a/scene/resources/shape_2d.cpp b/scene/resources/shape_2d.cpp
index 969aeb973f..4e2af89c05 100644
--- a/scene/resources/shape_2d.cpp
+++ b/scene/resources/shape_2d.cpp
@@ -104,12 +104,12 @@ Variant Shape2D::collide_and_get_contacts(const Matrix32& p_local_xform, const
void Shape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_custom_solver_bias","bias"),&Shape2D::set_custom_solver_bias);
- ObjectTypeDB::bind_method(_MD("get_custom_solver_bias"),&Shape2D::get_custom_solver_bias);
- ObjectTypeDB::bind_method(_MD("collide","local_xform","with_shape:Shape2D","shape_xform"),&Shape2D::collide);
- ObjectTypeDB::bind_method(_MD("collide_with_motion","local_xform","local_motion","with_shape:Shape2D","shape_xform","shape_motion"),&Shape2D::collide_with_motion);
- ObjectTypeDB::bind_method(_MD("collide_and_get_contacts:Variant","local_xform","with_shape:Shape2D","shape_xform"),&Shape2D::collide_and_get_contacts);
- ObjectTypeDB::bind_method(_MD("collide_with_motion_and_get_contacts:Variant","local_xform","local_motion","with_shape:Shape2D","shape_xform","shape_motion"),&Shape2D::collide_with_motion_and_get_contacts);
+ ClassDB::bind_method(_MD("set_custom_solver_bias","bias"),&Shape2D::set_custom_solver_bias);
+ ClassDB::bind_method(_MD("get_custom_solver_bias"),&Shape2D::get_custom_solver_bias);
+ ClassDB::bind_method(_MD("collide","local_xform","with_shape:Shape2D","shape_xform"),&Shape2D::collide);
+ ClassDB::bind_method(_MD("collide_with_motion","local_xform","local_motion","with_shape:Shape2D","shape_xform","shape_motion"),&Shape2D::collide_with_motion);
+ ClassDB::bind_method(_MD("collide_and_get_contacts:Variant","local_xform","with_shape:Shape2D","shape_xform"),&Shape2D::collide_and_get_contacts);
+ ClassDB::bind_method(_MD("collide_with_motion_and_get_contacts:Variant","local_xform","local_motion","with_shape:Shape2D","shape_xform","shape_motion"),&Shape2D::collide_with_motion_and_get_contacts);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"custom_solver_bias",PROPERTY_HINT_RANGE,"0,1,0.001"),_SCS("set_custom_solver_bias"),_SCS("get_custom_solver_bias"));
}
diff --git a/scene/resources/shape_2d.h b/scene/resources/shape_2d.h
index 758824a4b7..ea89b31057 100644
--- a/scene/resources/shape_2d.h
+++ b/scene/resources/shape_2d.h
@@ -32,7 +32,7 @@
#include "resource.h"
class Shape2D : public Resource {
- OBJ_TYPE( Shape2D, Resource );
+ GDCLASS( Shape2D, Resource );
OBJ_SAVE_TYPE( Shape2D );
RID shape;
diff --git a/scene/resources/shape_line_2d.cpp b/scene/resources/shape_line_2d.cpp
index a86e4f050f..b2270d00c0 100644
--- a/scene/resources/shape_line_2d.cpp
+++ b/scene/resources/shape_line_2d.cpp
@@ -90,11 +90,11 @@ Rect2 LineShape2D::get_rect() const{
void LineShape2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_normal","normal"),&LineShape2D::set_normal);
- ObjectTypeDB::bind_method(_MD("get_normal"),&LineShape2D::get_normal);
+ ClassDB::bind_method(_MD("set_normal","normal"),&LineShape2D::set_normal);
+ ClassDB::bind_method(_MD("get_normal"),&LineShape2D::get_normal);
- ObjectTypeDB::bind_method(_MD("set_d","d"),&LineShape2D::set_d);
- ObjectTypeDB::bind_method(_MD("get_d"),&LineShape2D::get_d);
+ ClassDB::bind_method(_MD("set_d","d"),&LineShape2D::set_d);
+ ClassDB::bind_method(_MD("get_d"),&LineShape2D::get_d);
ADD_PROPERTY( PropertyInfo(Variant::VECTOR2,"normal"),_SCS("set_normal"),_SCS("get_normal") );
ADD_PROPERTY( PropertyInfo(Variant::REAL,"d"),_SCS("set_d"),_SCS("get_d") );
diff --git a/scene/resources/shape_line_2d.h b/scene/resources/shape_line_2d.h
index 160dc17b4b..abad5f6a24 100644
--- a/scene/resources/shape_line_2d.h
+++ b/scene/resources/shape_line_2d.h
@@ -32,7 +32,7 @@
#include "scene/resources/shape_2d.h"
class LineShape2D : public Shape2D {
- OBJ_TYPE( LineShape2D, Shape2D );
+ GDCLASS( LineShape2D, Shape2D );
Vector2 normal;
real_t d;
diff --git a/scene/resources/sky_box.cpp b/scene/resources/sky_box.cpp
index e8017cb084..95e3053bc3 100644
--- a/scene/resources/sky_box.cpp
+++ b/scene/resources/sky_box.cpp
@@ -16,8 +16,8 @@ SkyBox::RadianceSize SkyBox::get_radiance_size() const {
void SkyBox::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_radiance_size","size"),&SkyBox::set_radiance_size);
- ObjectTypeDB::bind_method(_MD("get_radiance_size"),&SkyBox::get_radiance_size);
+ ClassDB::bind_method(_MD("set_radiance_size","size"),&SkyBox::set_radiance_size);
+ ClassDB::bind_method(_MD("get_radiance_size"),&SkyBox::get_radiance_size);
ADD_PROPERTY(PropertyInfo(Variant::INT,"radiance_size",PROPERTY_HINT_ENUM,"256,512,1024,2048"),_SCS("set_radiance_size"),_SCS("get_radiance_size"));
@@ -113,8 +113,8 @@ RID ImageSkyBox::get_rid() const {
void ImageSkyBox::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_image_path","image","path"),&ImageSkyBox::set_image_path);
- ObjectTypeDB::bind_method(_MD("get_image_path","image"),&ImageSkyBox::get_image_path);
+ ClassDB::bind_method(_MD("set_image_path","image","path"),&ImageSkyBox::set_image_path);
+ ClassDB::bind_method(_MD("get_image_path","image"),&ImageSkyBox::get_image_path);
List<String> extensions;
ImageLoader::get_recognized_extensions(&extensions);
diff --git a/scene/resources/sky_box.h b/scene/resources/sky_box.h
index 3a3dd1b2de..a3caf15aa7 100644
--- a/scene/resources/sky_box.h
+++ b/scene/resources/sky_box.h
@@ -4,7 +4,7 @@
#include "scene/resources/texture.h"
class SkyBox : public Resource {
- OBJ_TYPE(SkyBox,Resource);
+ GDCLASS(SkyBox,Resource);
public:
@@ -32,7 +32,7 @@ VARIANT_ENUM_CAST(SkyBox::RadianceSize)
class ImageSkyBox : public SkyBox {
- OBJ_TYPE(ImageSkyBox,SkyBox);
+ GDCLASS(ImageSkyBox,SkyBox);
public:
diff --git a/scene/resources/space_2d.cpp b/scene/resources/space_2d.cpp
index e95bfd69c8..3f0d2824ce 100644
--- a/scene/resources/space_2d.cpp
+++ b/scene/resources/space_2d.cpp
@@ -48,8 +48,8 @@ bool Space2D::is_active() const {
void Space2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_active","active"),&Space2D::set_active);
- ObjectTypeDB::bind_method(_MD("is_active"),&Space2D::is_active);
+ ClassDB::bind_method(_MD("set_active","active"),&Space2D::set_active);
+ ClassDB::bind_method(_MD("is_active"),&Space2D::is_active);
ADD_PROPERTY( PropertyInfo(Variant::BOOL,"active"),_SCS("set_active"),_SCS("is_active") );
diff --git a/scene/resources/space_2d.h b/scene/resources/space_2d.h
index b1577dcbe4..82aef89c07 100644
--- a/scene/resources/space_2d.h
+++ b/scene/resources/space_2d.h
@@ -35,7 +35,7 @@
class Space2D : public Resource {
- OBJ_TYPE(Space2D,Resource);
+ GDCLASS(Space2D,Resource);
bool active;
RID space;
protected:
diff --git a/scene/resources/sphere_shape.cpp b/scene/resources/sphere_shape.cpp
index 5f632b1404..bcfb164b4c 100644
--- a/scene/resources/sphere_shape.cpp
+++ b/scene/resources/sphere_shape.cpp
@@ -75,8 +75,8 @@ float SphereShape::get_radius() const {
void SphereShape::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_radius","radius"),&SphereShape::set_radius);
- ObjectTypeDB::bind_method(_MD("get_radius"),&SphereShape::get_radius);
+ ClassDB::bind_method(_MD("set_radius","radius"),&SphereShape::set_radius);
+ ClassDB::bind_method(_MD("get_radius"),&SphereShape::get_radius);
ADD_PROPERTY( PropertyInfo(Variant::REAL,"radius",PROPERTY_HINT_RANGE,"0,4096,0.01"), _SCS("set_radius"), _SCS("get_radius"));
diff --git a/scene/resources/sphere_shape.h b/scene/resources/sphere_shape.h
index 96a84ce48f..990564be80 100644
--- a/scene/resources/sphere_shape.h
+++ b/scene/resources/sphere_shape.h
@@ -34,7 +34,7 @@
class SphereShape : public Shape {
- OBJ_TYPE(SphereShape,Shape);
+ GDCLASS(SphereShape,Shape);
float radius;
protected:
diff --git a/scene/resources/style_box.cpp b/scene/resources/style_box.cpp
index cdb663b8f1..146e53300d 100644
--- a/scene/resources/style_box.cpp
+++ b/scene/resources/style_box.cpp
@@ -70,20 +70,20 @@ Size2 StyleBox::get_center_size() const {
void StyleBox::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("test_mask","point","rect"),&StyleBox::test_mask);
+ ClassDB::bind_method(_MD("test_mask","point","rect"),&StyleBox::test_mask);
- ObjectTypeDB::bind_method(_MD("set_default_margin","margin","offset"),&StyleBox::set_default_margin);
- ObjectTypeDB::bind_method(_MD("get_default_margin","margin"),&StyleBox::get_default_margin);
+ ClassDB::bind_method(_MD("set_default_margin","margin","offset"),&StyleBox::set_default_margin);
+ ClassDB::bind_method(_MD("get_default_margin","margin"),&StyleBox::get_default_margin);
-// ObjectTypeDB::bind_method(_MD("set_default_margin"),&StyleBox::set_default_margin);
-// ObjectTypeDB::bind_method(_MD("get_default_margin"),&StyleBox::get_default_margin);
+// ClassDB::bind_method(_MD("set_default_margin"),&StyleBox::set_default_margin);
+// ClassDB::bind_method(_MD("get_default_margin"),&StyleBox::get_default_margin);
- ObjectTypeDB::bind_method(_MD("get_margin","margin"),&StyleBox::get_margin);
- ObjectTypeDB::bind_method(_MD("get_minimum_size"),&StyleBox::get_minimum_size);
- ObjectTypeDB::bind_method(_MD("get_center_size"),&StyleBox::get_center_size);
- ObjectTypeDB::bind_method(_MD("get_offset"),&StyleBox::get_offset);
+ ClassDB::bind_method(_MD("get_margin","margin"),&StyleBox::get_margin);
+ ClassDB::bind_method(_MD("get_minimum_size"),&StyleBox::get_minimum_size);
+ ClassDB::bind_method(_MD("get_center_size"),&StyleBox::get_center_size);
+ ClassDB::bind_method(_MD("get_offset"),&StyleBox::get_offset);
- ObjectTypeDB::bind_method(_MD("draw","canvas_item","rect"),&StyleBox::draw);
+ ClassDB::bind_method(_MD("draw","canvas_item","rect"),&StyleBox::draw);
ADD_PROPERTYI( PropertyInfo( Variant::REAL, "content_margin/left", PROPERTY_HINT_RANGE,"-1,2048,1" ), _SCS("set_default_margin"),_SCS("get_default_margin"), MARGIN_LEFT );
ADD_PROPERTYI( PropertyInfo( Variant::REAL, "content_margin/right", PROPERTY_HINT_RANGE,"-1,2048,1" ), _SCS("set_default_margin"),_SCS("get_default_margin"), MARGIN_RIGHT );
@@ -208,23 +208,23 @@ Color StyleBoxTexture::get_modulate() const {
void StyleBoxTexture::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_texture","texture:Texture"),&StyleBoxTexture::set_texture);
- ObjectTypeDB::bind_method(_MD("get_texture:Texture"),&StyleBoxTexture::get_texture);
+ ClassDB::bind_method(_MD("set_texture","texture:Texture"),&StyleBoxTexture::set_texture);
+ ClassDB::bind_method(_MD("get_texture:Texture"),&StyleBoxTexture::get_texture);
- ObjectTypeDB::bind_method(_MD("set_margin_size","margin","size"),&StyleBoxTexture::set_margin_size);
- ObjectTypeDB::bind_method(_MD("get_margin_size","margin"),&StyleBoxTexture::get_margin_size);
+ ClassDB::bind_method(_MD("set_margin_size","margin","size"),&StyleBoxTexture::set_margin_size);
+ ClassDB::bind_method(_MD("get_margin_size","margin"),&StyleBoxTexture::get_margin_size);
- ObjectTypeDB::bind_method(_MD("set_expand_margin_size","margin","size"),&StyleBoxTexture::set_expand_margin_size);
- ObjectTypeDB::bind_method(_MD("get_expand_margin_size","margin"),&StyleBoxTexture::get_expand_margin_size);
+ ClassDB::bind_method(_MD("set_expand_margin_size","margin","size"),&StyleBoxTexture::set_expand_margin_size);
+ ClassDB::bind_method(_MD("get_expand_margin_size","margin"),&StyleBoxTexture::get_expand_margin_size);
- ObjectTypeDB::bind_method(_MD("set_region_rect","region"),&StyleBoxTexture::set_region_rect);
- ObjectTypeDB::bind_method(_MD("get_region_rect"),&StyleBoxTexture::get_region_rect);
+ ClassDB::bind_method(_MD("set_region_rect","region"),&StyleBoxTexture::set_region_rect);
+ ClassDB::bind_method(_MD("get_region_rect"),&StyleBoxTexture::get_region_rect);
- ObjectTypeDB::bind_method(_MD("set_draw_center","enable"),&StyleBoxTexture::set_draw_center);
- ObjectTypeDB::bind_method(_MD("get_draw_center"),&StyleBoxTexture::get_draw_center);
+ ClassDB::bind_method(_MD("set_draw_center","enable"),&StyleBoxTexture::set_draw_center);
+ ClassDB::bind_method(_MD("get_draw_center"),&StyleBoxTexture::get_draw_center);
- ObjectTypeDB::bind_method(_MD("set_modulate","color"),&StyleBoxTexture::set_modulate);
- ObjectTypeDB::bind_method(_MD("get_modulate"),&StyleBoxTexture::get_modulate);
+ ClassDB::bind_method(_MD("set_modulate","color"),&StyleBoxTexture::set_modulate);
+ ClassDB::bind_method(_MD("get_modulate"),&StyleBoxTexture::get_modulate);
ADD_SIGNAL(MethodInfo("texture_changed"));
@@ -386,18 +386,18 @@ float StyleBoxFlat::get_style_margin(Margin p_margin) const {
}
void StyleBoxFlat::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_bg_color","color"),&StyleBoxFlat::set_bg_color);
- ObjectTypeDB::bind_method(_MD("get_bg_color"),&StyleBoxFlat::get_bg_color);
- ObjectTypeDB::bind_method(_MD("set_light_color","color"),&StyleBoxFlat::set_light_color);
- ObjectTypeDB::bind_method(_MD("get_light_color"),&StyleBoxFlat::get_light_color);
- ObjectTypeDB::bind_method(_MD("set_dark_color","color"),&StyleBoxFlat::set_dark_color);
- ObjectTypeDB::bind_method(_MD("get_dark_color"),&StyleBoxFlat::get_dark_color);
- ObjectTypeDB::bind_method(_MD("set_border_size","size"),&StyleBoxFlat::set_border_size);
- ObjectTypeDB::bind_method(_MD("get_border_size"),&StyleBoxFlat::get_border_size);
- ObjectTypeDB::bind_method(_MD("set_border_blend","blend"),&StyleBoxFlat::set_border_blend);
- ObjectTypeDB::bind_method(_MD("get_border_blend"),&StyleBoxFlat::get_border_blend);
- ObjectTypeDB::bind_method(_MD("set_draw_center","size"),&StyleBoxFlat::set_draw_center);
- ObjectTypeDB::bind_method(_MD("get_draw_center"),&StyleBoxFlat::get_draw_center);
+ ClassDB::bind_method(_MD("set_bg_color","color"),&StyleBoxFlat::set_bg_color);
+ ClassDB::bind_method(_MD("get_bg_color"),&StyleBoxFlat::get_bg_color);
+ ClassDB::bind_method(_MD("set_light_color","color"),&StyleBoxFlat::set_light_color);
+ ClassDB::bind_method(_MD("get_light_color"),&StyleBoxFlat::get_light_color);
+ ClassDB::bind_method(_MD("set_dark_color","color"),&StyleBoxFlat::set_dark_color);
+ ClassDB::bind_method(_MD("get_dark_color"),&StyleBoxFlat::get_dark_color);
+ ClassDB::bind_method(_MD("set_border_size","size"),&StyleBoxFlat::set_border_size);
+ ClassDB::bind_method(_MD("get_border_size"),&StyleBoxFlat::get_border_size);
+ ClassDB::bind_method(_MD("set_border_blend","blend"),&StyleBoxFlat::set_border_blend);
+ ClassDB::bind_method(_MD("get_border_blend"),&StyleBoxFlat::get_border_blend);
+ ClassDB::bind_method(_MD("set_draw_center","size"),&StyleBoxFlat::set_draw_center);
+ ClassDB::bind_method(_MD("get_draw_center"),&StyleBoxFlat::get_draw_center);
ADD_PROPERTY( PropertyInfo( Variant::COLOR, "bg_color"), _SCS("set_bg_color"),_SCS("get_bg_color") );
ADD_PROPERTY( PropertyInfo( Variant::COLOR, "light_color"),_SCS("set_light_color"),_SCS("get_light_color"));
diff --git a/scene/resources/style_box.h b/scene/resources/style_box.h
index 8d3ba3a360..f8b02724ee 100644
--- a/scene/resources/style_box.h
+++ b/scene/resources/style_box.h
@@ -37,7 +37,7 @@
*/
class StyleBox : public Resource {
- OBJ_TYPE( StyleBox, Resource );
+ GDCLASS( StyleBox, Resource );
RES_BASE_EXTENSION("sbx");
OBJ_SAVE_TYPE( StyleBox );
float margin[4];
@@ -65,7 +65,7 @@ public:
class StyleBoxEmpty : public StyleBox {
- OBJ_TYPE( StyleBoxEmpty, StyleBox );
+ GDCLASS( StyleBoxEmpty, StyleBox );
virtual float get_style_margin(Margin p_margin) const { return 0; }
public:
@@ -76,7 +76,7 @@ public:
class StyleBoxTexture : public StyleBox {
- OBJ_TYPE( StyleBoxTexture, StyleBox );
+ GDCLASS( StyleBoxTexture, StyleBox );
float expand_margin[4];
@@ -123,7 +123,7 @@ public:
class StyleBoxFlat : public StyleBox {
- OBJ_TYPE( StyleBoxFlat, StyleBox );
+ GDCLASS( StyleBoxFlat, StyleBox );
Color bg_color;
Color light_color;
diff --git a/scene/resources/surface_tool.cpp b/scene/resources/surface_tool.cpp
index bcfacc62fa..2ed620c097 100644
--- a/scene/resources/surface_tool.cpp
+++ b/scene/resources/surface_tool.cpp
@@ -860,25 +860,25 @@ void SurfaceTool::clear() {
void SurfaceTool::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("begin","primitive"),&SurfaceTool::begin);
- ObjectTypeDB::bind_method(_MD("add_vertex","vertex"),&SurfaceTool::add_vertex);
- ObjectTypeDB::bind_method(_MD("add_color","color"),&SurfaceTool::add_color);
- ObjectTypeDB::bind_method(_MD("add_normal","normal"),&SurfaceTool::add_normal);
- ObjectTypeDB::bind_method(_MD("add_tangent","tangent"),&SurfaceTool::add_tangent);
- ObjectTypeDB::bind_method(_MD("add_uv","uv"),&SurfaceTool::add_uv);
- ObjectTypeDB::bind_method(_MD("add_uv2","uv2"),&SurfaceTool::add_uv2);
- ObjectTypeDB::bind_method(_MD("add_bones","bones"),&SurfaceTool::add_bones);
- ObjectTypeDB::bind_method(_MD("add_weights","weights"),&SurfaceTool::add_weights);
- ObjectTypeDB::bind_method(_MD("add_smooth_group","smooth"),&SurfaceTool::add_smooth_group);
- ObjectTypeDB::bind_method(_MD("add_triangle_fan", "vertexes", "uvs", "colors", "uv2s", "normals", "tangents"),&SurfaceTool::add_triangle_fan, DEFVAL(Vector<Vector2>()), DEFVAL(Vector<Color>()), DEFVAL(Vector<Vector2>()),DEFVAL(Vector<Vector3>()), DEFVAL(Vector<Plane>()));
- ObjectTypeDB::bind_method(_MD("set_material","material:Material"),&SurfaceTool::set_material);
- ObjectTypeDB::bind_method(_MD("index"),&SurfaceTool::index);
- ObjectTypeDB::bind_method(_MD("deindex"),&SurfaceTool::deindex);
- ///ObjectTypeDB::bind_method(_MD("generate_flat_normals"),&SurfaceTool::generate_flat_normals);
- ObjectTypeDB::bind_method(_MD("generate_normals"),&SurfaceTool::generate_normals);
- ObjectTypeDB::bind_method(_MD("add_index", "index"), &SurfaceTool::add_index);
- ObjectTypeDB::bind_method(_MD("commit:Mesh","existing:Mesh"),&SurfaceTool::commit,DEFVAL(Variant()));
- ObjectTypeDB::bind_method(_MD("clear"),&SurfaceTool::clear);
+ ClassDB::bind_method(_MD("begin","primitive"),&SurfaceTool::begin);
+ ClassDB::bind_method(_MD("add_vertex","vertex"),&SurfaceTool::add_vertex);
+ ClassDB::bind_method(_MD("add_color","color"),&SurfaceTool::add_color);
+ ClassDB::bind_method(_MD("add_normal","normal"),&SurfaceTool::add_normal);
+ ClassDB::bind_method(_MD("add_tangent","tangent"),&SurfaceTool::add_tangent);
+ ClassDB::bind_method(_MD("add_uv","uv"),&SurfaceTool::add_uv);
+ ClassDB::bind_method(_MD("add_uv2","uv2"),&SurfaceTool::add_uv2);
+ ClassDB::bind_method(_MD("add_bones","bones"),&SurfaceTool::add_bones);
+ ClassDB::bind_method(_MD("add_weights","weights"),&SurfaceTool::add_weights);
+ ClassDB::bind_method(_MD("add_smooth_group","smooth"),&SurfaceTool::add_smooth_group);
+ ClassDB::bind_method(_MD("add_triangle_fan", "vertexes", "uvs", "colors", "uv2s", "normals", "tangents"),&SurfaceTool::add_triangle_fan, DEFVAL(Vector<Vector2>()), DEFVAL(Vector<Color>()), DEFVAL(Vector<Vector2>()),DEFVAL(Vector<Vector3>()), DEFVAL(Vector<Plane>()));
+ ClassDB::bind_method(_MD("set_material","material:Material"),&SurfaceTool::set_material);
+ ClassDB::bind_method(_MD("index"),&SurfaceTool::index);
+ ClassDB::bind_method(_MD("deindex"),&SurfaceTool::deindex);
+ ///ClassDB::bind_method(_MD("generate_flat_normals"),&SurfaceTool::generate_flat_normals);
+ ClassDB::bind_method(_MD("generate_normals"),&SurfaceTool::generate_normals);
+ ClassDB::bind_method(_MD("add_index", "index"), &SurfaceTool::add_index);
+ ClassDB::bind_method(_MD("commit:Mesh","existing:Mesh"),&SurfaceTool::commit,DEFVAL(Variant()));
+ ClassDB::bind_method(_MD("clear"),&SurfaceTool::clear);
}
diff --git a/scene/resources/surface_tool.h b/scene/resources/surface_tool.h
index 5fa300a046..f859efbfe5 100644
--- a/scene/resources/surface_tool.h
+++ b/scene/resources/surface_tool.h
@@ -35,7 +35,7 @@
class SurfaceTool : public Reference {
- OBJ_TYPE(SurfaceTool, Reference );
+ GDCLASS(SurfaceTool, Reference );
public:
struct Vertex {
diff --git a/scene/resources/texture.cpp b/scene/resources/texture.cpp
index c9c9d679b6..462341a751 100644
--- a/scene/resources/texture.cpp
+++ b/scene/resources/texture.cpp
@@ -63,16 +63,16 @@ bool Texture::get_rect_region(const Rect2& p_rect, const Rect2& p_src_rect,Rect2
void Texture::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_width"),&Texture::get_width);
- ObjectTypeDB::bind_method(_MD("get_height"),&Texture::get_height);
- ObjectTypeDB::bind_method(_MD("get_size"),&Texture::get_size);
- ObjectTypeDB::bind_method(_MD("get_rid"),&Texture::get_rid);
- ObjectTypeDB::bind_method(_MD("has_alpha"),&Texture::has_alpha);
- ObjectTypeDB::bind_method(_MD("set_flags","flags"),&Texture::set_flags);
- ObjectTypeDB::bind_method(_MD("get_flags"),&Texture::get_flags);
- ObjectTypeDB::bind_method(_MD("draw","canvas_item","pos","modulate","transpose"),&Texture::draw,DEFVAL(Color(1,1,1)),DEFVAL(false));
- ObjectTypeDB::bind_method(_MD("draw_rect","canvas_item","rect","tile","modulate","transpose"),&Texture::draw_rect,DEFVAL(Color(1,1,1)),DEFVAL(false));
- ObjectTypeDB::bind_method(_MD("draw_rect_region","canvas_item","rect","src_rect","modulate","transpose"),&Texture::draw_rect_region,DEFVAL(Color(1,1,1)),DEFVAL(false));
+ ClassDB::bind_method(_MD("get_width"),&Texture::get_width);
+ ClassDB::bind_method(_MD("get_height"),&Texture::get_height);
+ ClassDB::bind_method(_MD("get_size"),&Texture::get_size);
+ ClassDB::bind_method(_MD("get_rid"),&Texture::get_rid);
+ ClassDB::bind_method(_MD("has_alpha"),&Texture::has_alpha);
+ ClassDB::bind_method(_MD("set_flags","flags"),&Texture::set_flags);
+ ClassDB::bind_method(_MD("get_flags"),&Texture::get_flags);
+ ClassDB::bind_method(_MD("draw","canvas_item","pos","modulate","transpose"),&Texture::draw,DEFVAL(Color(1,1,1)),DEFVAL(false));
+ ClassDB::bind_method(_MD("draw_rect","canvas_item","rect","tile","modulate","transpose"),&Texture::draw_rect,DEFVAL(Color(1,1,1)),DEFVAL(false));
+ ClassDB::bind_method(_MD("draw_rect_region","canvas_item","rect","src_rect","modulate","transpose"),&Texture::draw_rect_region,DEFVAL(Color(1,1,1)),DEFVAL(false));
BIND_CONSTANT( FLAG_MIPMAPS );
BIND_CONSTANT( FLAG_REPEAT );
@@ -407,27 +407,27 @@ void ImageTexture::_set_data(Dictionary p_data) {
void ImageTexture::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("create","width","height","format","flags"),&ImageTexture::create,DEFVAL(FLAGS_DEFAULT));
- ObjectTypeDB::bind_method(_MD("create_from_image","image","flags"),&ImageTexture::create_from_image,DEFVAL(FLAGS_DEFAULT));
- ObjectTypeDB::bind_method(_MD("get_format"),&ImageTexture::get_format);
- ObjectTypeDB::bind_method(_MD("load","path"),&ImageTexture::load);
- ObjectTypeDB::bind_method(_MD("set_data","image"),&ImageTexture::set_data);
- ObjectTypeDB::bind_method(_MD("get_data","cube_side"),&ImageTexture::get_data);
- ObjectTypeDB::bind_method(_MD("set_storage","mode"),&ImageTexture::set_storage);
- ObjectTypeDB::bind_method(_MD("get_storage"),&ImageTexture::get_storage);
- ObjectTypeDB::bind_method(_MD("set_lossy_storage_quality","quality"),&ImageTexture::set_lossy_storage_quality);
- ObjectTypeDB::bind_method(_MD("get_lossy_storage_quality"),&ImageTexture::get_lossy_storage_quality);
- ObjectTypeDB::bind_method(_MD("fix_alpha_edges"),&ImageTexture::fix_alpha_edges);
- ObjectTypeDB::bind_method(_MD("premultiply_alpha"),&ImageTexture::premultiply_alpha);
- ObjectTypeDB::bind_method(_MD("normal_to_xy"),&ImageTexture::normal_to_xy);
- ObjectTypeDB::bind_method(_MD("shrink_x2_and_keep_size"),&ImageTexture::shrink_x2_and_keep_size);
-
- ObjectTypeDB::bind_method(_MD("set_size_override","size"),&ImageTexture::set_size_override);
- ObjectTypeDB::set_method_flags(get_type_static(),_SCS("fix_alpha_edges"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
- ObjectTypeDB::set_method_flags(get_type_static(),_SCS("premultiply_alpha"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
- ObjectTypeDB::set_method_flags(get_type_static(),_SCS("normal_to_xy"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
- ObjectTypeDB::set_method_flags(get_type_static(),_SCS("shrink_x2_and_keep_size"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
- ObjectTypeDB::bind_method(_MD("_reload_hook","rid"),&ImageTexture::_reload_hook);
+ ClassDB::bind_method(_MD("create","width","height","format","flags"),&ImageTexture::create,DEFVAL(FLAGS_DEFAULT));
+ ClassDB::bind_method(_MD("create_from_image","image","flags"),&ImageTexture::create_from_image,DEFVAL(FLAGS_DEFAULT));
+ ClassDB::bind_method(_MD("get_format"),&ImageTexture::get_format);
+ ClassDB::bind_method(_MD("load","path"),&ImageTexture::load);
+ ClassDB::bind_method(_MD("set_data","image"),&ImageTexture::set_data);
+ ClassDB::bind_method(_MD("get_data","cube_side"),&ImageTexture::get_data);
+ ClassDB::bind_method(_MD("set_storage","mode"),&ImageTexture::set_storage);
+ ClassDB::bind_method(_MD("get_storage"),&ImageTexture::get_storage);
+ ClassDB::bind_method(_MD("set_lossy_storage_quality","quality"),&ImageTexture::set_lossy_storage_quality);
+ ClassDB::bind_method(_MD("get_lossy_storage_quality"),&ImageTexture::get_lossy_storage_quality);
+ ClassDB::bind_method(_MD("fix_alpha_edges"),&ImageTexture::fix_alpha_edges);
+ ClassDB::bind_method(_MD("premultiply_alpha"),&ImageTexture::premultiply_alpha);
+ ClassDB::bind_method(_MD("normal_to_xy"),&ImageTexture::normal_to_xy);
+ ClassDB::bind_method(_MD("shrink_x2_and_keep_size"),&ImageTexture::shrink_x2_and_keep_size);
+
+ ClassDB::bind_method(_MD("set_size_override","size"),&ImageTexture::set_size_override);
+ ClassDB::set_method_flags(get_class_static(),_SCS("fix_alpha_edges"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
+ ClassDB::set_method_flags(get_class_static(),_SCS("premultiply_alpha"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
+ ClassDB::set_method_flags(get_class_static(),_SCS("normal_to_xy"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
+ ClassDB::set_method_flags(get_class_static(),_SCS("shrink_x2_and_keep_size"),METHOD_FLAGS_DEFAULT|METHOD_FLAG_EDITOR);
+ ClassDB::bind_method(_MD("_reload_hook","rid"),&ImageTexture::_reload_hook);
BIND_CONSTANT( STORAGE_RAW );
@@ -549,14 +549,14 @@ Rect2 AtlasTexture::get_margin() const {
void AtlasTexture::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_atlas","atlas:Texture"),&AtlasTexture::set_atlas);
- ObjectTypeDB::bind_method(_MD("get_atlas:Texture"),&AtlasTexture::get_atlas);
+ ClassDB::bind_method(_MD("set_atlas","atlas:Texture"),&AtlasTexture::set_atlas);
+ ClassDB::bind_method(_MD("get_atlas:Texture"),&AtlasTexture::get_atlas);
- ObjectTypeDB::bind_method(_MD("set_region","region"),&AtlasTexture::set_region);
- ObjectTypeDB::bind_method(_MD("get_region"),&AtlasTexture::get_region);
+ ClassDB::bind_method(_MD("set_region","region"),&AtlasTexture::set_region);
+ ClassDB::bind_method(_MD("get_region"),&AtlasTexture::get_region);
- ObjectTypeDB::bind_method(_MD("set_margin","margin"),&AtlasTexture::set_margin);
- ObjectTypeDB::bind_method(_MD("get_margin"),&AtlasTexture::get_margin);
+ ClassDB::bind_method(_MD("set_margin","margin"),&AtlasTexture::set_margin);
+ ClassDB::bind_method(_MD("get_margin"),&AtlasTexture::get_margin);
ADD_SIGNAL(MethodInfo("atlas_changed"));
@@ -804,18 +804,18 @@ Ref<Texture> LargeTexture::get_piece_texture(int p_idx) const{
void LargeTexture::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("add_piece","ofs","texture:Texture"),&LargeTexture::add_piece);
- ObjectTypeDB::bind_method(_MD("set_piece_offset", "idx", "ofs"),&LargeTexture::set_piece_offset);
- ObjectTypeDB::bind_method(_MD("set_piece_texture","idx", "texture:Texture"),&LargeTexture::set_piece_texture);
- ObjectTypeDB::bind_method(_MD("set_size","size"),&LargeTexture::set_size);
- ObjectTypeDB::bind_method(_MD("clear"),&LargeTexture::clear);
+ ClassDB::bind_method(_MD("add_piece","ofs","texture:Texture"),&LargeTexture::add_piece);
+ ClassDB::bind_method(_MD("set_piece_offset", "idx", "ofs"),&LargeTexture::set_piece_offset);
+ ClassDB::bind_method(_MD("set_piece_texture","idx", "texture:Texture"),&LargeTexture::set_piece_texture);
+ ClassDB::bind_method(_MD("set_size","size"),&LargeTexture::set_size);
+ ClassDB::bind_method(_MD("clear"),&LargeTexture::clear);
- ObjectTypeDB::bind_method(_MD("get_piece_count"),&LargeTexture::get_piece_count);
- ObjectTypeDB::bind_method(_MD("get_piece_offset","idx"),&LargeTexture::get_piece_offset);
- ObjectTypeDB::bind_method(_MD("get_piece_texture:Texture","idx"),&LargeTexture::get_piece_texture);
+ ClassDB::bind_method(_MD("get_piece_count"),&LargeTexture::get_piece_count);
+ ClassDB::bind_method(_MD("get_piece_offset","idx"),&LargeTexture::get_piece_offset);
+ ClassDB::bind_method(_MD("get_piece_texture:Texture","idx"),&LargeTexture::get_piece_texture);
- ObjectTypeDB::bind_method(_MD("_set_data","data"),&LargeTexture::_set_data);
- ObjectTypeDB::bind_method(_MD("_get_data"),&LargeTexture::_get_data);
+ ClassDB::bind_method(_MD("_set_data","data"),&LargeTexture::_set_data);
+ ClassDB::bind_method(_MD("_get_data"),&LargeTexture::_get_data);
ADD_PROPERTY( PropertyInfo( Variant::ARRAY, "_data",PROPERTY_HINT_NONE,"",PROPERTY_USAGE_NOEDITOR), _SCS("_set_data"),_SCS("_get_data") );
@@ -1048,18 +1048,18 @@ void CubeMap::_get_property_list( List<PropertyInfo> *p_list) const {
void CubeMap::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_width"),&CubeMap::get_width);
- ObjectTypeDB::bind_method(_MD("get_height"),&CubeMap::get_height);
- ObjectTypeDB::bind_method(_MD("get_rid"),&CubeMap::get_rid);
- ObjectTypeDB::bind_method(_MD("set_flags","flags"),&CubeMap::set_flags);
- ObjectTypeDB::bind_method(_MD("get_flags"),&CubeMap::get_flags);
-
- ObjectTypeDB::bind_method(_MD("set_side","side","image"),&CubeMap::set_side);
- ObjectTypeDB::bind_method(_MD("get_side","side"),&CubeMap::get_side);
- ObjectTypeDB::bind_method(_MD("set_storage","mode"),&CubeMap::set_storage);
- ObjectTypeDB::bind_method(_MD("get_storage"),&CubeMap::get_storage);
- ObjectTypeDB::bind_method(_MD("set_lossy_storage_quality","quality"),&CubeMap::set_lossy_storage_quality);
- ObjectTypeDB::bind_method(_MD("get_lossy_storage_quality"),&CubeMap::get_lossy_storage_quality);
+ ClassDB::bind_method(_MD("get_width"),&CubeMap::get_width);
+ ClassDB::bind_method(_MD("get_height"),&CubeMap::get_height);
+ ClassDB::bind_method(_MD("get_rid"),&CubeMap::get_rid);
+ ClassDB::bind_method(_MD("set_flags","flags"),&CubeMap::set_flags);
+ ClassDB::bind_method(_MD("get_flags"),&CubeMap::get_flags);
+
+ ClassDB::bind_method(_MD("set_side","side","image"),&CubeMap::set_side);
+ ClassDB::bind_method(_MD("get_side","side"),&CubeMap::get_side);
+ ClassDB::bind_method(_MD("set_storage","mode"),&CubeMap::set_storage);
+ ClassDB::bind_method(_MD("get_storage"),&CubeMap::get_storage);
+ ClassDB::bind_method(_MD("set_lossy_storage_quality","quality"),&CubeMap::set_lossy_storage_quality);
+ ClassDB::bind_method(_MD("get_lossy_storage_quality"),&CubeMap::get_lossy_storage_quality);
BIND_CONSTANT( STORAGE_RAW );
diff --git a/scene/resources/texture.h b/scene/resources/texture.h
index 945541e102..aac3514af3 100644
--- a/scene/resources/texture.h
+++ b/scene/resources/texture.h
@@ -41,7 +41,7 @@
class Texture : public Resource {
- OBJ_TYPE( Texture, Resource );
+ GDCLASS( Texture, Resource );
OBJ_SAVE_TYPE( Texture ); //children are all saved as Texture, so they can be exchanged
protected:
@@ -85,7 +85,7 @@ VARIANT_ENUM_CAST( Texture::Flags );
class ImageTexture : public Texture {
- OBJ_TYPE( ImageTexture, Texture );
+ GDCLASS( ImageTexture, Texture );
RES_BASE_EXTENSION("tex");
public:
enum Storage {
@@ -164,7 +164,7 @@ VARIANT_ENUM_CAST( ImageTexture::Storage );
class AtlasTexture : public Texture {
- OBJ_TYPE( AtlasTexture, Texture );
+ GDCLASS( AtlasTexture, Texture );
RES_BASE_EXTENSION("atex");
protected:
@@ -205,7 +205,7 @@ public:
class LargeTexture : public Texture {
- OBJ_TYPE( LargeTexture, Texture );
+ GDCLASS( LargeTexture, Texture );
RES_BASE_EXTENSION("ltex");
protected:
@@ -256,7 +256,7 @@ public:
class CubeMap : public Resource {
- OBJ_TYPE( CubeMap, Resource );
+ GDCLASS( CubeMap, Resource );
RES_BASE_EXTENSION("cbm");
public:
enum Storage {
diff --git a/scene/resources/theme.cpp b/scene/resources/theme.cpp
index da9056541c..2e3afbf057 100644
--- a/scene/resources/theme.cpp
+++ b/scene/resources/theme.cpp
@@ -664,48 +664,48 @@ void Theme::get_type_list(List<StringName> *p_list) const {
void Theme::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("set_icon","name","type","texture:Texture"),&Theme::set_icon);
- ObjectTypeDB::bind_method(_MD("get_icon:Texture","name","type"),&Theme::get_icon);
- ObjectTypeDB::bind_method(_MD("has_icon","name","type"),&Theme::has_icon);
- ObjectTypeDB::bind_method(_MD("clear_icon","name","type"),&Theme::clear_icon);
- ObjectTypeDB::bind_method(_MD("get_icon_list","type"),&Theme::_get_icon_list);
+ ClassDB::bind_method(_MD("set_icon","name","type","texture:Texture"),&Theme::set_icon);
+ ClassDB::bind_method(_MD("get_icon:Texture","name","type"),&Theme::get_icon);
+ ClassDB::bind_method(_MD("has_icon","name","type"),&Theme::has_icon);
+ ClassDB::bind_method(_MD("clear_icon","name","type"),&Theme::clear_icon);
+ ClassDB::bind_method(_MD("get_icon_list","type"),&Theme::_get_icon_list);
- ObjectTypeDB::bind_method(_MD("set_stylebox","name","type","texture:StyleBox"),&Theme::set_stylebox);
- ObjectTypeDB::bind_method(_MD("get_stylebox:StyleBox","name","type"),&Theme::get_stylebox);
- ObjectTypeDB::bind_method(_MD("has_stylebox","name","type"),&Theme::has_stylebox);
- ObjectTypeDB::bind_method(_MD("clear_stylebox","name","type"),&Theme::clear_stylebox);
- ObjectTypeDB::bind_method(_MD("get_stylebox_list","type"),&Theme::_get_stylebox_list);
- ObjectTypeDB::bind_method(_MD("get_stylebox_types"),&Theme::_get_stylebox_types);
+ ClassDB::bind_method(_MD("set_stylebox","name","type","texture:StyleBox"),&Theme::set_stylebox);
+ ClassDB::bind_method(_MD("get_stylebox:StyleBox","name","type"),&Theme::get_stylebox);
+ ClassDB::bind_method(_MD("has_stylebox","name","type"),&Theme::has_stylebox);
+ ClassDB::bind_method(_MD("clear_stylebox","name","type"),&Theme::clear_stylebox);
+ ClassDB::bind_method(_MD("get_stylebox_list","type"),&Theme::_get_stylebox_list);
+ ClassDB::bind_method(_MD("get_stylebox_types"),&Theme::_get_stylebox_types);
- ObjectTypeDB::bind_method(_MD("set_font","name","type","font:Font"),&Theme::set_font);
- ObjectTypeDB::bind_method(_MD("get_font:Font","name","type"),&Theme::get_font);
- ObjectTypeDB::bind_method(_MD("has_font","name","type"),&Theme::has_font);
- ObjectTypeDB::bind_method(_MD("clear_font","name","type"),&Theme::clear_font);
- ObjectTypeDB::bind_method(_MD("get_font_list","type"),&Theme::_get_font_list);
+ ClassDB::bind_method(_MD("set_font","name","type","font:Font"),&Theme::set_font);
+ ClassDB::bind_method(_MD("get_font:Font","name","type"),&Theme::get_font);
+ ClassDB::bind_method(_MD("has_font","name","type"),&Theme::has_font);
+ ClassDB::bind_method(_MD("clear_font","name","type"),&Theme::clear_font);
+ ClassDB::bind_method(_MD("get_font_list","type"),&Theme::_get_font_list);
- ObjectTypeDB::bind_method(_MD("set_color","name","type","color"),&Theme::set_color);
- ObjectTypeDB::bind_method(_MD("get_color","name","type"),&Theme::get_color);
- ObjectTypeDB::bind_method(_MD("has_color","name","type"),&Theme::has_color);
- ObjectTypeDB::bind_method(_MD("clear_color","name","type"),&Theme::clear_color);
- ObjectTypeDB::bind_method(_MD("get_color_list","type"),&Theme::_get_color_list);
+ ClassDB::bind_method(_MD("set_color","name","type","color"),&Theme::set_color);
+ ClassDB::bind_method(_MD("get_color","name","type"),&Theme::get_color);
+ ClassDB::bind_method(_MD("has_color","name","type"),&Theme::has_color);
+ ClassDB::bind_method(_MD("clear_color","name","type"),&Theme::clear_color);
+ ClassDB::bind_method(_MD("get_color_list","type"),&Theme::_get_color_list);
- ObjectTypeDB::bind_method(_MD("set_constant","name","type","constant"),&Theme::set_constant);
- ObjectTypeDB::bind_method(_MD("get_constant","name","type"),&Theme::get_constant);
- ObjectTypeDB::bind_method(_MD("has_constant","name","type"),&Theme::has_constant);
- ObjectTypeDB::bind_method(_MD("clear_constant","name","type"),&Theme::clear_constant);
- ObjectTypeDB::bind_method(_MD("get_constant_list","type"),&Theme::_get_constant_list);
+ ClassDB::bind_method(_MD("set_constant","name","type","constant"),&Theme::set_constant);
+ ClassDB::bind_method(_MD("get_constant","name","type"),&Theme::get_constant);
+ ClassDB::bind_method(_MD("has_constant","name","type"),&Theme::has_constant);
+ ClassDB::bind_method(_MD("clear_constant","name","type"),&Theme::clear_constant);
+ ClassDB::bind_method(_MD("get_constant_list","type"),&Theme::_get_constant_list);
- ObjectTypeDB::bind_method(_MD("set_default_font","font"),&Theme::set_default_theme_font);
- ObjectTypeDB::bind_method(_MD("get_default_font"),&Theme::get_default_theme_font);
+ ClassDB::bind_method(_MD("set_default_font","font"),&Theme::set_default_theme_font);
+ ClassDB::bind_method(_MD("get_default_font"),&Theme::get_default_theme_font);
- ObjectTypeDB::bind_method(_MD("get_type_list","type"),&Theme::_get_type_list);
+ ClassDB::bind_method(_MD("get_type_list","type"),&Theme::_get_type_list);
- ObjectTypeDB::bind_method(_MD("_emit_theme_changed"),&Theme::_emit_theme_changed);
+ ClassDB::bind_method(_MD("_emit_theme_changed"),&Theme::_emit_theme_changed);
- ObjectTypeDB::bind_method("copy_default_theme",&Theme::copy_default_theme);
+ ClassDB::bind_method("copy_default_theme",&Theme::copy_default_theme);
ADD_PROPERTY(PropertyInfo(Variant::OBJECT,"default_font",PROPERTY_HINT_RESOURCE_TYPE,"Font"),_SCS("set_default_font"),_SCS("get_default_font"));
diff --git a/scene/resources/theme.h b/scene/resources/theme.h
index 1bce5e1213..94ac910e9f 100644
--- a/scene/resources/theme.h
+++ b/scene/resources/theme.h
@@ -41,7 +41,7 @@
*/
class Theme : public Resource {
- OBJ_TYPE( Theme, Resource );
+ GDCLASS( Theme, Resource );
RES_BASE_EXTENSION("thm");
static Ref<Theme> default_theme;
diff --git a/scene/resources/tile_set.cpp b/scene/resources/tile_set.cpp
index e9c5ac12bb..1811dee384 100644
--- a/scene/resources/tile_set.cpp
+++ b/scene/resources/tile_set.cpp
@@ -407,37 +407,37 @@ void TileSet::clear() {
void TileSet::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("create_tile","id"),&TileSet::create_tile);
- ObjectTypeDB::bind_method(_MD("tile_set_name","id","name"),&TileSet::tile_set_name);
- ObjectTypeDB::bind_method(_MD("tile_get_name","id"),&TileSet::tile_get_name);
- ObjectTypeDB::bind_method(_MD("tile_set_texture","id","texture:Texture"),&TileSet::tile_set_texture);
- ObjectTypeDB::bind_method(_MD("tile_get_texture:Texture","id"),&TileSet::tile_get_texture);
- ObjectTypeDB::bind_method(_MD("tile_set_material","id","material:CanvasItemMaterial"),&TileSet::tile_set_material);
- ObjectTypeDB::bind_method(_MD("tile_get_material:CanvasItemMaterial","id"),&TileSet::tile_get_material);
- ObjectTypeDB::bind_method(_MD("tile_set_texture_offset","id","texture_offset"),&TileSet::tile_set_texture_offset);
- ObjectTypeDB::bind_method(_MD("tile_get_texture_offset","id"),&TileSet::tile_get_texture_offset);
- ObjectTypeDB::bind_method(_MD("tile_set_shape_offset","id","shape_offset"),&TileSet::tile_set_shape_offset);
- ObjectTypeDB::bind_method(_MD("tile_get_shape_offset","id"),&TileSet::tile_get_shape_offset);
- ObjectTypeDB::bind_method(_MD("tile_set_region","id","region"),&TileSet::tile_set_region);
- ObjectTypeDB::bind_method(_MD("tile_get_region","id"),&TileSet::tile_get_region);
- ObjectTypeDB::bind_method(_MD("tile_set_shape","id","shape:Shape2D"),&TileSet::tile_set_shape);
- ObjectTypeDB::bind_method(_MD("tile_get_shape:Shape2D","id"),&TileSet::tile_get_shape);
- ObjectTypeDB::bind_method(_MD("tile_set_shapes","id","shapes"),&TileSet::_tile_set_shapes);
- ObjectTypeDB::bind_method(_MD("tile_get_shapes","id"),&TileSet::_tile_get_shapes);
- ObjectTypeDB::bind_method(_MD("tile_set_navigation_polygon","id","navigation_polygon:NavigationPolygon"),&TileSet::tile_set_navigation_polygon);
- ObjectTypeDB::bind_method(_MD("tile_get_navigation_polygon:NavigationPolygon","id"),&TileSet::tile_get_navigation_polygon);
- ObjectTypeDB::bind_method(_MD("tile_set_navigation_polygon_offset","id","navigation_polygon_offset"),&TileSet::tile_set_navigation_polygon_offset);
- ObjectTypeDB::bind_method(_MD("tile_get_navigation_polygon_offset","id"),&TileSet::tile_get_navigation_polygon_offset);
- ObjectTypeDB::bind_method(_MD("tile_set_light_occluder","id","light_occluder:OccluderPolygon2D"),&TileSet::tile_set_light_occluder);
- ObjectTypeDB::bind_method(_MD("tile_get_light_occluder:OccluderPolygon2D","id"),&TileSet::tile_get_light_occluder);
- ObjectTypeDB::bind_method(_MD("tile_set_occluder_offset","id","occluder_offset"),&TileSet::tile_set_occluder_offset);
- ObjectTypeDB::bind_method(_MD("tile_get_occluder_offset","id"),&TileSet::tile_get_occluder_offset);
-
- ObjectTypeDB::bind_method(_MD("remove_tile","id"),&TileSet::remove_tile);
- ObjectTypeDB::bind_method(_MD("clear"),&TileSet::clear);
- ObjectTypeDB::bind_method(_MD("get_last_unused_tile_id"),&TileSet::get_last_unused_tile_id);
- ObjectTypeDB::bind_method(_MD("find_tile_by_name","name"),&TileSet::find_tile_by_name);
- ObjectTypeDB::bind_method(_MD("get_tiles_ids", "name"), &TileSet::_get_tiles_ids);
+ ClassDB::bind_method(_MD("create_tile","id"),&TileSet::create_tile);
+ ClassDB::bind_method(_MD("tile_set_name","id","name"),&TileSet::tile_set_name);
+ ClassDB::bind_method(_MD("tile_get_name","id"),&TileSet::tile_get_name);
+ ClassDB::bind_method(_MD("tile_set_texture","id","texture:Texture"),&TileSet::tile_set_texture);
+ ClassDB::bind_method(_MD("tile_get_texture:Texture","id"),&TileSet::tile_get_texture);
+ ClassDB::bind_method(_MD("tile_set_material","id","material:CanvasItemMaterial"),&TileSet::tile_set_material);
+ ClassDB::bind_method(_MD("tile_get_material:CanvasItemMaterial","id"),&TileSet::tile_get_material);
+ ClassDB::bind_method(_MD("tile_set_texture_offset","id","texture_offset"),&TileSet::tile_set_texture_offset);
+ ClassDB::bind_method(_MD("tile_get_texture_offset","id"),&TileSet::tile_get_texture_offset);
+ ClassDB::bind_method(_MD("tile_set_shape_offset","id","shape_offset"),&TileSet::tile_set_shape_offset);
+ ClassDB::bind_method(_MD("tile_get_shape_offset","id"),&TileSet::tile_get_shape_offset);
+ ClassDB::bind_method(_MD("tile_set_region","id","region"),&TileSet::tile_set_region);
+ ClassDB::bind_method(_MD("tile_get_region","id"),&TileSet::tile_get_region);
+ ClassDB::bind_method(_MD("tile_set_shape","id","shape:Shape2D"),&TileSet::tile_set_shape);
+ ClassDB::bind_method(_MD("tile_get_shape:Shape2D","id"),&TileSet::tile_get_shape);
+ ClassDB::bind_method(_MD("tile_set_shapes","id","shapes"),&TileSet::_tile_set_shapes);
+ ClassDB::bind_method(_MD("tile_get_shapes","id"),&TileSet::_tile_get_shapes);
+ ClassDB::bind_method(_MD("tile_set_navigation_polygon","id","navigation_polygon:NavigationPolygon"),&TileSet::tile_set_navigation_polygon);
+ ClassDB::bind_method(_MD("tile_get_navigation_polygon:NavigationPolygon","id"),&TileSet::tile_get_navigation_polygon);
+ ClassDB::bind_method(_MD("tile_set_navigation_polygon_offset","id","navigation_polygon_offset"),&TileSet::tile_set_navigation_polygon_offset);
+ ClassDB::bind_method(_MD("tile_get_navigation_polygon_offset","id"),&TileSet::tile_get_navigation_polygon_offset);
+ ClassDB::bind_method(_MD("tile_set_light_occluder","id","light_occluder:OccluderPolygon2D"),&TileSet::tile_set_light_occluder);
+ ClassDB::bind_method(_MD("tile_get_light_occluder:OccluderPolygon2D","id"),&TileSet::tile_get_light_occluder);
+ ClassDB::bind_method(_MD("tile_set_occluder_offset","id","occluder_offset"),&TileSet::tile_set_occluder_offset);
+ ClassDB::bind_method(_MD("tile_get_occluder_offset","id"),&TileSet::tile_get_occluder_offset);
+
+ ClassDB::bind_method(_MD("remove_tile","id"),&TileSet::remove_tile);
+ ClassDB::bind_method(_MD("clear"),&TileSet::clear);
+ ClassDB::bind_method(_MD("get_last_unused_tile_id"),&TileSet::get_last_unused_tile_id);
+ ClassDB::bind_method(_MD("find_tile_by_name","name"),&TileSet::find_tile_by_name);
+ ClassDB::bind_method(_MD("get_tiles_ids", "name"), &TileSet::_get_tiles_ids);
}
diff --git a/scene/resources/tile_set.h b/scene/resources/tile_set.h
index e0ae0330b2..ce40e5ebe3 100644
--- a/scene/resources/tile_set.h
+++ b/scene/resources/tile_set.h
@@ -37,7 +37,7 @@
class TileSet : public Resource {
- OBJ_TYPE( TileSet, Resource );
+ GDCLASS( TileSet, Resource );
struct Data {
diff --git a/scene/resources/video_stream.h b/scene/resources/video_stream.h
index ce01a766ca..bcd25c0336 100644
--- a/scene/resources/video_stream.h
+++ b/scene/resources/video_stream.h
@@ -35,7 +35,7 @@
class VideoStreamPlayback : public Resource {
- OBJ_TYPE(VideoStreamPlayback,Resource);
+ GDCLASS(VideoStreamPlayback,Resource);
protected:
static void _bind_methods();
@@ -77,7 +77,7 @@ public:
class VideoStream : public Resource {
- OBJ_TYPE( VideoStream, Resource );
+ GDCLASS( VideoStream, Resource );
OBJ_SAVE_TYPE( VideoStream ); //children are all saved as AudioStream, so they can be exchanged
public:
diff --git a/scene/resources/world.cpp b/scene/resources/world.cpp
index e75c4821d7..e89a460558 100644
--- a/scene/resources/world.cpp
+++ b/scene/resources/world.cpp
@@ -314,12 +314,12 @@ PhysicsDirectSpaceState *World::get_direct_space_state() {
void World::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_space"),&World::get_space);
- ObjectTypeDB::bind_method(_MD("get_scenario"),&World::get_scenario);
- ObjectTypeDB::bind_method(_MD("get_sound_space"),&World::get_sound_space);
- ObjectTypeDB::bind_method(_MD("set_environment","env:Environment"),&World::set_environment);
- ObjectTypeDB::bind_method(_MD("get_environment:Environment"),&World::get_environment);
- ObjectTypeDB::bind_method(_MD("get_direct_space_state:PhysicsDirectSpaceState"),&World::get_direct_space_state);
+ ClassDB::bind_method(_MD("get_space"),&World::get_space);
+ ClassDB::bind_method(_MD("get_scenario"),&World::get_scenario);
+ ClassDB::bind_method(_MD("get_sound_space"),&World::get_sound_space);
+ ClassDB::bind_method(_MD("set_environment","env:Environment"),&World::set_environment);
+ ClassDB::bind_method(_MD("get_environment:Environment"),&World::get_environment);
+ ClassDB::bind_method(_MD("get_direct_space_state:PhysicsDirectSpaceState"),&World::get_direct_space_state);
ADD_PROPERTY(PropertyInfo(Variant::OBJECT,"environment",PROPERTY_HINT_RESOURCE_TYPE,"Environment"),_SCS("set_environment"),_SCS("get_environment"));
}
diff --git a/scene/resources/world.h b/scene/resources/world.h
index 84d69482bd..8244261243 100644
--- a/scene/resources/world.h
+++ b/scene/resources/world.h
@@ -40,7 +40,7 @@ class Camera;
class VisibilityNotifier;
class World : public Resource {
- OBJ_TYPE(World, Resource);
+ GDCLASS(World, Resource);
RES_BASE_EXTENSION("wrd");
private:
RID space;
diff --git a/scene/resources/world_2d.cpp b/scene/resources/world_2d.cpp
index 8c39d70b2d..46434bfd60 100644
--- a/scene/resources/world_2d.cpp
+++ b/scene/resources/world_2d.cpp
@@ -382,11 +382,11 @@ RID World2D::get_sound_space() {
void World2D::_bind_methods() {
- ObjectTypeDB::bind_method(_MD("get_canvas"),&World2D::get_canvas);
- ObjectTypeDB::bind_method(_MD("get_space"),&World2D::get_space);
- ObjectTypeDB::bind_method(_MD("get_sound_space"),&World2D::get_sound_space);
+ ClassDB::bind_method(_MD("get_canvas"),&World2D::get_canvas);
+ ClassDB::bind_method(_MD("get_space"),&World2D::get_space);
+ ClassDB::bind_method(_MD("get_sound_space"),&World2D::get_sound_space);
- ObjectTypeDB::bind_method(_MD("get_direct_space_state:Physics2DDirectSpaceState"),&World2D::get_direct_space_state);
+ ClassDB::bind_method(_MD("get_direct_space_state:Physics2DDirectSpaceState"),&World2D::get_direct_space_state);
}
diff --git a/scene/resources/world_2d.h b/scene/resources/world_2d.h
index 91ddc8f600..a9110b3bd9 100644
--- a/scene/resources/world_2d.h
+++ b/scene/resources/world_2d.h
@@ -39,7 +39,7 @@ class Viewport;
class World2D : public Resource {
- OBJ_TYPE( World2D, Resource );
+ GDCLASS( World2D, Resource );
RID canvas;
RID space;