Class/Object

io.scalajs.dom.html.phaser.physics

Arcade

Related Docs: object Arcade | package physics

Permalink

class Arcade extends Object

The Arcade Physics world. Contains Arcade Physics related collision, overlap and motion methods.

Annotations
@RawJSType() @native() @JSGlobal( "Phaser.Physics.Arcade" )
See also

http://phaser.io/docs/2.6.2/Phaser.Physics.Arcade.html

Linear Supertypes
Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Arcade
  2. Object
  3. Any
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Arcade(game: Phaser.Game)

    Permalink

    game

    reference to the current game instance.

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. var OVERLAP_BIAS: Double

    Permalink

    A value added to the delta values during collision checks.

  5. def accelerateToObject(displayObject: DisplayObject, destination: Any, speed: Double, xSpeedMax: Double, ySpeedMax: Double): Double

    Permalink

    Sets the acceleration.x/y property on the display object so it will move towards the target at the given speed (in pixels per second sq.)

    Sets the acceleration.x/y property on the display object so it will move towards the target at the given speed (in pixels per second sq.)

    You must give a maximum speed value, beyond which the display object won't go any faster.

    Note: The display object does not continuously track the target. If the target changes location during transit the display object will not modify its course.

    Note: The display object doesn't stop moving once it reaches the destination coordinates.

    displayObject

    The display object to move.

    destination

    The display object to move towards. Can be any object but must have visible x/y properties.

    speed

    The speed it will accelerate in pixels per second.

    xSpeedMax

    The maximum x velocity the display object can reach.

    ySpeedMax

    The maximum y velocity the display object can reach.

    returns

    The angle (in radians) that the object should be visually set to in order to match its new trajectory.

  6. def accelerateToPointer(displayObject: DisplayObject, pointer: Phaser.Pointer = js.native, speed: Double = js.native, xSpeedMax: Double = js.native, ySpeedMax: Double = js.native): Double

    Permalink

    Sets the acceleration.x/y property on the display object so it will move towards the target at the given speed (in pixels per second sq.)

    Sets the acceleration.x/y property on the display object so it will move towards the target at the given speed (in pixels per second sq.)

    You must give a maximum speed value, beyond which the display object won't go any faster. Note: The display object does not continuously track the target. If the target changes location during transit the display object will not modify its course.

    Note: The display object doesn't stop moving once it reaches the destination coordinates.

    displayObject

    The display object to move.

    pointer

    The pointer to move towards. Defaults to Phaser.Input.activePointer.

    speed

    The speed it will accelerate in pixels per second.

    xSpeedMax

    The maximum x velocity the display object can reach.

    ySpeedMax

    The maximum y velocity the display object can reach.

    returns

    The angle (in radians) that the object should be visually set to in order to match its new trajectory.

  7. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  8. var bounds: Phaser.Rectangle

    Permalink

    The bounds inside of which the physics world exists.

    The bounds inside of which the physics world exists. Defaults to match the world bounds.

  9. var checkCollision: Any

    Permalink

    Set the checkCollision properties to control for which bounds collision is processed.

    Set the checkCollision properties to control for which bounds collision is processed. For example checkCollision.down = false means Bodies cannot collide with the World.bounds.bottom. An object containing allowed collision flags.

  10. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  13. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. var forceX: Boolean

    Permalink

    If true World.separate will always separate on the X axis before Y.

    If true World.separate will always separate on the X axis before Y. Otherwise it will check gravity totals first.

  15. var game: Phaser.Game

    Permalink

    reference to the current game instance.

  16. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  17. var gravity: Phaser.Point

    Permalink

    The World gravity setting.

    The World gravity setting. Defaults to x: 0, y: 0, or no gravity.

  18. def hasOwnProperty(v: String): Boolean

    Permalink
    Definition Classes
    Object
  19. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  20. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  21. var isPaused: Boolean

    Permalink

    If true the Body.preUpdate method will be skipped, halting all motion for all bodies.

    If true the Body.preUpdate method will be skipped, halting all motion for all bodies. Note that other methods such as collide will still work, so be careful not to call them on paused bodies.

  22. def isPrototypeOf(v: Object): Boolean

    Permalink
    Definition Classes
    Object
  23. var maxLevels: Double

    Permalink

    Used by the QuadTree to set the maximum number of iteration levels.

  24. var maxObjects: Double

    Permalink

    Used by the QuadTree to set the maximum number of objects per quad.

  25. def moveToObject(displayObject: DisplayObject, destination: Any, speed: Int = 60, maxTime: Long = 0): Double

    Permalink
  26. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  27. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  28. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  29. def overlap(object1: |[|[Sprite, Group[_]], Array[_]], object2: |[|[Sprite, Group[_]], Array[_]], overlapCallback: Function2[_, _, _], processCallback: Option[Function2[_, _, Boolean]], callbackContext: Any = js.native): Unit

    Permalink
  30. def propertyIsEnumerable(v: String): Boolean

    Permalink
    Definition Classes
    Object
  31. var quadTree: Phaser.QuadTree

    Permalink

    The world QuadTree.

  32. var skipQuadTree: Boolean

    Permalink

    If true the QuadTree will not be used for any collision.

    If true the QuadTree will not be used for any collision. QuadTrees are great if objects are well spread out in your game, otherwise they are a performance hit. If you enable this you can disable on a per body basis via Body.skipQuadTree.

  33. var sortDirection: Int

    Permalink

    Used when colliding a Sprite vs.

    Used when colliding a Sprite vs. a Group, or a Group vs. a Group, this defines the direction the sort is based on. Default is Phaser.Physics.Arcade.LEFT_RIGHT.

  34. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  35. def toLocaleString(): String

    Permalink
    Definition Classes
    Object
  36. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  37. def valueOf(): Any

    Permalink
    Definition Classes
    Object
  38. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  39. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped