Skip to main content

HashColliderProxy

Proxy type to stash collision info

Hierarchy

Index

Constructors

constructor

Properties

body

bottomY

bottomY: number

bottom bounds y hash coordinate

bounds

bounds: BoundingBox

cells

References to the hash cell the collider is a current member of

publiccollider

collider: Collider

collisionType

collisionType: CollisionType

readonlygridSize

gridSize: number

Grid size in pixels

hasZeroBounds

hasZeroBounds: boolean = false

id

id: number = -1

leftX

leftX: number

left bounds x hash coordinate

publicobject

object: Collider

owner

owner: Entity<any>

rightX

rightX: number

right bounds x hash coordinate

topY

topY: number

top bounds y hash coordinate

Methods

clear

  • clear(): void
  • Clears all collider references


    Returns void

hasChanged

  • hasChanged(): boolean
  • Has the hashed bounds changed


    Returns boolean

update

  • update(): void
  • Updates the hashed bounds coordinates


    Returns void