2. City-Building Game
Ex : SimCityChain
Game Flow:
Add the Game:
Admin calls
addGame("SimCityChain", gameOwner, "ipfsHash", 300)
to register the game with a 3% fee.
Register Player:
Player calls
registerOnGame(gameId)
to join the city simulation.On-chain: Player registration details.
Token Deployment:
Game owner deploys an ERC1155 contract using
deployTokenContract(gameId, "ERC1155", "CityAssets", "CITY")
.
Gameplay:
Player builds a house and receives an ERC1155 token (e.g., "House Type A").
On-chain: ERC1155 token balance for the player.
IPFS: Metadata for the house type (size, resources, image).
On-Chain Data:
Player registrations, token balances. IPFS Data:
Building metadata (types, resources, appearance).
Last updated