phaser - v4.0.0-rc.4
    Preparing search index...

    Function TransformXY

    • Takes the x and y coordinates and transforms them into the same space as defined by the position, rotation and scale values.

      Parameters

      • x: number

        The x coordinate to be transformed.

      • y: number

        The y coordinate to be transformed.

      • positionX: number

        Horizontal position of the transform point.

      • positionY: number

        Vertical position of the transform point.

      • rotation: number

        Rotation of the transform point, in radians.

      • scaleX: number

        Horizontal scale of the transform point.

      • scaleY: number

        Vertical scale of the transform point.

      • Optionaloutput: Vector2Like

        The output vector, point or object for the translated coordinates.

      Returns Vector2Like