81 / Bunnies thesis & Remix
Essential features you need to know
Essential features in Remix that users may not know about with Rob Stupay and a deep dive into OnChainBunnies research by Axelle Moortgat including optimizations and strategies for random ID generation.
Timeline
Participants
@fulldecent
William Entriken
@dtedesco1
Daniel Tedesco
@037
AKM
@Legend
???
@axellemoortgat
Axelle Moortgat
@TheMiamiApe
???
@Remix
Remix Project
@ryestew
Rob Stupay
@SBU_HoneyRadio
???
@jhinnbay
???
@rocsolmiami
???
@retromort
???
@H_T_V_
???
@StackieRobins0n
???
Episode notes
Edit these notes…- OnChainBunnies research
- How NFT randomness works
- Axelle Moortgat: OnChainBunnies research
- Optimizations
- Generation instead of storage (Loot generation, SVG)
- Optimizer
- Solidity gets translated to opcode by EVM
- SSTORE is the most expensive opcode
- Memory data
- Storage options: Storage data, call data, and memory data
- Every time you ask for memory data, code is read, data is declared, and data is deleted
- Bitfieldencoding
- How to store the IDs?
- Use bits for every trait
- Bitfield operations are very cheap
- Store one integer and get all the data once
- Random ID generation
- Uncovered insider trading
- Developer knows which IDs have which traits and will tell friends
- How to prevent this? Need to reveal IDs randomly
- Need a random number, but this is hard on blockchain
- Some ways
- Timestamp
- Miner address
- Who will be next validator
- Combination of these to generate a random number
- Still need to figure out how to generate the IDs as a result
- Pick numbers in an ascending order
- Random ID picking algorithm
- ID revealed at mint
- Tradeoffs: Can abort transactions if you don’t like what you minted
- “Randomness can be controlled by sandwiches”
- Randomness https://blog.phor.net/randomization-strategies-nft-drops
- Uncovered insider trading
- Optimizations
- Remix Project
- https://remix.ethereum.org/#lang=en&optimize=false&runs=200&evmVersion=null&version=soljson-v0.8.20+commit.a1b79de6.js&language=Solidity
- Get your NFT drop by joining as a beta tester at https://docs.google.com/forms/d/e/1FAIpQLSd0WsJnKbeJo-BGrnf7WijxAdmE4PnC_Z4M0IApbBfHLHZdsQ/viewform
-
Community Service Hour episode 81 featuring @axellemoortgat @OnChainBunnies @ryestew
Key points for efficiently putting image-NFTs on chain
And things you might not know about Remix IDE
-
Best practices for generating the images when needed ON-CHAIN, and minimizing storage (SSTORE) use.
-
“Randomness can be controlled by sandwiches” // @legend has the official framed book note for this!
-
See also our article https://blog.phor.net/randomization-strategies-nft-drops about all the tradeoffs
-
Check out Remix at https://remix.ethereum.org and now I can see all this documentation that was always there. Here is where to find it…
[[ PHOTO ]]
-
Get your NFT drop by joining as a Remix beta tester at [https://docs.google.com/forms/d/e/1FAIpQLSd0WsJnKbeJo-BGrnf7WijxAdmE4PnC_Z4M0IApbBfHLHZdsQ/viewform
](https://docs.google.com/forms/d/e/1FAIpQLSd0WsJnKbeJo-BGrnf7WijxAdmE4PnC_Z4M0IApbBfHLHZdsQ/viewform)Is this the first official Ethereum Foundation sanctioned NFT drop?