DEADSOFTWARE

Delta time in physics and animation
[cavedroid.git] / core / src / ru / deadsoftware / cavedroid / game / objects / Drop.java
index 07a2f6cf68b9ea8f6ecaeefbfbd0b604a4b48df3..e9f2e61f489ac4b3a276075c4ed1479f2483ce14 100644 (file)
@@ -106,9 +106,9 @@ public class Drop extends Rectangle implements Serializable {
 //        }
     }
 
-    public void move() {
-        x += velocity.x;
-        y += velocity.y;
+    public void move(float delta) {
+        x += velocity.x * delta;
+        y += velocity.y * delta;
         checkWorldBounds();
         y = MathUtils.round(y);
     }