0xFableOrg / 0xFable

A fully on-chain trading card game. There will be elves, wizards & shit. Drama and broken friendships also.
https://twitter.com/0xFableGame
BSD 3-Clause Clear License
106 stars 39 forks source link

Decks Onchain #134

Open eviterin opened 7 months ago

eviterin commented 7 months ago

Context (Problem, Motivation, Solution)

103 Bring Decks Onchain

111 Add Deck Validity Status when Constructing Deck

Describe Your Changes

Decks are now saved and modified onchain. Decks owned by the player are now presented in their collection. Minor changes to UI but not overhauled (#93)

A couple of functions added in the Inventory.sol contract, namely: getAllDecks getDeckNames getDeckReal

Checklist

Testing

If you didn't write tests, explain how you made sure the code was correct and working as intended.

eviterin commented 7 months ago

This one should be in draft state, but I can't set it to that. Still have tests & checks to do, and refactor getDeckReal as it clashes with a function named getDeck that fetches only the cards of a deck(not name).

norswap commented 6 months ago

You don't see "Still in progress? Convert to Draft" in the top right panel? If you do see it, what happens if you click it?

You have write access to the repo, so you should be able to convert the PR to draft in theory!

Do you want me to already give this a review, or do you want me to wait when you're done?

norswap commented 6 months ago

I see this still has conflict, so should be rebased on top of master!

norswap commented 6 months ago

It's kind of weird there are commits from Aritra in the middle ... rebase gone wrong?

eviterin commented 6 months ago

Aritra commits are DELTED. REBASED on top of master. All checks PASSING. Commit history tidied up (some).

I haven't been able to verify if my work has regressed gameplay due to "#135 Unable to Join Game", and am worried as I have refactored getDeck in Inventory.sol that is used there (commit f812094).