All three of these projects use procedural generation (and Perlin noise in particular) for efficiently building rich, intricate on-chain worlds.
3/ Why do on-chain games use procgen?
Unlike other modern games, on-chain games deal with one big constraint — storage cost!
Using procedural generation allows on-chain games to compute map tiles on-demand, saving storage costs for large/infinite maps.
4/ A procedural generation algorithm is essentially a trick to compress a complex world into an executable.
Much like gamedev in the resource-constrained days of the 90s, developing on-chain worlds is an exercise in being creative & hacky with the limited compute available.
5/ How do games use procgen?
Worlds generated purely randomly with no deeper coherence start feeling stale quickly. Without locality or progression, gameplay degenerates into pulling slot machine levers. Procgen bridges this gap — creating structured, consistent randomness.
6/ This blog post builds up to the Perlin Noise procgen algorithm, starting from simple wave functions super-positioned to create a wave that's locally consistent, yet globally random.
7/ Next, these wave functions are extended to 2-D grids, creating a heatmap or "terrain map." Function outputs can then be thresholded to create a blobby map resembling an archipelago.
8/ The post demonstrates how to impose other global patterns onto these on-chain worlds, exploring different tricks used to create global consistency: super-positioning handwritten functions, switching coordinate systems or simply giving maps a fresh coat of paint!
9/ All explorations in the blog are accompanied by open-source solidity and TS code demos. The blog also links readers to solidity library and ZK-SNARK circuit implementations (s/o @darkforest_eth) of Perlin Noise for use in their own experiments.
10/ We hope this blog inspires readers to explore the unique affordances of blockchains by creating their own crypto native games and building *fun* blockchain experiences.
Thanks to @alanluo_0 for introducing us to procgen and sharing many educational resources!
• • •
Missing some Tweet in this thread? You can try to
force a refresh
2/ Try out zkREPL at the link below! Build, compile, and test your circuit in-browser in seconds—no installation or dependency management needed. Multiple 0xPARC teams have been using zkREPL to prototype and test complex circuits in the past few months.
Primitives for ZK-enabled decentralized identity systems are coming online rapidly. In our last post on the topic, we touched on the “why” of ZK identity. This time, we’ll dive into the “how.”
2/ As a reminder from part 1, SNARKs promise to revolutionize identity online because they (1) allow us to make arbitrary credible claims while (2) maintaining privacy.
Earlier today, @0xB07DAD pointed out a flaw in the current StealthDrop system that allows users to double-claim. The vulnerability (and the fix strategy) are instructive for anyone interested in building ZK systems; the StealthDrop team asked us to share a summary! (1/n)
First, to repeat - community projects like this are *highly experimental* and *not suited for production-grade use* (yet!). We share community projects and encourage teams to open-source these projects for feedback and for educational value, but... (2/n)
these demonstrations are NOT appropriate for use in production-grade code. For more ZK applications to become production-ready, we'll need to build an ecosystem of auditors, reviewers, and verification tools. (3/n)
As a proof of concept, all @darkforest_eth players who have linked their address to a twitter handle, and all @ETHUniversity students, can claim a Stealthdrop token on xDAI anonymously at the demo website below: (2/n)
@theyisun, Tony L, @xu3kev, and @gubsheep present an efficient proof-of-concept implementation of zkSNARK circuits for ECDSA algorithms in circom. (1/n)
Our main contribution is the circom-ecdsa repository, which includes a collection of (unaudited) ZK circuits for non-native field arithmetic, secp256k1 curve operations, ECDSA algorithms, and ETH private-key/address operations. (2/n)
zkSNARKs for ECDSA enable users to make claims like:
- I own a @darkforest_eth NFT, but I won't tell you which one.
- I possess enough signed votes to pass a DAO proposal, but I won't reveal the IDs of the voters.
- I can claim an airdrop, but I won't reveal my address.
(3/n)
We're excited to announce 0xPARC: Program for Applied Research in Cryptography. (1/n)
0xPARC is a new organization supporting decentralized application R&D. We aim to foster a budding community of researchers, developers, thinkers, and builders - a distributed "skunk works" for the Ethereum and decentralized tech ecosystems. (2/n)
Projects we currently support include @darkforest_eth, @ETHUniversity, Project Sophon, @reboot_hq, and several more experimental applications currently in development. (3/n)