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

feat: setup logic for resign & offer draw #180

Closed
wants to merge 16 commits into from

Conversation

devsargam
Copy link

No description provided.

@hkirat
Copy link
Contributor

hkirat commented Apr 21, 2024

nice

@Sama-004
Copy link
Contributor

I tried implementing this but failed :(

@devsargam devsargam marked this pull request as ready for review April 21, 2024 20:31
@devsargam
Copy link
Author

Hey @hkirat, could you please review this one?

}

if (message.type === DRAW_OFFER_ACCEPTED) {
SocketManager.getInstance().broadcast(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we checking if the other user has offered a draw before accepting it?
It should be stored somewhere that there was an offer made

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good one. I thought better do this way since doing db was a lot of hassle. Happy to change if needed? is it?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hkirat how about a in memory store the expires every 30s?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In memory yeah makes sense

apps/ws/src/GameManager.ts Outdated Show resolved Hide resolved
@devsargam
Copy link
Author

@devsargam
Copy link
Author

image

@devsargam
Copy link
Author

Hey @hkirat kindly check this one. A lot of ui changes very prone to merge conflicts

@devsargam
Copy link
Author

Ui can be extended from #223

@hkirat
Copy link
Contributor

hkirat commented May 6, 2024

#223 is merged
Do u want to bring this one up to date or create a new one @devsargam ?

@devsargam
Copy link
Author

@hkirat new one should do it. Raising it by eod

@hkirat hkirat closed this May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants