summaryrefslogtreecommitdiff
path: root/scene
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-10-23 07:42:52 +0200
committerGitHub <noreply@github.com>2019-10-23 07:42:52 +0200
commit19fa163d9a3bd3bfcb5d030b9134bff2b850323c (patch)
tree74c5351a476e31360b81320084902a9e84033261 /scene
parentf022e4748c181b1af16fba134fb328a6b9954e30 (diff)
parent6c0ef9f729424e9c11aa475ecee5f8c07d0913a3 (diff)
Merge pull request #32992 from KoBeWi/AUTOVECTORZ
Auto-increment frame_coords when keying
Diffstat (limited to 'scene')
-rw-r--r--scene/2d/sprite.cpp4
-rw-r--r--scene/3d/sprite_3d.cpp4
2 files changed, 8 insertions, 0 deletions
diff --git a/scene/2d/sprite.cpp b/scene/2d/sprite.cpp
index d2e1e494e3..8cdfceea52 100644
--- a/scene/2d/sprite.cpp
+++ b/scene/2d/sprite.cpp
@@ -387,6 +387,10 @@ void Sprite::_validate_property(PropertyInfo &property) const {
property.hint_string = "0," + itos(vframes * hframes - 1) + ",1";
property.usage |= PROPERTY_USAGE_KEYING_INCREMENTS;
}
+
+ if (property.name == "frame_coords") {
+ property.usage |= PROPERTY_USAGE_KEYING_INCREMENTS;
+ }
}
void Sprite::_texture_changed() {
diff --git a/scene/3d/sprite_3d.cpp b/scene/3d/sprite_3d.cpp
index a8d2f4d415..adcd80b0ab 100644
--- a/scene/3d/sprite_3d.cpp
+++ b/scene/3d/sprite_3d.cpp
@@ -662,6 +662,10 @@ void Sprite3D::_validate_property(PropertyInfo &property) const {
property.hint_string = "0," + itos(vframes * hframes - 1) + ",1";
property.usage |= PROPERTY_USAGE_KEYING_INCREMENTS;
}
+
+ if (property.name == "frame_coords") {
+ property.usage |= PROPERTY_USAGE_KEYING_INCREMENTS;
+ }
}
void Sprite3D::_bind_methods() {