summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Warden <nathanwardenlee@icloud.com>2015-05-02 12:17:59 -0500
committerNathan Warden <nathanwardenlee@icloud.com>2015-05-02 12:17:59 -0500
commit62129469278b284b91845a678b517c04cefbebfe (patch)
treeb372630b37c375f6236a4c52f8878996c129d481
parent524d9fad59cd596bb291648c8c2e1b4a46fb2d02 (diff)
Fixed some items caught in cppcheck
-rw-r--r--scene/3d/sprite_3d.cpp2
-rw-r--r--scene/resources/animation.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/scene/3d/sprite_3d.cpp b/scene/3d/sprite_3d.cpp
index 35f6523c6a..4952f742df 100644
--- a/scene/3d/sprite_3d.cpp
+++ b/scene/3d/sprite_3d.cpp
@@ -292,7 +292,7 @@ SpriteBase3D::SpriteBase3D() {
parent_sprite=NULL;
pI=NULL;
- for(int i=0;i<4;i++)
+ for(int i=0;i<FLAG_MAX;i++)
flags[i]=i==FLAG_TRANSPARENT;
axis=Vector3::AXIS_Z;
diff --git a/scene/resources/animation.cpp b/scene/resources/animation.cpp
index 0f11a66703..095406dad9 100644
--- a/scene/resources/animation.cpp
+++ b/scene/resources/animation.cpp
@@ -1216,8 +1216,8 @@ T Animation::_interpolate( const Vector< TKey<T> >& p_keys, float p_time, Inter
if (p_ok)
*p_ok=true;
-
- int next;
+
+ int next=0;
float c=0;
// prepare for all cases of interpolation