Contracts written in Cairo using Dojo to showcase a Pixel World with app interoperability. Its interoperability is made possible with core actions. Apps are any other contracts that are deployed to the Pixel World.
Follow the asdf installation instructions.
asdf plugin add dojo https://github.com/dojoengine/asdf-dojo
asdf install dojo 1.0.0
asdf plugin add scarb
asdf install scarb 2.7.0
And after moving into contracts directory, the versions for these libs are set in the .tool-versions file.
# Run Katana
katana --dev --dev.no-fee --http.cors_origins "*"
# Build the example
sozo build
# Migrate the example
sozo migrate
# Initialize the pixelaw app
scarb run init_auth
# Start Torii
torii --world 0x6f130c8e150882e39cbe878c650c8f35c86579180dbc77d0c1cbe169449b5f6 --http.cors_origins "*"
you can deploy your app to our katana testnet by running the following commands:
# Deploy the pixelaw app
sozo build -P release
sozo migrate apply -P release
If you want to use latest dojo version, you need to clone core by yourself and modify the path in Scarb.toml
file.
- Clone core repo
git clone https://github.com/pixelaw/core
- Modify the path in
Scarb.toml
file
pixelaw = { path = "../pixelaw/core/contracts" }
- Modify version in
Scarb.toml
file in core repo
dojo = { git = "https://github.com/dojoengine/dojo", tag = "v1.0.0-alpha.11" }
- Build and run core
cd contracts
sozo build
sozo migrate apply