예제 #1
0
파일: Crystal.cpp 프로젝트: ElAleyo/solarus
/**
 * \brief This function is called when another entity collides with this crystal.
 * \param entity_overlapping the other entity
 * \param collision_mode the collision mode that detected the collision
 */
void Crystal::notify_collision(MapEntity& entity_overlapping, CollisionMode collision_mode) {
  entity_overlapping.notify_collision_with_crystal(*this, collision_mode);
}
예제 #2
0
파일: Crystal.cpp 프로젝트: ElAleyo/solarus
/**
 * \brief Notifies this entity that another sprite is overlapping it.
 *
 * This function is called by check_collision(MapEntity*, Sprite*) when another entity's
 * sprite overlaps a sprite of this detector.
 *
 * \param other_entity the entity overlapping this detector
 * \param other_sprite the sprite of other_entity that is overlapping this detector
 * \param this_sprite the sprite of this detector that is overlapping the other entity's sprite
 */
void Crystal::notify_collision(MapEntity& other_entity, Sprite& other_sprite, Sprite& this_sprite) {
  other_entity.notify_collision_with_crystal(*this, other_sprite);
}