denom
untyped stringValue
"ugnot"
Window
int64The rules, fixed at deploy. Times are block heights.
Value
2000
Floor
int64The rules, fixed at deploy. Times are block heights.
Value
300
Life
int64The rules, fixed at deploy. Times are block heights.
Value
100000
BumpPct
int64The rules, fixed at deploy. Times are block heights.
Value
20
DividendPct
int64The rules, fixed at deploy. Times are block heights.
Value
50
MinWrite
int64The rules, fixed at deploy. Times are block heights.
Value
1000000
PerByte
int64The rules, fixed at deploy. Times are block heights.
Value
1000
MaxLen
untyped bigintThe rules, fixed at deploy. Times are block heights.
Value
(280 <untyped> bigint)
clk
*v0.Clock- OID
- 0110e8…6f8e:33
clk details
ledger
*v0.Ledger- OID
- 0110e8…6f8e:35
ledger details
message
stringValue
""
author
.uverse.addressValue
<gnolang.StringValue>
paid
int64// what the current holder paid
Value
0
pot
int64// what settlement will split
Value
0
writers
v0.Tree// address string -> int64 total paid
- OID
- 0110e8…6f8e:38
writers details
order
[]string// writers in first-write order, so the split is deterministic
Value
<zero>
writes
int64Value
0
settled
boolValue
false
init.19
func()- OID
- 0110e8…6f8e:17
init.19 details
open
func(h int64)open resets the game to a fresh slot at height h. It is the only place the clock is built, so tests and init cannot disagree about the rules.
- OID
- 0110e8…6f8e:19
open details
Price
func(msg string) int64Price returns what msg costs to write right now, in ugnot: a base, plus a charge per byte, and always at least one ugnot more than the current holder paid. Query it before sending; an underpaying write is refused, not refunded.
- OID
- 0110e8…6f8e:20
Price details
Write
func(msg string)Write puts msg in the slot and makes the caller its holder. The caller must send at least Price(msg) ugnot with the transaction. Half of the payment is credited to the writer being displaced and the rest joins the pot. The deadline is pushed a fifth of the way toward the hard end, never past it, and never to less than Floor from now. Only a direct user transaction may write, so the payment envelope cannot be spoofed by an ephemeral MsgRun realm.
- OID
- 0110e8…6f8e:21
Write details
Settle
func()Settle closes the game once the clock has run out, splitting the pot among every writer EXCEPT the one holding the slot, pro rata to what each paid. Anyone may call it: leaving settlement to an interested party is how a pot stays unclaimed. It moves no coins, it credits the ledger; Withdraw is what pays. If the holder is the only writer there is nobody else to split with, so the pot returns to them.
- OID
- 0110e8…6f8e:22
Settle details
Withdraw
func() int64Withdraw pays the caller everything credited to them and returns the amount. Dividends are claimable while the game runs; settlement shares only after Settle.
- OID
- 0110e8…6f8e:23
Withdraw details
Message
func() stringMessage returns the slot's current contents, raw. Render is what escapes it.
- OID
- 0110e8…6f8e:24
Message details
Author
func() .uverse.address- OID
- 0110e8…6f8e:25
Author details
Pot
func() int64Pot returns what settlement will split.
- OID
- 0110e8…6f8e:26
Pot details
Deadline
func() int64Deadline returns the height the slot closes at.
- OID
- 0110e8…6f8e:27
Deadline details
Owed
func(addr .uverse.address) int64Owed returns what an address can Withdraw right now.
- OID
- 0110e8…6f8e:28
Owed details
totalPaid
func(key string) int64totalPaid returns what an address has paid in total, zero if it never wrote.
- OID
- 0110e8…6f8e:29
totalPaid details
gnot
func(ugnot int64) string- OID
- 0110e8…6f8e:30
gnot details
Render
func(path string) stringRender shows the slot, the clock and the money. The message is caller-typed text, so it goes through ui.Inline: a stored string that renders as markdown is a phishing link on a page nobody can edit, and this realm's whole product is a string somebody else wrote.
- OID
- 0110e8…6f8e:31