v0.13.3 account delete api, web client and toolchain update

This commit is contained in:
lixen committed 2026-10-12 21:34:06 -04:00
1 parent cc03dc0294
commit ffbf603bc8
16 files changed
+672 -57

No files matched your search

+14
View File
@@ -406,6 +406,20 @@ func (g *Game) ClaimSlot(color core.Color, userID string) error {
return nil
}
// ReleaseUser clears userID's claims and name snapshots, leaving those slots
// anonymous, and reports whether any slot changed. Player IDs stay: once the
// account is gone they identify nobody. Caller must hold the lock.
func (g *Game) ReleaseUser(userID string) bool {
changed := false
for _, player := range g.players {
if player != nil && player.ClaimedBy == userID {
player.ClaimedBy, player.Name = "", ""
changed = true
}
}
return changed
}
// GetSlotOwner returns the userID that claimed the slot, empty if unclaimed
// Caller must hold the lock
func (g *Game) GetSlotOwner(color core.Color) string {