summaryrefslogtreecommitdiffstats
path: root/scene/resources/sprite_frames.cpp
diff options
context:
space:
mode:
authorAaron Franke <arnfranke@yahoo.com>2021-02-01 21:16:37 -0500
committerAaron Franke <arnfranke@yahoo.com>2021-08-09 14:05:42 -0500
commit84f720966c74d5b37f70e21867e9e3e6a1e44c36 (patch)
tree770bb6c7c266c5266f4de3ceab52e756b55bf440 /scene/resources/sprite_frames.cpp
parent78d33a6e24a3977fc3a2c66808d7cbdddd3add11 (diff)
downloadredot-engine-84f720966c74d5b37f70e21867e9e3e6a1e44c36.tar.gz
Use doubles for time in many other places
Diffstat (limited to 'scene/resources/sprite_frames.cpp')
-rw-r--r--scene/resources/sprite_frames.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/scene/resources/sprite_frames.cpp b/scene/resources/sprite_frames.cpp
index e9adf67559..140c6f821f 100644
--- a/scene/resources/sprite_frames.cpp
+++ b/scene/resources/sprite_frames.cpp
@@ -122,14 +122,14 @@ Vector<String> SpriteFrames::get_animation_names() const {
return names;
}
-void SpriteFrames::set_animation_speed(const StringName &p_anim, float p_fps) {
+void SpriteFrames::set_animation_speed(const StringName &p_anim, double p_fps) {
ERR_FAIL_COND_MSG(p_fps < 0, "Animation speed cannot be negative (" + itos(p_fps) + ").");
Map<StringName, Anim>::Element *E = animations.find(p_anim);
ERR_FAIL_COND_MSG(!E, "Animation '" + String(p_anim) + "' doesn't exist.");
E->get().speed = p_fps;
}
-float SpriteFrames::get_animation_speed(const StringName &p_anim) const {
+double SpriteFrames::get_animation_speed(const StringName &p_anim) const {
const Map<StringName, Anim>::Element *E = animations.find(p_anim);
ERR_FAIL_COND_V_MSG(!E, 0, "Animation '" + String(p_anim) + "' doesn't exist.");
return E->get().speed;