Inspiration

This project was inspired by other satirical stock market games, including r/memeeconomy and the Codeforces Stonks bot.

What even is looking at memes without the adrenaline rush of risking your life's savings?

What it does

NYAN CATS ONLY GO UP is a decentralized, cryptocurrency-based stock market game running on the Ethereum blockchain. Users can upload memes, as well as buy and sell meme shares for M3M, our own crypto token that can be freely exchanged with Ethereum. Meme prices are directly crowdsourced through a voting feature, in which users can browse memes and vote for their favourites, ensuring high-quality memes grow in price, while stale or unfunny memes get voted out of view.

First, users use a web-app-like interface to trade Ethereum for our crypto token, M3M which can be exchanged 1:1 with Ethereum. Users may upload their memes to the blockchain for a small fee, and are in turn assigned 100 shares of that meme.

Any user can access the voting minigame, in which they are randomly assigned four memes created by other users. The user can then vote which one they think is the best, which the app uses to increase or decrease the share price of the meme.

Users can freely sell shares of their meme at market price to the block chain in exchange for M3M tokens, and vice versa, providing an authentic game theory-ridden, nerve-wracking stock trading experience. Although the app is satirical in nature, should it be deployed to the Ethereum mainnet, it can easily be played with real world money.

The memes uploading also aggregate into a trending page, where the top memes can be seen. This doubles as a good source of the best content from the community, since the community automatically sorts it, much like a site such as Reddit. The page also shows price over time (another metric stored in the blockchain!), so others can analyze the history of its success!

How we built it

The decentralized backend was written in Solidity, Ethereum’s smart contracts programming language. Truffle and web3.js are used to handle communication between the blockchain and the browser. Bootstrap, as well as vanilla HTML, CSS and Javascript and jQuery were used to build the front-end. The chart.js library was used to add some very nice analytical stock graphs.

Challenges we ran into

  • Understanding block chain, and whether or not this was feasible, was a huge challenge. We've been hearing about traditional web servers since we were very little, and most people are well versed in their development. In contrast, the Ethereum block chain is new and requires a fundamentally different approach to development.
  • It is very difficult to test smart contracts, since the fact that they run in Ethereum VM only means that they must be deployed to a test net every time.
  • We had to learn about smart contracts and the Solidity programming language, both of which were new concepts to us.
  • A challenge the front-end ran into was displaying modals (lightboxes) on click. Adding the event listener to a dynamic data-set was also quite the task.
  • Centering a div is hard

Accomplishments that we're proud of

The web-application actually working!!! Honestly, this hackathon, our project ran into like 1% the amount of bugs in our previous hackathon. On a more serious note, we were very proud that we managed to learn to and use blockchain & smart contracts — and actually make it work with the front-end!!! As for the front-end, we were proud that we were able to implement Bootstrap, chart.js as well as some nice CSS transitions.

What we learned

  • Blockchain, smart contracts, and the Solidity programming language
  • How to use Bootstrap, chart.js and CSS.
  • How to make modals and use jQuery/adding event listeners to them.
  • Time management!!!

What's next for NYAN CATS ONLY GO UP

  • Optimizing and cleaning up code
  • Search/sorting feature for better browsing
  • Moderation features
  • Private Block chain launch?
Share this project:

Updates