# at.skeetfighter.best

> One per player (key self): their all-time best and this week's best, each pointing at the at.skeetfighter.score record it came from.

- Kind: record
- Record key: literal:self
- Authority: skeetfighter.at
- Lexicon: 1
- Published by [skeetfighter.at](https://lexicon.garden/identity/did:plc:xa2u22z7m4qgaaxxy3kjyqs4), the NSID's authority

## Links

- [Documentation](https://lexicon.garden/lexicon/did:plc:xa2u22z7m4qgaaxxy3kjyqs4/at.skeetfighter.best)
- [Schema JSON](https://lexicon.garden/lexicon/did:plc:xa2u22z7m4qgaaxxy3kjyqs4/at.skeetfighter.best/schema.json)
- [Analytics](https://lexicon.garden/lexicon/did:plc:xa2u22z7m4qgaaxxy3kjyqs4/at.skeetfighter.best/analytics)

## Record (`at.skeetfighter.best`)

Type: record · key literal:self

### Properties

- `allTime` (ref, required): The player's best score ever.
  - Reference: `#entry`
- `updatedAt` (string · datetime, required)
- `week` (ref): The player's best score in the week starting at weekStart.
  - Reference: `#weekEntry`

## #entry (`at.skeetfighter.best#entry`)

Type: object

### Properties

- `achievedAt` (string · datetime, required)
- `cleared` (boolean, required): Whether the run beat the final boss.
- `fighter` (string · did, required): The account whose fighter the player used.
- `outcome` (string, required)
  - Constraints: knownValues: cleared | gameOver | continued | quit
- `ref` (ref, required): The at.skeetfighter.score record this entry came from.
  - Reference: `com.atproto.repo.strongRef`
- `score` (integer, required)
  - Constraints: minimum: 0, maximum: 99999999

## #weekEntry (`at.skeetfighter.best#weekEntry`)

Type: object

### Properties

- `achievedAt` (string · datetime, required)
- `cleared` (boolean, required)
- `fighter` (string · did, required)
- `outcome` (string, required)
  - Constraints: knownValues: cleared | gameOver | continued | quit
- `ref` (ref, required)
  - Reference: `com.atproto.repo.strongRef`
- `score` (integer, required)
  - Constraints: minimum: 0, maximum: 99999999
- `weekStart` (string · datetime, required): The Monday 00:00 UTC that starts the week.

## Schema

```json
{
  "$type": "com.atproto.lexicon.schema",
  "defs": {
    "entry": {
      "properties": {
        "achievedAt": {
          "format": "datetime",
          "type": "string"
        },
        "cleared": {
          "description": "Whether the run beat the final boss.",
          "type": "boolean"
        },
        "fighter": {
          "description": "The account whose fighter the player used.",
          "format": "did",
          "type": "string"
        },
        "outcome": {
          "knownValues": [
            "cleared",
            "gameOver",
            "continued",
            "quit"
          ],
          "type": "string"
        },
        "ref": {
          "description": "The at.skeetfighter.score record this entry came from.",
          "ref": "com.atproto.repo.strongRef",
          "type": "ref"
        },
        "score": {
          "maximum": 99999999,
          "minimum": 0,
          "type": "integer"
        }
      },
      "required": [
        "score",
        "outcome",
        "fighter",
        "cleared",
        "achievedAt",
        "ref"
      ],
      "type": "object"
    },
    "main": {
      "description": "One per player (key self): their all-time best and this week's best, each pointing at the at.skeetfighter.score record it came from.",
      "key": "literal:self",
      "record": {
        "properties": {
          "allTime": {
            "description": "The player's best score ever.",
            "ref": "#entry",
            "type": "ref"
          },
          "updatedAt": {
            "format": "datetime",
            "type": "string"
          },
          "week": {
            "description": "The player's best score in the week starting at weekStart.",
            "ref": "#weekEntry",
            "type": "ref"
          }
        },
        "required": [
          "allTime",
          "updatedAt"
        ],
        "type": "object"
      },
      "type": "record"
    },
    "weekEntry": {
      "properties": {
        "achievedAt": {
          "format": "datetime",
          "type": "string"
        },
        "cleared": {
          "type": "boolean"
        },
        "fighter": {
          "format": "did",
          "type": "string"
        },
        "outcome": {
          "knownValues": [
            "cleared",
            "gameOver",
            "continued",
            "quit"
          ],
          "type": "string"
        },
        "ref": {
          "ref": "com.atproto.repo.strongRef",
          "type": "ref"
        },
        "score": {
          "maximum": 99999999,
          "minimum": 0,
          "type": "integer"
        },
        "weekStart": {
          "description": "The Monday 00:00 UTC that starts the week.",
          "format": "datetime",
          "type": "string"
        }
      },
      "required": [
        "score",
        "outcome",
        "fighter",
        "cleared",
        "achievedAt",
        "ref",
        "weekStart"
      ],
      "type": "object"
    }
  },
  "description": "A Skeet Fighter II player's best scores, kept so a scoreboard can read one record per player.",
  "id": "at.skeetfighter.best",
  "lexicon": 1
}
```
