Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement the attack logic #26

Closed
0xLucqs opened this issue Aug 8, 2023 · 5 comments · May be fixed by #57
Closed

Implement the attack logic #26

0xLucqs opened this issue Aug 8, 2023 · 5 comments · May be fixed by #57
Assignees
Labels
good first issue Good for newcomers smart contract Everything smart contract related

Comments

@0xLucqs
Copy link
Contributor

0xLucqs commented Aug 8, 2023

Description

As per the game rules, at the end of your turn, all your cards on the field will try to pass the opponents' players. If you dribble an enemy player it'll go out of the game but will reduce your defense by his dribble stats. If the opponent's board is empty you'll score a goald and win the round. The attacking sequence is : attacker => midfielder => defense => goalkeeper
(this should be in the end turn system)

Acceptance criteria

  • The attacking sequence is respected
  • Cards that get passed get removed from the board
  • If a card doesn't get passed but gets attacked its defense stat is updated
@0xLucqs 0xLucqs added good first issue Good for newcomers smart contract Everything smart contract related labels Aug 8, 2023
@WhoIsNac
Copy link
Contributor

WhoIsNac commented Aug 8, 2023

I can handle this if needed

@0xLucqs
Copy link
Contributor Author

0xLucqs commented Aug 13, 2023

Hey any news there N

@0xLucqs
Copy link
Contributor Author

0xLucqs commented Aug 14, 2023

It is blocking other PRs so unassigning it. Feel free to pick up something else

@0xLucqs 0xLucqs self-assigned this Aug 14, 2023
WhoIsNac added a commit to WhoIsNac/tsubasa that referenced this issue Aug 14, 2023
I have implemented the beginning of the contract as well as the attack logic tests but the implementation of the attack requires the modification of the component file as well as the implementation of the card deck system in order to verify the lenght of the players' hand.
WhoIsNac added a commit to WhoIsNac/tsubasa that referenced this issue Aug 14, 2023
I have implemented the beginning of the contract as well as the attack logic tests but the implementation of the attack requires the modification of the component file as well as the implementation of the card deck system in order to verify the lenght of the players' hand.
@WhoIsNac
Copy link
Contributor

Sorry, I didn't see the message, I've started the attack logic and contract and implemented the test, (I've also created a card creation contract to test with card stats).

But to finish the implementation, we need to finish the card logic system and also the place_card system to know every card in the field in order to start the attack sequence between the players' cards.

I don't know if we're allowed to implement other parts to finish this one.

@0xLucqs
Copy link
Contributor Author

0xLucqs commented Aug 14, 2023

Cool I'll implement the place card now which seems to block all the PRs and then you can finish your implementation

@0xLucqs 0xLucqs assigned WhoIsNac and unassigned 0xLucqs Aug 14, 2023
WhoIsNac added a commit to WhoIsNac/tsubasa that referenced this issue Aug 15, 2023
Fix error in test Attack , also finished the implementation of the create_card system , and i added some comment to the code
@0xLucqs 0xLucqs closed this as completed Sep 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers smart contract Everything smart contract related
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants