Example #1
0
  public boolean mate(EntityAnimal entityanimal) {
    if (entityanimal == this) {
      return false;
    } else if (entityanimal.getClass() != this.getClass()) {
      return false;
    } else {
      EntityHorse entityhorse = (EntityHorse) entityanimal;

      if (this.cT() && entityhorse.cT()) {
        int i = this.getType();
        int j = entityhorse.getType();

        return i == j || i == 0 && j == 1 || i == 1 && j == 0;
      } else {
        return false;
      }
    }
  }