onCollision method

  1. @mustCallSuper
void onCollision(
  1. List<Vector2> intersectionPoints,
  2. T other
)

onCollision is called in every tick when this object is colliding with other.

Implementation

@mustCallSuper
void onCollision(List<Vector2> intersectionPoints, T other) {
  onCollisionCallback?.call(intersectionPoints, other);
}