Interface WorldManager.CollisionDetectionListener

  • Enclosing interface:
    WorldManager
    Functional Interface:
    This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

    @FunctionalInterface
    public static interface WorldManager.CollisionDetectionListener
    Listener to operate on detected collisions between two composite entities on entity level. This listener is invoked once per local entity position. For example if 3 overlapping fields populated with entities collide, you will get 3 invocations.
    • Method Detail

      • run

        boolean run​(Iterator<PhysicalEntity> it0,
                    Iterator<PhysicalEntity> it1)
        See CollisionDetectionListener description.
        Parameters:
        it0 - Entities on composite entity 0 colliding with 1
        it1 - Entities on composite entity 1 colliding with 0
        Returns:
        false to break execution, true to continue with next collision position