Skip to content

Commit de3d749

Browse files
committed
Farthest swapped for the more common Furthest.
1 parent 56759f4 commit de3d749

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ You can read all about the philosophy behind Lazer [here](http://phaser.io/news/
338338

339339
* Phaser.Line.intersectsRectangle checks for intersection between a Line and a Rectangle, or any Rectangle-like object such as a Sprite or Body.
340340
* Group.getClosestTo will return the child closest to the given point (thanks @Nuuf #2504)
341-
* Group.getFarthestFrom will return the child farthest away from the given point (thanks @Nuuf #2504)
341+
* Group.getFurthestFrom will return the child farthest away from the given point (thanks @Nuuf #2504)
342342
* Animation.reverse will reverse the currently playing animation direction (thanks @gotenxds #2505)
343343
* Animation.reverseOnce will reverse the animation direction for the current, or next animation only (thanks @gotenxds #2505)
344344
* The way the display list updates and Camera movements are handled has been completely revamped, which should result is significantly smoother motion when the Camera is following tweened or physics controlled sprites. The `Stage.postUpdate` function is now vastly reduced in complexity. It takes control over updating the display list (calling `updateTransform` on itself), rather than letting the Canvas or WebGL renderers do this. Because of this change, the `Camera.updateTarget` function uses the Sprites `worldPosition` property instead, which is now frame accurate (thanks @whig @Upperfoot @Whoisnt @hexus #2482)

src/core/Group.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2019,11 +2019,11 @@ Phaser.Group.prototype.getClosestTo = function (object) {
20192019
*
20202020
* 'furthest away' is determined by the distance from the objects `x` and `y` properties compared to the childs `x` and `y` properties.
20212021
*
2022-
* @method Phaser.Group#getFarthestFrom
2022+
* @method Phaser.Group#getFurthestFrom
20232023
* @param {any} object - The object used to determine the distance. This can be a Sprite, Group, Image or any object with public x and y properties.
20242024
* @return {any} The child furthest from the given object, or null if no child was found.
20252025
*/
2026-
Phaser.Group.prototype.getFarthestFrom = function (object) {
2026+
Phaser.Group.prototype.getFurthestFrom = function (object) {
20272027

20282028
var distance = 0;
20292029
var tempDistance = 0;

0 commit comments

Comments
 (0)