diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-09-27 09:51:24 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-27 09:51:24 +0200 |
commit | 5e9194086dfce421a4b0657c347b53db22b64b87 (patch) | |
tree | 158d748c38e1df11cac2a82f3b23d28205a7bfbe | |
parent | fc481db1c3187688d54b5afdb7a1ebb3e4d506c2 (diff) | |
parent | bcc0493a4a1dcf0ba5ed5c34d0d0317d90dfd24c (diff) |
Merge pull request #35924 from doot24/fix_#35863
Fixed Gradient.remove_point not allowing fewer than two points.
-rw-r--r-- | scene/resources/gradient.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/resources/gradient.cpp b/scene/resources/gradient.cpp index 4bcc52776b..b720653f91 100644 --- a/scene/resources/gradient.cpp +++ b/scene/resources/gradient.cpp @@ -129,7 +129,7 @@ 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); + ERR_FAIL_COND(points.size() <= 1); points.remove(p_index); emit_signal(CoreStringNames::get_singleton()->changed); } |