CryptoBlades / cryptoblades
- четверг, 22 июля 2021 г. в 00:30:21
99999999 (or some other high number so you can deploy).You should now have 100 fake eth! You're now fake rich.
npm install.env in the 'frontend' directory alongside .env.mainnet and .env.testnet Edit this file to include the following lines of codenpm run contract:prepare (this builds your contracts)npm run contract:deploy (this deploys your contracts to your local blockchain)npm run start:frontendFor Windows developers experiencing errors follow these steps:
rm -r buildnpm run contract:prepare (this builds your contracts)rm -r build/contractsnpm run contract:deploynpm run start:frontendIf you're using VSCode, we recommend these extensions: Auto Rename Tag, EditorConfig for VSCode, Eslint, Github Pull Requests, Gitlens, Javascript and Typescript, Live Share, Solidity, Typescript Hero, Vetur
Truffle also supports some environment variables, if you create a .env file in the root you can specify:
ETH_DEV_RPC_HOSTETH_DEV_RPC_PORTETH_DEV_RPC_NETWORK_IDETH_DEV_RPC_GASBINANCE_WALLET_MNEMONICcontracts contains the solidity contracts for the gamefrontend contains the Vue code for the frontendmigrations contains migration filestest contains testsnpm run start:frontend - start up a server for the Vue frontendnpm run lint - run lint checking for all modulesnpm run contract:prepare - extract the ABI and re-compile Truffle contractsnpm run contract:deploy - deploy the Truffle contracts for testing- rm -rf build/