Skip to content

feat: Add time-locked refunds and game cancellation to escrow contract#2

Open
syed-ghufran-hassan wants to merge 1 commit intojadonamite:mainfrom
syed-ghufran-hassan:patch-2
Open

feat: Add time-locked refunds and game cancellation to escrow contract#2
syed-ghufran-hassan wants to merge 1 commit intojadonamite:mainfrom
syed-ghufran-hassan:patch-2

Conversation

@syed-ghufran-hassan
Copy link
Copy Markdown

  • Add game status tracking ("waiting", "active", "completed", "refunded", "cancelled")
  • Implement cancel-game for white player before black joins
  • Add time-locked refund mechanism for games where black never joins
  • Implement claim-abandoned for games inactive past timelock
  • Add update-last-move to track game activity
  • Enhance release-to-winner with winner validation
  • Enhance refund-game with player authorization
  • Add read-only functions: get-game-status, get-refund-timelock, can-request-refund
  • Add admin function to set refund timelock

- Add game status tracking ("waiting", "active", "completed", "refunded", "cancelled")
- Implement cancel-game for white player before black joins
- Add time-locked refund mechanism for games where black never joins
- Implement claim-abandoned for games inactive past timelock
- Add update-last-move to track game activity
- Enhance release-to-winner with winner validation
- Enhance refund-game with player authorization
- Add read-only functions: get-game-status, get-refund-timelock, can-request-refund
- Add admin function to set refund timelock
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.

1 participant