Based on oakdex-pokemon.
require 'oakdex/breeding'
pok1 = Oakdex::Pokemon.create('Ditto', level: 20)
pok2 = Oakdex::Pokemon.create('Pikachu', level: 20, gender: 'female')
Oakdex::Breeding.compatible?(pok1, pok2) # => true
Oakdex::Breeding.chance_in_percentage(pok1, pok2) # => 20
Oakdex::Breeding.breed(pok1, pok2) #=> Oakdex::Pokemon Pichu
I would be happy if you want to add your contribution to the project. In order to contribute, you just have to fork this repository.
Please respect the Code of Conduct.
MIT License. See the included MIT-LICENSE file.
Logo Icon by Roundicons Freebies.