Testing Inside Editor

In-Editor Wallet

To be able to test transactions and whatever else while you are developing, WalletService provides a generated wallet. If you check Use Generated on, when you start the game, a keypair will be automatically generated for you. The same one each time, using your device's ID as the seed.

This wallet is going to be empty at first, but you can send tokens and NFTs to it by using its public key. To make sure to not lose the contents of said wallet, you can uncomment the part of the script in wallet_service.gd which reveals its private key. You can use it to import the wallet into your favourite wallet provider

Alternatively, you can use your own existing wallet for testing. To do that, you need to export the private key of the desired wallet and paste it into a text file. Then in the inspector of WalletService node, you can add the path to the text file with your keypair in the Custom Pk Path field.

Testing the Build

while being able to test your game inside editor with transactions that get automatically approved, it is vital to be able to quickly test the build version as well!

One crucial thing that is often overlooked while developing a Web game is that you can quickly launch the localhost version as easily as going into the Play mode. To enable that option, go to Project -> Export -> New and select WEB option.

Once you add it in, Godot will ask you to download the necessary drivers to allow the web building. When that's done, you will see an additional button available among the play scene buttons - Remote Debug. Click it and you will be able to test the game in web, without needing to build it!

PROTIP: When you're testing in web, use a hotkey of CTRL+SHIFT+I to open the console and inspect the errors and everything else.

Last updated