Card game token burn and trade-in protocol for Ergo blockchain.
- Use at your own risk.
- Download the latest release.
- Install
Java 18.0.2
(JRE, JDK, or OpenJDK). - If you would like to compile the jar yourself, download
sbt
and runsbt assembly
within the repository folder.
This command will compile all the ErgoScript contracts required for the protocol.
- Run
java -jar trade-in-<version>.jar --compile
These commands will execute transactions in the setup phase of the protocol. It assumes that you have compiled the ErgoScript contracts already. You must execute these transactions in the order they appear. Please wait for confirmation before executing the next transaction.
- Run
java -jar trade-in-<version>.jar --mint-game-tokens
to execute the game token mint transaction. - Run
java -jar trade-in-<version>.jar --mint-game-lp-singleton
to execute the game liquidity pool singleton token minting transaction. - Run
java -jar trade-in-<version>.jar --game-lp-creation
to execute the game lp box creation transaction. - Run
java -jar trade-in-<version>.jar --mint-card-value-mapping-singleton
to execute the card-value-mapping singleton token minting transaction. - Run
java -jar trade-in-<version>.jar --card-value-mapping-creation
to execute the card-value-mapping box creation transaction.
The Player Proxy transaction is not part of this setup protocol but will instead be executed by the bot. However, this will assume that a valid game token already exists.
Please create a GitHub issue or email me.