DOCS
How Libregochi works under the pixels: payments, the contract, the rules and the resources it uses on Libre. Written for builders, block producers and anyone who wants to check our work.
The numbers and graphs on this page are generated from the code the game runs, so they change when the rules do.
At a glance
- A 32×32 pixel pet game on Libre (Antelope/Leap 5). Pets never die; neglected ones get sick and recover with care.
- Players design their pet in a creator (8 bodies, 16 palettes, 12 eyes, 10 patterns). Nothing is rolled.
- Care is free: every feed, play, clean and nap is a transaction with 0 fees.
- Items have fixed prices in LIBRE, BTC or USDT, shown before paying. No token of our own, no staking, no farming.
- Pets, items, stats and XP live in the
libregochicontract. There is no game server; the chain is the database.
Architecture
libregochi.com is a static Next.js export on Cloudflare. The browser reads the contract's tables straight from Libre nodes, with failover between endpoints, and the keeper's wallet signs every action. A small Worker handles only /api/* (the Telegram bot and pet cards). Each build is fixed to one network, so nobody signs on the wrong chain.
SHOW THE NUMBERS
| Part | What it does |
|---|---|
| libregochi.com | Static site on Cloudflare; a Worker only for /api/* |
| Browser | Draws the pet and computes live stats with the same rules as the contract |
| Wallet | WharfKit: Bitcoin Libre or Anchor; signs each action |
| Libre nodes | get_table_rows reads, 3 mainnet endpoints with failover |
| libregochi | Holds pets, items, players; runs the rules |
The rules live in one TypeScript package with integer math only. The C++ contract implements the same rules, and both run the same shared test vectors, so the stats the page shows are the stats the chain stores.
A visitor without a wallet can try a guest pet. It runs the same shared rules inside the browser, is kept in localStorage and never touches the chain. Adopting starts a fresh egg with the same look, name and personality.
Networks and accounts
| Network | Chain ID | Endpoints |
|---|---|---|
| Libre Mainnet | 38b1d7815474d0c60683ecbea321d723e83f5da6ae5f1c1f9fecc69d9ba96465 | https://lb.libre.org https://api.libre.cryptobloks.io https://libre.greymass.com |
| Libre Testnet | b64646740308df2ee06c6b72f34c0f7fa066d940e831f752db2006fcc2b78dee | https://testnet.libre.org https://api.testnet.libre.cryptobloks.io https://libretestnet.greymass.com |
libregochi: the game contract. Every purchase is a transfer to it.gochivault: receives 70% of LIBRE and 90% of BTC and USDT payments. It is the studio's account: it pays for running and building the game, the developer's pay included.eosio.null: burned LIBRE goes here. Nobody holds its keys.- Status: the contract goes to testnet first, once the board grants it resources; mainnet follows a testnet play-test and a security review. The testnet build lives at
testnet.libregochi.com(every change lands there first, marked TESTNET, with test LIBRE that has no value);libregochi.comchanges only on a release. Progress is on the roadmap.
Paying
Every purchase is a plain token transfer to libregochi with a memo. The Bitcoin Libre wallet shows only from, to, quantity and memo when it asks to sign, so that is everything a purchase needs. The contract reacts to the transfer notification and splits the payment on the spot; it keeps nothing.
LIBRE
BTC
USDT
SHOW THE NUMBERS
| Token | Vault | Burned | Referrer |
|---|---|---|---|
| LIBRE | 70% | 20% | 10% |
| BTC | 90% | 0% | 10% |
| USDT | 90% | 0% | 10% |
MEMOS
adopt:<name>;l=<look>[;p=<1-5>][;f=1][;r=<referrer>] an egg designed as <look>, with a personality; f=1 makes it the Founder egg buy:<templateId>[;r=<referrer>] a wearable, into the inventory buy:<templateId>:<petId>[;r=<referrer>] food, care or a helper, used on a pet rename:<petId>:<name> a new name personality:<petId>:<1-5> a new personality for a pet
| adopt:Mochi;l=3.12.7.4.g;p=4 | adopt an egg named Mochi, designed as body 3, palette 12, eyes 7, pattern 4, a girl, with the calm personality (p=4) |
| adopt:Mochi;l=3.12.7.4.g;p=4;f=1 | the same egg, bought as a Founder egg (f=1): one per keeper, numbered in order of purchase |
| buy:22;r=alice | buy item 22 (the Witch hat) into the inventory; alice invited this keeper |
| buy:18:42 | buy item 18 (an XP Snack) and use it on pet 42 right away |
| rename:42:Sir Mochi | rename pet 42 |
| personality:42:4 | give pet 42 the calm personality |
The template and pet ids above are examples.
- Only
eosio.tokenLIBRE (4 decimals) ,btc.libreBTC (8 decimals) andusdt.libreUSDT (8 decimals) are accepted, checked by the notification's first receiver, so a look-alike token is refused. - The quantity must be exactly the price in the templates table. Anything else is refused and the whole transfer reverts.
r=<referrer>is bound once: the first purchase that names a referrer sets it, and it never changes after that. Nobody can invite themselves, and a token contract can't be a referrer (usdt.librerefuses transfers to itself, so it would block that keeper's USDT purchases). The referrer's share goes to the vault when the referrer has no balance row for that token, because creating one would cost the contract RAM. A referrer's share arrives as a transfer fromlibregochiwith the memoLibregochi: thanks for inviting a keeper, which is how /play lists a keeper's referral rewards.- The read-only
checkmemoaction says what a memo means, or why it would be refused, so wallets and tools can check one before signing. The web app builds memos with the same grammar the contract parses. - The starter egg is free:
claimstarter, once per keeper, soulbound, for accounts that hold at least 1,000 LIBRE, 1,000 sats or 1 USDT, which keeps throwaway accounts from farming eggs.
Prices
Prices are set in US dollars and stored in the contract's templates table as fixed LIBRE, sats and USDT amounts. LIBRE and BTC are checked on the 1st of each month and repriced only when a rate has moved more than 25%, announced a week ahead; between repricings their prices don't move. USDT is a dollar, so its price is the dollar price itself and is never repriced.
The LIBRE rate comes from the swap.libre BTC/LIBRE pool (BLLP) times BTC/USD, as a 7-day median. The on-chain oracle and the price trackers lag behind for LIBRE, so we don't use them.
SHOW THE NUMBERS
| Item | Kind | USD |
|---|---|---|
| Kibble bowl | food | 1¢ |
| Cookie | food | 2¢ |
| Rice ball | food | 2¢ |
| Soap | care | 2¢ |
| Strawberry | food | 3¢ |
| Pizza | food | 5¢ |
| Toy ball | care | 5¢ |
| Comfy Pillow | helper | 10¢ |
| Medicine | care | 10¢ |
| XP Snack | helper | 10¢ |
| Warm Blanket | helper | 25¢ |
| Party hat | wearable | 30¢ |
| Round glasses | wearable | 30¢ |
| Cozy scarf | wearable | 40¢ |
| Flower crown | wearable | 40¢ |
| Personality Change | service | 50¢ |
| Star shades | wearable | 50¢ |
| Witch hat | wearable | 50¢ |
| Raincoat | wearable | 60¢ |
| Tiny wings | wearable | $1.00 |
| Extra egg | pet | $1.50 |
The Founder egg is a launch-week keepsake at $5.00, listed as template 4 by the owner and closed again with settemplate (on_sale false) when the week ends. Buy it with adopt and f=1: the pet's serial is its number, in order of purchase, and it stays on the pet when it is given away. One per keeper: the founders table remembers who bought, so giving the pet away doesn't make room for a second egg. The cap of 500 is only a backstop. Nothing about it is random, and the pet card shows "Founder #N" without the cap.
35 Founder numbers are protected (protectfnd, at most 100): the public order steps over them, and the owner gives each one to a single keeper with grantfnd, as a thank-you. That keeper adopts it at the same price, even after launch week, and the foundernums table keeps the row once it's adopted, so no number is ever issued twice. Protected numbers are given, never sold, auctioned or drawn.
The contract
One contract, libregochi. Every action that changes state calls require_auth on the account it acts for. Purchases aren't actions: the contract reacts to transfers sent to it. It accepts only eosio.token / btc.libre / usdt.libre::transfer; any other token is refused, so that transfer fails.
CARE (THE KEEPER SIGNS; FREE)
setoffset(keeper: name, minutes: int16)
Sets the keeper's local day for routines, daily caps and the streak. Once only; the web app sends it with the first care action. Signed by: keeper.
feed(keeper: name, pet_id: uint64)
A free bowl (+30 hunger), 3 per pet per local day. More food is bought. Signed by: keeper.
play(keeper: name, pet_id: uint64)
+20 happiness, −10 energy; once an hour. Signed by: keeper.
clean(keeper: name, pet_id: uint64)
Hygiene back to 100; every 2 hours. Signed by: keeper.
sleep(keeper: name, pet_id: uint64)
A nap: energy comes back at 25 an hour until it's full, and the pet wakes on its own. Signed by: keeper.
wake(keeper: name, pet_id: uint64)
Ends a nap early. The pet keeps the energy it has slept so far and loses 1 happiness for every 10 minutes of nap left (at most 20). Needs a nap of 30 minutes and energy 30. No XP; a Comfy Pillow wakes it with no cost. Signed by: keeper.
pet(keeper: name, pet_id: uint64, taps: uint16)
Petting from the browser, synced at most every 4 hours. Adds happiness and a little capped XP; not a care action for the streak. Signed by: keeper.
minigame(keeper: name, pet_id: uint64, game: uint8, score: uint32)
A finished skill game. XP is capped per play and per day, so a made-up score gains nothing extra. Signed by: keeper.
STARTER EGG
claimstarter(keeper: name, pet_name: string, look: string, personality: uint8)
The free starter egg: one per keeper, soulbound, a daily cap for everyone together, and a little LIBRE, BTC or USDT in the account. Signed by: keeper.
WEARABLES AND GIFTS
equip(keeper: name, pet_id: uint64, item_id: uint64)
Puts a wearable on a pet; whatever was in that slot goes back to the inventory. Signed by: keeper.
unequip(keeper: name, item_id: uint64)
Takes a wearable off. Signed by: keeper.
gift(from: name, to: name, pet_ids: uint64[], item_ids: uint64[], memo: string)
Gives pets and items to another keeper for free. Soulbound ones can't be given; a pet keeps what it wears, except soulbound items. Signed by: from.
claimgift(keeper: name, pet_id: uint64)
Opens the keeper's next gift from the Daily Gift Calendar, once per local day (the time zone must be set): a treat used on the pet (its stat effect only), a free streak freeze, or a soulbound wearable (docs/game-design.md §16.1). Signed by: keeper.
READ-ONLY
checkmemo(memo: string)
Returns what a memo means, or why it would be refused. Wallets and tools can check a memo with it before signing. Signed by: none (read-only).
ADMIN (ON MAINNET, SIGNING REQUESTS THE OWNER SIGNS)
setconfig(vault: name, hatch_delay_sec: uint32, starters_per_day: uint32, bodies: uint8, palettes: uint8, eyes: uint8)
Game settings. On mainnet every admin action is a signing request the owner signs. Signed by: libregochi.
settemplate(tpl: template_row)
Adds or reprices a shop item. An item's kind and slot never change, and `sold` is counted by the contract. Signed by: libregochi.
pause(paused: bool)
Stops or resumes purchases, starter eggs, care, equipping and gifts, for incidents. The contract starts paused. Signed by: libregochi.
protectfnd(serials: uint32[])
Keeps Founder numbers back from the public counter, to give to people. At most 100 in all; a number already protected is skipped. Never sold, auctioned or drawn. Signed by: libregochi.
grantfnd(serial: uint32, holder: name)
Gives a protected Founder number to one keeper, who adopts it at the same price, even after launch week. One per keeper; it can be taken back until adopted. Signed by: libregochi.
TABLES
Every table is in scope libregochi. Rows have a bounded size: names are at most 16 characters, and daily counters are keyed by day number and overwritten, never appended to.
config key singleton
Game settings.
7 FIELDS
paused bool vault name receives the vault share hatch_delay_sec uint32 starters_per_day uint32 free starter eggs, all keepers together bodies uint8 creator option counts palettes uint8 eyes uint8 state key singleton
Counters for new ids, which are never reused.
4 FIELDS
next_pet_id uint64 next_item_id uint64 starter_day uint32 UTC day number of the counter below starters_today uint32 templates key id
Everything the shop sells, at fixed prices in both currencies.
17 FIELDS
id uint64 1 = egg, 2 = rename, 3 = personality change key string catalog key, e.g. xp-snack kind uint8 1 food, 2 care, 3 helper, 4 streak, 5 egg, 6 wearable, 7 service slot uint8 wearables: 1 head, 2 face, 3 body, 4 back min_level uint8 price_libre int64 LIBRE units, 4 decimals price_sats int64 BTC units, 8 decimals price_usdt int64 USDT units, 8 decimals: the dollar price itself hunger int8 stat effects when used, −100..100 happiness int8 energy int8 hygiene int8 xp uint16 max_supply uint32 0 = unlimited sold uint32 on_sale bool special uint8 0 none, 1 medicine, 2 XP Snack, 3 Comfy Pillow, 4 Warm Blanket players key account
One row per keeper.
15 FIELDS
account name referrer name bound once; empty = none utc_offset_min int16 offset_set bool starter_claimed bool joined uint32 streak_days uint16 streak_last_day uint32 local day number freezes uint8 broken_day uint32 days_before uint16 the streak before a break, for repair pets_owned uint16 at most 30 items_owned uint16 at most 300 care_day uint32 care_today uint8 care actions toward today's streak day wishes key keeper
One row per keeper, created on the first wish done or album moment: today's wishes, the weekly card and the moments album (docs/game-design.md §9.1).
7 FIELDS
keeper name day uint32 local day the done bits belong to done uint8 bit i = wish i of that day is done week uint16 Monday-to-Sunday week the day bits belong to day_bits uint8 bit i = all three wishes done on weekday i stars uint16 weekly cards filled album uint32 moments album, one bit per moment gifts key keeper
One row per keeper, created on the first opened gift: the Daily Gift Calendar's count for the month and the wearables already given (docs/game-design.md §16.1).
5 FIELDS
keeper name month uint16 months since January 1970 the count belongs to opened uint8 gifts opened that month, up to 28 last_day uint32 local day of the last opened gift wearables uint8 bit i = the calendar's i-th wearable has been given founders key account
One row per keeper who bought a Founder egg (adopt with f=1): the one-per-keeper rule holds even after the pet is given away. The number is also the pet's `serial`.
2 FIELDS
account name serial uint32 the number on their Founder pet, in order of purchase foundernums key serial · index byholder (holder)
Protected Founder numbers: the public counter skips them, and each goes to the keeper the owner gives it to. The row stays after adoption, so a number is never issued twice.
3 FIELDS
serial uint32 holder name empty until given claimed bool adopted fndcounter key singleton
The public Founder counter.
2 FIELDS
last uint32 the last public number handed out protected_count uint32 protected numbers, at most 100 pets key id · index byowner (owner)
One row per pet, fixed size. Stats are stored at last_update and decay is computed when read or acted on.
55 FIELDS
id uint64 owner name name_text string body uint8 the look, chosen by the keeper palette uint8 eyes uint8 pattern uint8 gender uint8 0 boy, 1 girl gen uint16 tradable bool false for the starter created uint32 hatch_at uint32 hunger uint8 0–100 at last_update happiness uint8 energy uint8 hygiene uint8 last_update uint32 asleep_until uint32 neglect_since uint32 0 = cared for sick_since uint32 0 = healthy good_since uint32 start of the current run of good care xp uint32 xp_day uint32 local day of the counters below xp_care uint8 today's XP per capped source xp_routine uint8 xp_minigame uint8 xp_petting uint8 xp_healthy uint8 plays_today uint8 bowls_today uint8 routines_today uint8 bit 0 morning, bit 1 bedtime, bit 2 fed today snacks_today uint8 pillows_today uint8 last_play uint32 last_clean uint32 last_pet uint32 cs_minigames uint16 care-style counters for this stage cs_petting uint16 cs_cleaning uint16 cs_feeding uint16 cs_naps uint16 style_teen uint8 style_adult uint8 worn_head uint64 item ids; 0 = nothing worn_face uint64 worn_body uint64 worn_back uint64 personality uint8 1–5, picked at adoption (personality.ts); 0 = not picked mom uint64 parent pet ids, 0 for Gen 0 dad uint64 serial uint32 founder number, 0 = not a founder talent_0 uint8 the talent picked in each slot, 0 = none talent_1 uint8 tm_0 uint32 uses of each slot's talent (mastery) tm_1 uint32 items key id · index byowner (owner)
Wearables and other kept items.
6 FIELDS
id uint64 owner name template_id uint64 pet_id uint64 the pet wearing it; 0 = in the inventory serial uint32 limited editions only tradable bool
Once the contract is deployed, read a keeper's pets from any node, for example:
curl -s https://lb.libre.org/v1/chain/get_table_rows \
-H 'content-type: application/json' \
-d '{"code":"libregochi","scope":"libregochi","table":"pets",
"index_position":2,"key_type":"name",
"lower_bound":"alice","upper_bound":"alice","json":true}'Stats in a row are as stored at last_update. Decay since then is computed, not stored: the rules below give the current values, the same way the contract settles a pet before every action.
Game rules
- Stats run 0–100 and fall every hour: hunger 3, happy 2, energy 3, clean 2. A nap brings energy back at 25 an hour.
- A nap can be cut short with stop producing (the
wakeaction) once it has run 30 minutes and energy is at least 30. The pet keeps the energy it has slept so far and misses blocks: happiness drops by 1 for every 10 minutes of nap left, at most 20. It is not a care action: no XP, no streak. A nap that starts within 6 hours of the last one ending pays no care XP. A Comfy Pillow wakes it rested with no cost. The cost is computed fromasleep_until, so the row has no new field. - Poking a napping pet, hugging, belly rubs and the ball are browser touches. A hug and a belly rub each count as one petting tap, like a tap on the pet; pokes and the ball are not taps. Only the petting taps are signed, and the contract caps their XP.
- Free care: 3 top ups a day (bowls), a ping every 1 h, a prune every 2 h, and signing (petting) synced every 4 h.
- Orphaned blocks pile up in the room as clean drops below 70, 45 and 20: one more pile each time, up to three. Tapping a pile sends the same prune action, so it follows the same 2 h cooldown. Nothing is awarded and nothing is random.
- Hunger or hygiene at zero for 24 h makes a pet sick (shown as out of sync). A hotfix (medicine) cures it at once, or 12 h in a row of good care (hunger and hygiene at least 50) cures it for free. It never dies.
- Days are the keeper's local days, from a time zone they set once (
setoffset). - A personality is chosen at adoption, next to the look: 1 Shy, 2 Bold, 3 Goofy, 4 Calm, 5 Curious. It changes how a pet idles and what it says after care, and nothing else: no stat, price or XP depends on it, and only the keeper chooses it. It is stored in the
personalitycolumn (0 = not picked). A keeper can change it later for a fixed price (Personality Change, in the price list below), by paying with the memopersonality:<petId>:<1-5>; a change to the personality the pet already has is refused, so nobody pays for no change.
LEFT ALONE
SHOW THE NUMBERS
| Hour | Hunger | Happy | Energy | Clean |
|---|---|---|---|---|
| 0 | 100 | 100 | 100 | 100 |
| 6 | 82 | 88 | 82 | 88 |
| 12 | 64 | 76 | 64 | 76 |
| 18 | 46 | 64 | 46 | 64 |
| 24 | 28 | 52 | 28 | 52 |
| 30 | 10 | 40 | 10 | 40 |
| 36 | 0 | 28 | 0 | 28 |
| 42 | 0 | 16 | 0 | 16 |
| 48 | 0 | 4 | 0 | 4 |
| 54 | 0 | 0 | 0 | 0 |
| 60 | 0 | 0 | 0 | 0 |
| 66 | 0 | 0 | 0 | 0 |
| 72 | 0 | 0 | 0 | 0 |
CARED FOR
SHOW THE NUMBERS
| Hour | Hunger | Clean |
|---|---|---|
| 0 | 100 | 100 |
| 6 | 82 | 88 |
| 8 | 76 | 84 |
| 8 | 100 | 84 |
| 12 | 88 | 76 |
| 14 | 82 | 72 |
| 14 | 100 | 72 |
| 18 | 88 | 64 |
| 21 | 79 | 58 |
| 21 | 100 | 100 |
| 24 | 91 | 94 |
| 30 | 73 | 82 |
| 32 | 67 | 78 |
| 32 | 97 | 78 |
| 36 | 85 | 70 |
| 38 | 79 | 66 |
| 38 | 100 | 66 |
| 42 | 88 | 58 |
| 45 | 79 | 52 |
| 45 | 100 | 100 |
| 48 | 91 | 94 |
| 54 | 73 | 82 |
| 56 | 67 | 78 |
| 56 | 97 | 78 |
| 60 | 85 | 70 |
| 62 | 79 | 66 |
| 62 | 100 | 66 |
| 66 | 88 | 58 |
| 69 | 79 | 52 |
| 69 | 100 | 100 |
| 72 | 91 | 94 |
XP AND LEVELS
- XP comes from care, routines, petting, minigames and healthy days, and from one paid helper, the XP Snack (+25 XP, 1 per pet per day, not while sick). The free sources need the pet well (no stat under 20, not sick) and each has a daily cap per pet: care 40, routine 10, minigame 60, petting 10, healthy 10.
- Routines: +5 for looking after the pet between 6:00 and 10:00, and again between 20:00 and midnight, local time. +10 for the first action of each day while the pet is well.
- Minigames are skill only: up to 30 XP a play for 3 plays a day, and 60 a day at most. Scores are self-reported, which is why the caps exist: a made-up score gains no more than a good one. Mempool Dive is the first (the contract still calls it snack-catch): 45 seconds of diving down a shaft that scrolls past, steering the pet along the corridor to catch snacks. The shaft narrows as the dive goes on and forks now and then into a wide, safe lane and a tight lane with the big snacks. A snack is worth 1, a big snack 2 and the pet’s favourite 3. Catches in a row raise a combo multiplier (×2 from 8, ×3 from 20) that adds a bonus on top; the bonus is shown but never sent, so the score stays the plain points. A missed snack in the lane the pet is in, or a bubble, starts the combo over (at a fork the other lane’s snacks don’t count as missed), and a bubble makes the pet sneeze. Bumping a wall pushes the pet back into the lane, makes it dizzy for 0.6 seconds (it steers at 50% of its speed) and starts the combo over, and the run goes on. Passing a ledge, a fork’s post or a bubble within 2.5 pixels without touching it is a close shave and adds 2 to the same shown-only bonus. Nothing ever costs points or ends a play early. A leaf slows time for 3 seconds. The pace builds from calm to busy, and the dive goes down through a garden, roots and a crystal cave to the pantry at the bottom (the backdrops are looks only and never change the score). The score is the points, and 60 earns the full 30 XP; the safe lane alone holds more than that. The day’s dive is the same for everyone, and your best run of the day is kept in your browser as a faint ghost to race next time; the end screen can be shared as a plain link. Each play adds 10 happiness and costs 15 energy.
- Uptime: a day with 3 care actions (feed, play, clean, sleep, shown as top up, ping, prune, produce blocks, stop producing) counts. Each uptime day adds +10% to care XP, up to +50%. A free failover (freeze) comes every 7 uptime days, at most 2 held.
- The mempool (the daily wishes): 3 a day from a fixed weekly rotation, the same for every keeper on the same local day, so tomorrow’s wishes can be read today: Monday pet, Mempool Dive, feed; Tuesday bath, play, second feed; Wednesday nap, pet, Mempool Dive; Thursday feed, bath, play; Friday second feed, nap, pet; Saturday Mempool Dive, feed, bath; Sunday play, second feed, nap. A wish is done inside the care action that fulfils it, with no claim and no extra transaction: the second feed is a feed of a pet already fed that day (a bowl or bought food), petting needs at least 15 taps, and a Mempool Dive at least 40 points within the day’s 3 rewarded plays. Each wish is +3 XP, 9 for a full day, through the same XP gate as all XP; a sick pet’s wish still counts as done. All three on 5 of a week’s 7 days (Monday to Sunday) fill the weekly card for a star, a cosmetic count with badges at 1, 4, 12 stars. The keeper’s moments album keeps 14 firsts (first bath, nap, petting, Mempool Dive, healing, full wish day, star, level 2, teen, adult, and the streak milestones). Today’s wishes, the card and the album show under the pet on the play page, and the stars and moments on each of the keeper’s pet pages. Wishes follow a fixed rotation, cost no LIBRE and can’t be bought.
- Gift calendar: one gift a day, opened with
claimgift, from a published calendar of 28, the same for every keeper. Gifts are numbered by opening, not by date, so a missed day skips nothing; the count starts again on the 1st of the keeper’s local month. Each week of the calendar is Cookie, Soap, Strawberry, Toy ball, Rice ball, Pizza, then a special gift: gift 7 the Party hat, soulbound (a Pizza once given); gift 14 a free freeze (a Cookie at the hold limit or for a streak that has already lapsed); gift 21 the Cozy scarf, soulbound (a Rice ball once given); gift 28 the Flower crown, soulbound (a Strawberry once given). A treat is used on the pet the keeper picks (hatched and awake) and gives that item’s stat effect only: no XP of any kind, no wish, no streak care. Each wearable is given once per keeper, ever; at the 300-item limit it waits for another month. The calendar is published in advance, costs no LIBRE and can’t be bought.
SHOW THE NUMBERS
| Level | Total XP |
|---|---|
| 1 | 0 |
| 2 | 24 |
| 3 | 72 |
| 4 | 144 |
| 5 | 240 |
| 6 | 360 |
| 7 | 504 |
| 8 | 672 |
| 9 | 864 |
| 10 | 1,080 |
| 11 | 1,320 |
| 12 | 1,584 |
| 13 | 1,872 |
| 14 | 2,184 |
| 15 | 2,520 |
| 16 | 2,880 |
| 17 | 3,264 |
| 18 | 3,672 |
| 19 | 4,104 |
| 20 | 4,560 |
| 21 | 5,040 |
| 22 | 5,544 |
| 23 | 6,072 |
| 24 | 6,624 |
| 25 | 7,200 |
| 26 | 7,800 |
| 27 | 8,424 |
| 28 | 9,072 |
| 29 | 9,744 |
| 30 | 10,440 |
SHOW THE NUMBERS
| Day | Daily, free | Daily, misses 1 in 10 | Casual, once a day | Daily, buys helpers | Weekends only |
|---|---|---|---|---|---|
| 1 | 3 | 3 | 2 | 4 | 1 |
| 5 | 7 | 7 | 4 | 9 | 1 |
| 10 | 10 | 10 | 5 | 13 | 3 |
| 15 | 13 | 12 | 6 | 16 | 4 |
| 20 | 14 | 14 | 6 | 18 | 4 |
| 25 | 16 | 16 | 7 | 20 | 5 |
| 30 | 18 | 17 | 8 | 22 | 6 |
| 35 | 19 | 19 | 9 | 24 | 7 |
| 40 | 21 | 20 | 9 | 26 | 7 |
| 45 | 22 | 21 | 10 | 27 | 8 |
| 50 | 23 | 22 | 10 | 29 | 8 |
| 55 | 24 | 23 | 11 | 30 | 8 |
| 60 | 25 | 24 | 11 | 31 | 9 |
RAM and CPU
The contract pays the RAM for every row it creates. Players can't: new Libre accounts get 5,120 bytes and there's no RAM market. Purchases are handled in a transfer notification, where Leap's RAM_RESTRICTIONS doesn't let a contract bill the sender. And an extra action just to pay for RAM wouldn't read clearly on the wallet's signing sheet.
So nobody can drain it:
- rows have a bounded size;
- at most 30 pets and 300 items per keeper, and at most 10 pets and 10 items per gift;
- free starter eggs have a daily cap for everyone together.
SHOW THE NUMBERS
| Bytes | |
|---|---|
| Mainnet ask | 2,000,000 |
| Contract code and ABI | 1,471,098 |
| One keeper (2 pets, 3 items) | 2,047 |
| Keepers that fit | 258 |
| Ask for more at | 1,600,000 |
CPU and NET: the game is designed for at most 30 small transactions per keeper a day, each well under a millisecond, within what a Libre account with a weight of 1 gets (about 430 ms of CPU a day).
Nothing left to chance
- Pets are designed by the keeper, never rolled.
- Prices are fixed and shown before paying. Every paid item is exactly what it says: no mystery boxes, no draws. Boxes, when they come, show their contents before purchase.
- Surprise comes from timing and published calendars. Nothing paid for or awarded depends on chance, so there is no draw to audit. Purely cosmetic moments, like the weather, may vary; they award nothing.
- Leaderboards give badges only. Contests are free to enter, judged by a named jury, with cosmetic prizes.
- Players read the short version in How it works, the FAQ and the Terms: 18+, items delivered at once, and a withdrawal agreement the shop asks for once, before the first purchase.
Security and keys
require_authon every action; only the two accepted tokens; exact prices; 128-bit split math with the remainder to the vault.- The contract uses no host functions Libre hasn't activated. The build fails if one sneaks in.
- Tests run the real contract in Vert against mainnet's token contracts, including an attacker contract that forwards fake transfers.
- No chain keys in code or CI. Mainnet deploys and admin actions are signing requests the owner signs in their own wallet. The contract starts paused and can be paused in an incident.
Coming at launch
- The contracts and rules go public, with a reproducible build and the WASM hash, so anyone can check that the code on chain is the code we publish.
- An external security review before mainnet.
- Questions or a bug? Email hello@libreslav.com. Libregochi is made by Libreslav, a Libre block producer.
Canonical address: https://libregochi.com/docs