Casino

For this exercise you may use substrate-node-template application.

Implement:

  • CasinoGossipEngine, a wrapper over new GossipEngine instance that upon receiving Nth block starts gossiping an estimate of a timestamp in block N+Kth. N and K are parameters (might be hardcoded). We want to run the casino just once.

  • CasinoBlockImport that implements BlockImport trait. Custom block importer should send all info to CasinoGssipEngine required for gossiping logic. Use crate sp_timestamp as a source of timestamps.

Relevant substrate parts:

Last updated

Was this helpful?