Ban if daily score over 20000

pull/4/head
maru 6 months ago
parent e184e9da91
commit b52abbf7fe
No known key found for this signature in database
GPG Key ID: 37689350E9CD0F0D

@ -36,6 +36,10 @@ func Clear(uuid []byte, slot int, seed string, save defs.SessionSaveData) (Clear
waveCompleted-- waveCompleted--
} }
if save.Score >= 20000 {
db.UpdateAccountBanned(uuid, true)
}
err = db.AddOrUpdateAccountDailyRun(uuid, save.Score, waveCompleted) err = db.AddOrUpdateAccountDailyRun(uuid, save.Score, waveCompleted)
if err != nil { if err != nil {
log.Printf("failed to add or update daily run record: %s", err) log.Printf("failed to add or update daily run record: %s", err)

Loading…
Cancel
Save