diff options
Diffstat (limited to 'scene/2d')
-rw-r--r-- | scene/2d/camera_2d.cpp | 2 | ||||
-rw-r--r-- | scene/2d/path_2d.cpp | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/scene/2d/camera_2d.cpp b/scene/2d/camera_2d.cpp index 2616d1f09e..76b354805c 100644 --- a/scene/2d/camera_2d.cpp +++ b/scene/2d/camera_2d.cpp @@ -439,7 +439,7 @@ void Camera2D::clear_current() { void Camera2D::set_limit(Side p_side, int p_limit) { ERR_FAIL_INDEX((int)p_side, 4); limit[p_side] = p_limit; - update(); + _update_scroll(); } int Camera2D::get_limit(Side p_side) const { diff --git a/scene/2d/path_2d.cpp b/scene/2d/path_2d.cpp index 8eb48ffb30..9862c4bfb1 100644 --- a/scene/2d/path_2d.cpp +++ b/scene/2d/path_2d.cpp @@ -304,6 +304,7 @@ void PathFollow2D::_bind_methods() { } void PathFollow2D::set_offset(real_t p_offset) { + ERR_FAIL_COND(!isfinite(p_offset)); offset = p_offset; if (path) { if (path->get_curve().is_valid()) { |