BibliothecaDAO / realms-contracts

Realms Monorepo for Ethereum contracts and Starknet contracts.
https://bibliothecadao.xyz/
MIT License
87 stars 33 forks source link

feat: Permissionless ERC1155 contract #278

Closed ponderingdemocritus closed 1 year ago

ponderingdemocritus commented 1 year ago

Right now 1155 contracts have one owner. This owner gives perms to whoever can mint on the contract. If a contract has the ability to mint tokens it has the ability to mint any token id.

Since in the Realm universe, we are building an open platform it only makes sense that we open the resources contract. This doesn't mean that the tokens people make will be valuable. The utility of the token is still up to the actual creator. It just means that we can encourage developers to create tokens in the canonical contract of the world. This gives the token immediate access throughout the world and instant interoperability in the AMM.

How do we do this? We simply modify the current ERC1155 to have permissions at the token level, not the contract level. This contract will consume a bit more gas than a regular ERC1155 as there are perm checks on each token transfer.

Thoughts?