#include "Hero.hpp"
#include "Kicker.hpp"

Object& Play::Hero::onCollision(Object* object) {
  if (object != nullptr) {
    if (
      const Kicker* kicker = dynamic_cast<const Kicker*>(object)
    ) {
      static Vector v;
      (
        v = getSpeed()
      ).y = kicker->kickSpeedY;
      setSpeed(v);
    }
  }
  return FirstPerson::Hero::onCollision(object);
}
