ArrayUtils.rotateRight()

<static> rotateRight(array) → {any}

Moves the element from the end of the array to the start, shifting all items in the process.
The "rotation" happens to the right.

Before: [ A, B, C, D, E, F ]
After: [ F, A, B, C, D, E ]

See also Phaser.ArrayUtils.rotateLeft.

Parameters
Name Type Description
array Array.<any>

The array to rotate. The array is modified.

Returns
any -

The shifted value.

Source code: utils/ArrayUtils.js (Line 195)
doc_phaser
2017-02-14 10:36:19
Comments
Leave a Comment

Please login to continue.