DEV Community

loading...

Building a blockchain runtime module in Rust as Jr Dev

Amy-Centrality
Senior Community Developer at the CENNZnet team. We build a blockchain platform that enables devs to build quality Decentralised Apps(DApps) fast.
・1 min read

Alt Text

Here on the CENNZnet team, Our newest Junior Developer Jason decided to learn Rust by getting his hands dirty.

He thought the best way to learn to build a runtime module for the blockchain CENNZnet, was to build the classic game of Snake.

Runtime modules are the building blocks for CENNZnet. They are written in Rust for performance and security. CENNZnet provides runtime modules for commonly used functionalities in DApps(Decentralised Apps), then expose them through a JavaScript API for the ease of use.

While this Snake runtime module is unlikely to be useful for other DApp developers, it sure was a fruitful journey full of learnings.

This blockchain Snake game records the command and positions on the blockchain as transactions. Then the game reads these positions from the chain to display on the page.

Read the story here!

Discussion (0)