summaryrefslogtreecommitdiff
path: root/scene/resources/gradient.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/resources/gradient.cpp')
-rw-r--r--scene/resources/gradient.cpp4
1 files changed, 0 insertions, 4 deletions
diff --git a/scene/resources/gradient.cpp b/scene/resources/gradient.cpp
index 7bce04beaf..2ccabe0b80 100644
--- a/scene/resources/gradient.cpp
+++ b/scene/resources/gradient.cpp
@@ -52,7 +52,6 @@ Gradient::~Gradient() {
}
void Gradient::_bind_methods() {
-
ClassDB::bind_method(D_METHOD("add_point", "offset", "color"), &Gradient::add_point);
ClassDB::bind_method(D_METHOD("remove_point", "offset"), &Gradient::remove_point);
@@ -118,7 +117,6 @@ Vector<Gradient::Point> &Gradient::get_points() {
}
void Gradient::add_point(float p_offset, const Color &p_color) {
-
Point p;
p.offset = p_offset;
p.color = p_color;
@@ -129,7 +127,6 @@ void Gradient::add_point(float p_offset, const Color &p_color) {
}
void Gradient::remove_point(int p_index) {
-
ERR_FAIL_INDEX(p_index, points.size());
ERR_FAIL_COND(points.size() <= 2);
points.remove(p_index);
@@ -143,7 +140,6 @@ void Gradient::set_points(Vector<Gradient::Point> &p_points) {
}
void Gradient::set_offset(int pos, const float offset) {
-
ERR_FAIL_COND(pos < 0);
if (points.size() <= pos)
points.resize(pos + 1);