Move
typeMove is one of rock, paper, or scissors, ordered so that (winner - loser + 3) % 3 == 1 for every winning pair.
Value
v0.Move
Rock
v0.MoveValue
<zero>
Paper
v0.MoveValue
<zero>
Scissors
v0.MoveValue
<zero>
moveName
func(m v0.Move) string- OID
- 0c5315…282b:3
moveName details
parseMove
func(s string) (v0.Move, bool)- OID
- 0c5315…282b:5
parseMove details
judge
func(p v0.Move, h v0.Move) intjudge returns 0 for a tie, 1 if p beats h, 2 if h beats p.
- OID
- 0c5315…282b:6
judge details
beats
func(m v0.Move) v0.Movebeats returns the move that defeats m.
- OID
- 0c5315…282b:7
beats details
playerState
typeplayerState is the persisted record for one address.
Value
v0.playerState
players
v0.Tree// address string -> \*playerState
- OID
- 0c5315…282b:9
players details
nonce
intValue
0
totalRounds
intValue
0
oracleCorrect
int// rounds the oracle won by successfully countering
Value
0
topOutwitter
.uverse.addressValue
<zero>
topOutwitterWins
intValue
0
getOrCreate
func(addr .uverse.address) *v0.playerState- OID
- 0c5315…282b:15
getOrCreate details
predict
func(ps *v0.playerState, seed int64) v0.Movepredict guesses the player's next move as the most-played move in their history so far. Ties (including a fresh player's all-zero history) fall back to a chain-height-derived seed so the oracle doesn't always break ties the same way.
- OID
- 0c5315…282b:16
predict details
Play
func(moveStr string) stringPlay pits the caller against the oracle: it predicts your next move from your own move history and throws the counter. Accepts "rock"/"paper"/"scissors" or the single-letter shorthand "r"/"p"/"s".
- OID
- 0c5315…282b:17
Play details
renderHome
func() string- OID
- 0c5315…282b:18
renderHome details
escapeInline
func(s string) stringescapeInline neutralizes markdown-active characters in untrusted text before it's embedded inline in Render output.
- OID
- 0c5315…282b:19
escapeInline details
renderPlayer
func(rawAddr string) string- OID
- 0c5315…282b:20
renderPlayer details
Render
func(path string) stringRender shows the oracle's dashboard at "", or one player's record when path is their bech32 address.
- OID
- 0c5315…282b:21