Merge pull request #21842 from merumelu/curve-point-count
Bind Curve::get_point_count
This commit is contained in:
commit
584f1ab0c5
2 changed files with 8 additions and 0 deletions
|
@ -49,6 +49,13 @@
|
||||||
Removes all points from the curve.
|
Removes all points from the curve.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
|
<method name="get_point_count" qualifiers="const">
|
||||||
|
<return type="int">
|
||||||
|
</return>
|
||||||
|
<description>
|
||||||
|
Returns the number of points describing the curve.
|
||||||
|
</description>
|
||||||
|
</method>
|
||||||
<method name="get_point_left_mode" qualifiers="const">
|
<method name="get_point_left_mode" qualifiers="const">
|
||||||
<return type="int" enum="Curve.TangentMode">
|
<return type="int" enum="Curve.TangentMode">
|
||||||
</return>
|
</return>
|
||||||
|
|
|
@ -491,6 +491,7 @@ void Curve::ensure_default_setup(float p_min, float p_max) {
|
||||||
|
|
||||||
void Curve::_bind_methods() {
|
void Curve::_bind_methods() {
|
||||||
|
|
||||||
|
ClassDB::bind_method(D_METHOD("get_point_count"), &Curve::get_point_count);
|
||||||
ClassDB::bind_method(D_METHOD("add_point", "position", "left_tangent", "right_tangent", "left_mode", "right_mode"), &Curve::add_point, DEFVAL(0), DEFVAL(0), DEFVAL(TANGENT_FREE), DEFVAL(TANGENT_FREE));
|
ClassDB::bind_method(D_METHOD("add_point", "position", "left_tangent", "right_tangent", "left_mode", "right_mode"), &Curve::add_point, DEFVAL(0), DEFVAL(0), DEFVAL(TANGENT_FREE), DEFVAL(TANGENT_FREE));
|
||||||
ClassDB::bind_method(D_METHOD("remove_point", "index"), &Curve::remove_point);
|
ClassDB::bind_method(D_METHOD("remove_point", "index"), &Curve::remove_point);
|
||||||
ClassDB::bind_method(D_METHOD("clear_points"), &Curve::clear_points);
|
ClassDB::bind_method(D_METHOD("clear_points"), &Curve::clear_points);
|
||||||
|
|
Loading…
Reference in a new issue