dapperlabs / cryptokitties-bounty

Bounty program for CryptoKitties smart contract
https://www.cryptokitties.co/
Other
482 stars 228 forks source link

Possibly missing implementation of intended functionality #17

Open adamkolar opened 6 years ago

adamkolar commented 6 years ago

This comment:

        // Set to the index in the cooldown array (see below) that represents
        // the current cooldown duration for this Kitty. This starts at zero
        // for gen0 cats, and is initialized to floor(generation/2) for others.
        // Incremented by one for each successful breeding action, regardless
        // of whether this cat is acting as matron or sire.
        uint16 cooldownIndex;

says that cooldownIndex should be initialized to floor(generation/2) for all kitties with generation > 0. However I haven't found any code that implements this functionality, all kitties regardless of generation seem to start at 0.

dete commented 6 years ago

Nice catch, @adamkolar! We noticed this internally yesterday, but it's a fairly important miss so I'm going to leave this issue open for a bounty.

kimcope commented 6 years ago

Thanks for your participation, @adamkolar! Our team has reviewed your submission, and we are pleased to reward you for your report.

Impact: Low Likelihood: High Points: 100

We are discounting the point number because this issue was already found and fixed internally.

Please see the final leaderboard here.