Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/damianmarti/kitty-fight
Experimental project with CryptoKitties fights.
https://github.com/damianmarti/kitty-fight
ethereum solidity web3
Last synced: 22 days ago
JSON representation
Experimental project with CryptoKitties fights.
- Host: GitHub
- URL: https://github.com/damianmarti/kitty-fight
- Owner: damianmarti
- Created: 2021-05-24T22:49:38.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-05-24T23:33:37.000Z (over 3 years ago)
- Last Synced: 2024-10-07T01:41:02.892Z (about 1 month ago)
- Topics: ethereum, solidity, web3
- Language: JavaScript
- Homepage:
- Size: 411 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# KittyFight
Experimental project with CryptoKitties fights.
The KittyFight contract interact with the CryptoKitties core contract to get the kitties genes.
The fight result is generated from the kitties genes and some pseudo randomness.
![UI Screenshoot](https://github.com/damianmarti/kitty-fight/blob/main/docs/images/kitty-fight.png)
![UI Screenshoot](https://github.com/damianmarti/kitty-fight/blob/main/docs/images/kitty-fight2.png)
## Install libraries:
```bash
npm install
```## Start the test network with:
```bash
truffle develop
```## Deploy the contracts with:
```bash
truffle migrate
```## Run the tests:
```bash
truffle test
```## Testing:
You can create some test kitties using truffle console:
```bash
truffle consolelet kittyCore = await KittyCore.deployed()
kittyCore.createPromoKitty('626837621154801616088980922659877168609154386318304496692374110716999053','0x905B8ba9C9378c9876980e86CFB146B5C447C32e')
kittyCore.createPromoKitty('623332824742417442073801652020554010523726975553705023219600667807529387','0x905B8ba9C9378c9876980e86CFB146B5C447C32e')
```## Start web development server:
```bash
npm run dev
```## Configure Metamask
Set the test network on Metamask with the info on truffle-config.js and import the generated seed when truffle develop was started.