CryptoStars

Crypto, tokens, NFTs, web3, metaverse, trading and everything related to the blockchain

Doomsday for Layer 2

--

Wind back the Doomsday clock and reset all the alarms, because today we’re digging into the design and technical changes for my new project Season 2 of Doomsday NFT.

Photo by Ahmad Ossayli on Unsplash

For those of you who didn’t follow the original project, I did a full technical write-up on its mechanics when I launched, but if you can’t be bothered reading that, here are the highlights:

  • Lore: space debris is about to barrage the earth killing everyone.
  • Fully on-chain game where a Bunker can be placed in any city on earth, with its location recorded on chain.
  • Mint fees all go into a big prize pool.
  • Once the Apocalypse starts, the contract does some magic to plot explosions on a big map of the earth, and if you Bunker is inside it, it will be hit.
  • You can Reinforce your Bunker (at a fee, added to prize), and you can Evacuate your Bunker and receive a portion of the prize pool.
  • The last Bunker left alive wins a big old prize (Season 1 winner got 255 ETH), but requires nerves of steel.

Congratulations you are now an expert on Doomsday NFT.

Why Season 2?

Those who were part of the original Doomsday game will know I originally hadn’t planned on making it anything other than a one-off event. Partly because I wanted to focus all my energy on the project in front of me, but also because in general I prefer being experimental with my projects, so doing the exact same thing twice didn’t really appeal to me.

The response from the group of players that found the project was overwhelmingly positive, and everything worked exactly as intended (barring a few small technical issues with impacts which I didn’t catch in testing and skewed the results a little). But I found that some of the economic effects of running on ETH mainnet while trying to keep token prices as low as possible interfered with some of the game’s economy.

Although the game was designed from the ground up to work on mainnet, and thus didn’t suffer from “breaking” due to high gas costs, the mint period overlapped with some pretty crazy (200+) gas days, meaning people were paying almost as much in gas for their tokens as the mint price. This means the conditions required for them personally to break even in the game far exceeded what I’d planned for when balancing different parameters.

To catch what was the reasonable gas-range at the time, 0.01 ETH from mint txs had to be set aside to incentivise other people to execute hit-confirm txs. This worked fine, but this is a big chunk that could have otherwise gone into the prize pool (improving everyone’s break-even points).

Also, to keep the hit-confirm tx lean, I couldn’t include any anti-bot techniques, meaning a lot of that 0.01 ETH was collected by bots rather than individual users. This is fine, as the bots are just doing the job that the 0.01 ETH is designed to pay for, but it would have been nicer if more regular folk got that nice little payout more often.

So all these considerations, coupled with some vocal demand from the community for a Season 2, I decided to use it as an opportunity to take a chance on an L2 and explore the benefits that brings.

New Tech

Besides just patching the issues from Season 1, I couldn’t resist the urge to improve things while I was down there at the codeface.

Firstly, in Season 1, anyone who held a Bunker until death (either evac or impact) got to claim a Collectible version of their Bunker after it was destroyed. The Collectibles contract knew who the last holder was and gave them permission to mint the Collectible, but the mint/claim thing is quite cumbersome.

I figured if I was moving to a chain with cheaper txs, then I could just trigger the Collectible mint function from the Bunker destruction function. That way as soon as the Bunker is destroyed, the Collectible immediately appears in their wallet.

The second realisation was that I could expand both the gameplay and the lore with the creation of Survivor NFTs. The Survivors would be on a separate contract to the Bunkers, but would be able to meaningfully interact with them. Specifically, any Survivor could take refuge in any Bunker that had been minted, and anyone in a Bunker that got destroyed would be canonically “dead”.

Any survivors left at the end of the Apocalypse would share in a prize pool from Survivor mints.

Whereas the Bunker artwork is all generated using an algorithm I wrote back in Season, for the Survivors I reached out to Ghost Agent, an artist who I’ve collaborated with in the past and has a lot of experience creating art in both the NFT and Metaverse spaces. The end result is 1,000 unique Survivors, who capture the gritty aesthetic of Doomsday NFT very well.

Drawbacks of Layer 2

Of course, building on any layer 2 comes with significant risks and drawbacks, the two main ones being you sacrifice the “relevance” factor, as well as network effects

By the relevance factor, I mean the intangible thing that makes us decide that 1 BTC is worth $30,000 USD, while 1 BCH is only worth about $200 USD despite being basically identical from a technical POV. There are some small differences in this case, and I’m not trying to start any fights with any BTC fans, but the point is we all have this shared idea that BTC is the real deal while BCH is… meh.

The same applies with Eth mainnet vs any L2 or basically any other chain. Ethereum carries an air of legitimacy which it bestows upon any project that builds there. And this feeling is somewhat self-reinforcing, that is to say because mainnet is seen as the place for legitimate projects, legitimate projects tend to build there, and because legitimate projects tend to build their, it gives it more legitimacy.

So building on any other chain will come at the cost of this, which even for a non-speculative project like Doomsday NFT, still has the potential to negatively affect the project.

As for network effects, I mean the pool of users is much smaller than the already small crypto-user-space in general. And when your L2 user-base is smaller than mainnet, the number of friends that any given fan of your project can tell about it is much smaller. For a project like Doomsday NFT, its strength as a project grows the more people who are involved,which is the case with the vast majority of crypto projects, so targeting a smaller, less connected audience isn’t going to be playing on easy mode.

These were my two main concerns coming into Season 2, and to be honest I’ve always felt both of these as being key considerations in a project. I prefer to design for “must minimise possibility that anything can go wrong” rather than “must design for maximum possible moonshot”. But the whole point of Season 2 was taking an established concept and experimenting, so I muted those instincts and decided to take the leap. I’ll have to follow up this article with a dissection on how everything went.

Some bad luck

Of course, one other factor that can’t be ignored when setting out is that just a few days before our scheduled launch, the crypto market experienced the most extreme negative market event in about half a decade, bringing the market into what some are speculating could be another crypto winter. This is also shortly after a few had started crying “NFTs are dead”.

Doomsday NFT isn’t a speculative project, that is to say, there’s no need for the market price of a Bunker to budge by even a cent for the game to play out as designed and for the winners and losers to win and lose. But when trying to attract players in a the sea of other projects out there, especially on a new chain where I don’t have an established user-base to rally, these market conditions are certainly an unexpected hurdle.

Photo by Marcus Woodbridge on Unsplash

Choosing an L2

Anyway, now that you’ve decided to move to an L2, you have some decisions to make. Well… one decision, which L2?

For me I could eliminate a bunch pretty quickly. As a seasoned Solidity dev, with years of experience making Dapps on mainnet, I wasn’t very keen to learn a whole new language/process if something similar exists. Some of you may decry this, saying constant upskilling is key or that you should always be adding items to your technical resume.

But I actually push back on this. Learning a new language/framework carries opportunity cost. If you spend all the time mastering a specific L2, but it doesn’t take off, then those skills are more or less useless. And whats worse you could have spent that time further refining your Solidity skills. Plus, you could also spend that time learning something unrelated to coding, or just doing stuff you enjoy. Life is for living and if you are already a Solidity dev you probably aren’t living hand-to-mouth anyway.

All of this is to say, I had to pick an L2 where I could use my existing skills, so I could focus on all the actual stuff that made my project unique.

This eliminated a bunch of them, but there were still a few choices. A quick poll of devs I know in the space told me to check out Avalanche, Optimism or Polygon.

The other major consideration for me was that a key part of Doomsday NFT is that players have multiple options for how to both enter and exit the game. That is, they can Evacuate the Bunkers mid-Apocalypse for a bit of the prize, but they can also sell their Bunker on the open market to try get a better deal than what the Evacuation would pay. The game design is about conflicting incentives.

So with this in mind, whatever chain I had would need to have a mature NFT marketplace (since Bunkers are NFTs for this exact reason).

Lastly, different chains, depending on who is running them and how, might have incentives for you to build there. It’s a case-by-case thing but if you’re looking into building on an L2, check out what sort of incentives or support programs they have. You’ll effectively be bringing more users onto their network if your project is a success.

Polygon

Anyway, to cut to the chase, I ended up going with Polygon. Partly because Polygon NFTs can be traded on Opensea, the biggest NFT marketplace in the world, which seemed ideal for making sure that secondary sales aspect of the game mechanics worked.

But also, I’d met with Polygon Studios through a work connection and they made a pretty tantalising offer where they’d give us a nice grant and help with promotion of our project. Both of these seemed like a pretty good counter to the L2 drawbacks discussed above so I decided to pull the trigger on Polygon.

Note: For all you builders out there who are reading along, before you go jumping into bed with Polygon I have to warn you that as soon as we announced we’d move to their network Polygon Studios completely ghosted us, and we are yet to see any of these benefits. I understand I’m not the only one this has happened to, but am going to give them the benefit of the doubt for a little longer before I do a full post-mortem on my dealings with Polygon Studios. For the time being, this article is just laying out the decision making process for Doomsday NFT Season 2.

A Bunker from Doomsday NFT Season 2

Season 2 Has Begun!

So with all that being said, Doomsday NFT Season 2 is live! Public mint started yesterday and the prize pool is already over 12,000 MATIC (~$8,500 USD), with Bunkers only 60 MATIC to mint. Last season got beyond 250 ETH so expectations are pretty high.

If you have any questions regarding the project, please feel free to stop by our Discord for a chat. I’ve also made a completely different game-theory-based game that runs entirely in Discord, with lore based in the Doomsday NFT universe, where players have to compete to win Bunkers. I may write an article about that but I think you just need to witness the chaos for yourself.

I’ll be back in a few months with a follow up on how all this L2 business went, so stay tuned. For those of you still carrying on building in spite of everything that’s happened recently, keep fighting the good fight!

--

--

CryptoStars
CryptoStars

Published in CryptoStars

Crypto, tokens, NFTs, web3, metaverse, trading and everything related to the blockchain

Andrew Parker
Andrew Parker

Written by Andrew Parker

Codeslinger. Melbourne based Solidity developer for hire.

No responses yet