We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 834a582 commit 9ea3eb1Copy full SHA for 9ea3eb1
1 file changed
src/tweens/tween/Tween.js
@@ -344,6 +344,23 @@ var Tween = new Class({
344
this.callbackScope;
345
},
346
347
+ /**
348
+ * Returns the current value of the specified Tween Data.
349
+ *
350
+ * @method Phaser.Tweens.Tween#getValue
351
+ * @since 3.0.0
352
353
+ * @param {integer} [index=0] - The Tween Data to return the value from.
354
355
+ * @return {number} The value of the requested Tween Data.
356
+ */
357
+ getValue: function (index)
358
+ {
359
+ if (index === undefined) { index = 0; }
360
+
361
+ return this.data[index].current;
362
+ },
363
364
/**
365
* Set the scale the time applied to this Tween. A value of 1 runs in real-time. A value of 0.5 runs 50% slower, and so on.
366
*
0 commit comments