forked from retoor/devplacepy
Quiiz system
This commit is contained in:
@@ -42,7 +42,7 @@ and a level at which it unlocks. Slower crops pay far more per build.
|
||||
| 🦀 Rust Engine | `rust` | 200 | 30m | 520 | 60 | level 4 |
|
||||
| λ Compiler | `haskell` | 500 | 1h | 1380 | 150 | level 6 |
|
||||
| ⚙️ Kernel | `kernel` | 1200 | 2h | 3600 | 400 | level 8 |
|
||||
| 🕸️ Distributed System | `distsys` | 5000 | 4h | 9500 | 900 | level 20 + Mastery |
|
||||
| 🕸️ Distributed System | `distsys` | 5000 | 4h | 11300 | 900 | level 20 + Mastery |
|
||||
| 🧠 ML Pipeline | `mlpipe` | 12000 | 6h | 21000 | 1800 | level 20 + Mastery |
|
||||
| 🔐 Security Fortress | `secfort` | 30000 | 8h | 48000 | 3200 | level 20 + Mastery |
|
||||
|
||||
@@ -131,10 +131,13 @@ already-claimed quest returns an error.
|
||||
## Fertilizer
|
||||
|
||||
Fertilizing a growing build spends coins to **halve its remaining time**. The exact cost is
|
||||
`ceil(effective_harvest_coins * skipped_seconds / full_build_seconds * 1.05)`, where
|
||||
`effective_harvest_coins` already includes all your multipliers - so fully fertilizing a build
|
||||
always costs at least 105% of its harvest value. Fertilizer is a pure time-skip, never a profit,
|
||||
at any prestige. Each growing plot in the state reports its current `fertilize_cost`; a build
|
||||
`ceil(realizable_harvest_coins * skipped_seconds / full_build_seconds * 1.05)`, where
|
||||
`realizable_harvest_coins` is what *this specific build* will actually pay out - it includes your
|
||||
perks, prestige, Legacy multiplier, and the market factor, **and** the golden multiplier, an
|
||||
active weekly-contract boost, an active Underdog boost, and the Canary upside. Because the price
|
||||
is computed from the same value the harvest pays, fully fertilizing a build always costs at least
|
||||
105% of what it can return. Fertilizer is a pure time-skip, never a profit, at any prestige, on
|
||||
any build, with any combination of boosts. Each growing plot in the state reports its current `fertilize_cost`; a build
|
||||
with less than two seconds remaining cannot be fertilized.
|
||||
|
||||
## Golden builds
|
||||
@@ -148,7 +151,9 @@ currently stealable (a golden build is a 5x raid target too, so watch your grace
|
||||
|
||||
Visit another member's farm and water one of their **growing** builds. Watering reduces that
|
||||
build's remaining time by **8% of its full (speed-adjusted) build time** and rewards **you**, the
|
||||
visitor, with **6 coins and 3 experience**. Each visitor can water a given build **once per
|
||||
visitor, with **6 coins scaled by your own prestige and Tech Debt Payoff multiplier** (so watering
|
||||
stays worth doing at every stage of the game) plus **3 experience**. The daily bonus and daily
|
||||
quest coin rewards scale the same way. Each visitor can water a given build **once per
|
||||
growth cycle**, and a single build takes at most **3 waterings** total across all visitors, so
|
||||
popular farms fill up. Each plot reports `can_water` (true only for signed-in non-owners who have
|
||||
not watered it yet), `watered_count`, and `max_waters`. Watering also advances your own `water`
|
||||
@@ -161,25 +166,31 @@ but only after a protection window has passed since the build became ready. The
|
||||
seconds** base, **+30s** per level of the owner's Branch Protection Legacy upgrade, plus the
|
||||
owner's Defense tier grace bonus (table below).
|
||||
|
||||
The raider receives a fraction of the build's realized coin value:
|
||||
`max(floor, 50% - 5% x Branch Protection level)`. The floor comes from the owner's Defense tier
|
||||
(10% undefended, down to 4% at Zero Trust Mesh); when the owner owns the Observability Suite the
|
||||
floor is 30% instead. The owner loses the build entirely either way. A Security Fortress build
|
||||
can never be raided. The owner is notified their farm was raided but the raider's identity is
|
||||
never revealed.
|
||||
**A raid takes a share, it does not destroy the build.** The raider receives
|
||||
`min(cap, max(floor, (50% - 5% x Branch Protection level) x (1 - Defense tier reduction)))` of the
|
||||
build's realized coin value, and that share is recorded on the plot as `raided_fraction`. The
|
||||
**owner still harvests everything that was not taken** - a build raided for 35% still pays its
|
||||
owner the remaining 65%. A build can be raided until its shares add up to 100%, after which
|
||||
`steal_reason` is `stripped`. A Security Fortress build can never be raided.
|
||||
|
||||
You can raid any given neighbour only **once per hour** (per victim, so raiding several different
|
||||
farms in one hour is fine). Raiding a farm holding more than **10x** your own coins grants you a
|
||||
24-hour **Underdog** boost (+25% harvest coins, visible as
|
||||
`underdog_boost_seconds_remaining` in your state).
|
||||
The `cap` is 100% normally and **20%** when the owner owns the Observability Suite, so that
|
||||
building genuinely limits raid losses. The `floor` is the owner's Defense tier minimum. The owner
|
||||
is notified of the raider's name, the crop, and the exact amount taken.
|
||||
|
||||
You can raid any given neighbour only **once per hour**, and any given farm can be raided at most
|
||||
**3 times per day** in total, so an inactive player can never be stripped by an unlimited queue of
|
||||
raiders. Raiding a farm holding more than **10x** your own coins grants you a 24-hour **Underdog**
|
||||
boost (+25% harvest coins, visible as `underdog_boost_seconds_remaining` in your state).
|
||||
|
||||
Each plot on a farm you view reports:
|
||||
|
||||
- `can_steal` - true when everything below is satisfied and you can raid right now.
|
||||
- `steal_coins` - the exact payout a raid would give.
|
||||
- `steal_reason` - why a ready build is not stealable: `protected` (grace window still running),
|
||||
`cooldown` (you raided this owner within the hour), or `immune` (Security Fortress). Empty when
|
||||
stealable or not applicable.
|
||||
`cooldown` (you raided this owner within the hour), `stripped` (the build has already been
|
||||
raided for its full value), or `immune` (Security Fortress). Empty when stealable or not
|
||||
applicable.
|
||||
- `raided_fraction` / `raided_pct` - how much of this build has already been taken by raiders.
|
||||
- `steal_cooldown_seconds` - seconds until your per-owner cooldown ends (only set with
|
||||
`steal_reason` of `cooldown`; also mirrored farm-wide as `steal_cooldown_seconds` on the farm).
|
||||
- `ready_at` - add the protection window to compute when a raid becomes possible.
|
||||
@@ -193,7 +204,10 @@ supply measured in build time ("plot-days" at base rate), so a 30-second Shell S
|
||||
2-hour Kernel saturate on the same real-terms scale - quick crops are not punished for being
|
||||
quick. As supply piles up, the crop's payout steps down:
|
||||
|
||||
| Supply (plot-days in 48h) | Payout |
|
||||
Supply is measured **per active farm**, so a busy server is not permanently floored by a handful
|
||||
of heavy players - the thresholds scale with how many people are actually farming.
|
||||
|
||||
| Supply (plot-days in 48h, per active farm) | Payout |
|
||||
|:-------------------------:|:------:|
|
||||
| under 8 | 100% |
|
||||
| 8 or more | 85% |
|
||||
@@ -221,33 +235,37 @@ One-time, prestige-gated buildings bought with `POST /game/infrastructure/buy`:
|
||||
|
||||
| Building | Key | Effect | Cost | Requires |
|
||||
|----------|-----|--------|-----:|:--------:|
|
||||
| 📦 Private Registry | `registry` | Rust, Compiler, and Kernel builds finish 15% faster (watering them is 15% more effective too) | 25,000,000 | prestige 3 |
|
||||
| 🐤 Canary Deployments | `canary` | Every harvest has a 12% chance to double and a 6% chance to only refund its planting cost | 75,000,000 | prestige 8 |
|
||||
| 🔭 Observability Suite | `observability` | Fixes the raid payout floor at 30% of a build's value (see Raiding and Defense) | 150,000,000 | prestige 15 |
|
||||
| 📦 Private Registry | `registry` | Rust, Compiler, and Kernel builds finish 15% faster (watering them is 15% more effective too) | 3,000,000 | prestige 3 |
|
||||
| 🐤 Canary Deployments | `canary` | Every harvest has a 12% chance to double and a 6% chance to only refund its planting cost | 6,000,000 | prestige 8 |
|
||||
| 🔭 Observability Suite | `observability` | Caps what any raider can take from you at 20% of a build's value (see Raiding and Defense) | 15,000,000 | prestige 15 |
|
||||
|
||||
### Defense
|
||||
|
||||
An upgradeable building (`POST /game/defense/upgrade`) that lowers your raid losses and lengthens
|
||||
your protection window per tier:
|
||||
|
||||
| Tier | Name | Upgrade cost | Daily upkeep (min) | Raid payout floor | Extra grace |
|
||||
|:----:|------|-------------:|-------------------:|:-----------------:|:-----------:|
|
||||
| 0 | Undefended | - | 0 | 10% | +0s |
|
||||
| 1 | Firewall | 5,000 | 500 | 10% | +15s |
|
||||
| 2 | WAF | 40,000 | 2,500 | 8% | +30s |
|
||||
| 3 | SOC Monitoring | 300,000 | 15,000 | 6% | +60s |
|
||||
| 4 | Zero Trust Mesh | 2,000,000 | 100,000 | 4% | +120s |
|
||||
| Tier | Name | Upgrade cost | Daily upkeep (min) | Raid loss reduction | Undefended raider share | Extra grace |
|
||||
|:----:|------|-------------:|-------------------:|:-------------------:|:-----------------------:|:-----------:|
|
||||
| 0 | Undefended | - | 0 | 0% | 50.0% | +0s |
|
||||
| 1 | Firewall | 5,000 | 500 | 5% | 47.5% | +15s |
|
||||
| 2 | WAF | 40,000 | 2,500 | 12% | 44.0% | +30s |
|
||||
| 3 | SOC Monitoring | 300,000 | 15,000 | 20% | 40.0% | +60s |
|
||||
| 4 | Zero Trust Mesh | 2,000,000 | 100,000 | 30% | 35.0% | +120s |
|
||||
|
||||
The payout floor is the minimum fraction of a build's value a raider takes from you (see Raiding
|
||||
above); the Observability Suite replaces any tier floor with 30%. Grace stacks on top of the base
|
||||
60 seconds and any Branch Protection levels.
|
||||
The reduction is multiplicative and stacks with Branch Protection: a Zero Trust Mesh owner with
|
||||
Branch Protection 5 hands over 17.5% instead of 50%. Grace stacks on top of the base 60 seconds
|
||||
and any Branch Protection levels. The Observability Suite caps the raider's share at 20%
|
||||
regardless of tier.
|
||||
|
||||
Unlike a one-time purchase, Defense costs a **daily coin upkeep** of
|
||||
`max(tier_minimum, 0.2% of your coin balance)` - a large balance pays real money, not a flat fee.
|
||||
Upkeep is charged lazily whenever you load your own farm, for at most **2 days** at a time; if
|
||||
your balance cannot cover what is due, your coins go to zero and the tier **decays by one
|
||||
level**. The state reports `defense_level`, `defense_tier_name`, `defense_upkeep_daily` (today's
|
||||
exact charge), and `defense_next_cost`.
|
||||
Upkeep is charged lazily whenever you load your own farm, for every day elapsed since the last
|
||||
charge, so staying away is not cheaper than playing. If your balance cannot cover what is due,
|
||||
**only what you can afford is taken** and the tier decays by one level - your balance is never
|
||||
emptied, and you are notified. You can also leave the commitment deliberately with
|
||||
`POST /game/defense/downgrade` (no refund). The state reports `defense_level`,
|
||||
`defense_tier_name`, `defense_upkeep_daily` (today's exact charge), `defense_next_cost`, and
|
||||
`defense_downgrade_available`.
|
||||
|
||||
### Cosmetics
|
||||
|
||||
@@ -269,7 +287,7 @@ and `active_title` is your equipped title key.
|
||||
## Mastery (beyond prestige)
|
||||
|
||||
Refactoring past **prestige 50** starts earning a second currency: one Mastery point the moment
|
||||
you cross 50, then one more every 10 further prestige (`total earned = 1 + (prestige - 50) / 10`,
|
||||
you cross 50, then one more every 5 further prestige (`total earned = 1 + (prestige - 50) / 5`,
|
||||
rounded down). Points never expire, and crop unlocks check points **ever earned**
|
||||
(`mastery_points_earned_total`), so spending never re-locks content. Spend points with
|
||||
`POST /game/mastery` on three permanent upgrades:
|
||||
@@ -287,9 +305,10 @@ Each has a single level. The state reports `mastery_points` (spendable),
|
||||
|
||||
With Legacy Contracts owned, one **weekly contract** appears in your `quests` list with
|
||||
`scope: "weekly"` - a larger goal of the same four kinds, deterministic per user and ISO week.
|
||||
Claiming it (`POST /game/quests/claim` with the contract's `quest` kind and `scope=weekly`) pays
|
||||
**Stars** (`reward_stars`) plus experience, and grants a **+20% harvest-coin boost for 48
|
||||
hours**.
|
||||
A coin-denominated contract scales its goal with your own earning power, so it stays a week's work
|
||||
at every prestige. Claiming it (`POST /game/quests/claim` with the contract's `quest` kind and
|
||||
`scope=weekly`) pays a fixed **3 Stars** (5 for a coin contract) plus experience, and grants a
|
||||
**+20% harvest-coin boost for 48 hours**, shown as `contract_boost_seconds_remaining`.
|
||||
|
||||
## Refactor (prestige)
|
||||
|
||||
@@ -320,8 +339,10 @@ upgrades, Infrastructure, Defense, cosmetics, lifetime stats, and your Era count
|
||||
|
||||
Every refactor fee flows into a shared **community treasury**. Once per ISO week, an active farm
|
||||
that is still building up - at least **5 harvests this week**, fewer than **10,000 coins**, and
|
||||
at most **prestige 5** - can claim a grant of up to **2,500 coins** (capped by the treasury
|
||||
balance) with `POST /game/grant`. The state reports `grant_available`, `grant_amount`,
|
||||
at most **prestige 5** - can claim a grant with `POST /game/grant`. The treasury is **shared
|
||||
out between everyone currently eligible** rather than paid first-come-first-served: the amount is
|
||||
`treasury_balance / eligible_farms`, capped at **2,500 coins** and suppressed entirely below a
|
||||
**250 coin** minimum so nobody claims dust. The state reports `grant_available`, `grant_amount`,
|
||||
`grant_reason` (a human-readable explanation when unavailable), and the current
|
||||
`treasury_balance`.
|
||||
|
||||
@@ -335,9 +356,9 @@ of level `n+1` is `round(base * growth^n)` Stars. There are six:
|
||||
| 🤖 CI Bot | `autoharvest` | Auto-collect ready builds whenever you load your farm | 1 | 3 | - |
|
||||
| 💎 Tech Debt Payoff | `multiplier` | +10% harvest coins per level, stacks with refactor | 10 | 1 | 1.6x |
|
||||
| 🏎️ Bare-Metal | `speed` | +5% base build speed per level | 8 | 1 | 1.7x |
|
||||
| 🗂️ Monorepo | `plots` | +1 starting plot after each refactor per level | 4 | 3 | 2.0x |
|
||||
| 🗂️ Monorepo | `plots` | +1 starting plot after each refactor per level | 8 | 3 | 2.0x |
|
||||
| 🛡️ Branch Protection | `defense` | +30s steal grace and -5% steal loss per level | 5 | 2 | 1.8x |
|
||||
| 🪂 Golden Parachute | `carryover` | +5% refactor coin carry-over per level | 5 | 2 | 1.8x |
|
||||
| 🪂 Golden Parachute | `carryover` | +5% refactor coin carry-over per level | 10 | 2 | 1.8x |
|
||||
|
||||
The live state reports your `stars` balance and each legacy upgrade's current level and the exact
|
||||
Star cost of its next level.
|
||||
@@ -345,13 +366,15 @@ Star cost of its next level.
|
||||
## Leaderboards and scoring
|
||||
|
||||
The default leaderboard ranks the top 25 farms by a composite score. Refactors dominate the
|
||||
formula, then lifetime harvests, level, and everything else:
|
||||
formula, then lifetime harvests, level, and everything else. The coin term is **capped**, so the
|
||||
board measures what you have built rather than what you are sitting on, and refactoring - which
|
||||
spends your balance - never costs you rank:
|
||||
|
||||
```
|
||||
score = xp
|
||||
+ prestige * 5000
|
||||
+ total_harvests * 10
|
||||
+ coins / 20
|
||||
+ min(coins / 20, 100000)
|
||||
+ (ci_tier - 1) * 250
|
||||
+ (plots - 4) * 200
|
||||
+ total_perk_levels * 120
|
||||
@@ -421,6 +444,7 @@ your **API key** in an `X-API-KEY` header (or `Authorization: Bearer`). Your key
|
||||
| `POST` | `/game/mastery` | Buy a Mastery upgrade (`key`) with Mastery points. |
|
||||
| `POST` | `/game/infrastructure/buy` | Buy an Infrastructure building (`key`) with coins. |
|
||||
| `POST` | `/game/defense/upgrade` | Buy the next Defense tier with coins. |
|
||||
| `POST` | `/game/defense/downgrade` | Drop one Defense tier to escape its upkeep (no refund). |
|
||||
| `POST` | `/game/cosmetics/buy` | Buy a cosmetic (`key`) with coins. |
|
||||
| `POST` | `/game/cosmetics/equip` | Equip an owned title cosmetic (`key`). |
|
||||
| `POST` | `/game/farm/{username}/water` | Water a neighbour's build in `slot`. |
|
||||
@@ -499,7 +523,9 @@ lists you act on. A plot looks like this:
|
||||
"steal_cooldown_seconds": 0,
|
||||
"steal_reason": "",
|
||||
"is_golden": false,
|
||||
"fertilize_cost": 22
|
||||
"fertilize_cost": 22,
|
||||
"raided_fraction": 0.0,
|
||||
"raided_pct": 0
|
||||
}
|
||||
```
|
||||
|
||||
@@ -534,18 +560,25 @@ next `cost`, and a `maxed` flag where applicable.
|
||||
**Grant and treasury** *(owner)*: `grant_available`, `grant_amount`, `grant_reason`,
|
||||
`treasury_balance`.
|
||||
|
||||
**Daily:** `streak`, `daily_available` *(owner)*, `daily_reward`.
|
||||
**Daily:** `streak`, `daily_available` *(owner)*, `daily_streak_reset` (true when your streak
|
||||
lapsed, so `daily_reward` already reflects the reset value), `daily_reward`.
|
||||
|
||||
**Raiding:** `steal_cooldown_seconds` (your remaining cooldown against this farm's owner; 0 on
|
||||
your own farm).
|
||||
your own farm), `steal_max_per_victim_per_day` (how many raids any single farm can absorb per
|
||||
day).
|
||||
|
||||
**Mastery and lifetime stats:** `mastery_points`, `mastery_points_earned_total`,
|
||||
`mastery_analytics_unlocked`, `lifetime_coins_earned`, `lifetime_harvests`, `harvests_week`.
|
||||
|
||||
**Defense:** `defense_level`, `defense_tier_name`, `defense_upkeep_daily`, `defense_next_cost`
|
||||
(0 at the top tier).
|
||||
(0 at the top tier), `defense_downgrade_available` *(owner)*.
|
||||
|
||||
**Cosmetics and boosts:** `active_title`, `underdog_boost_seconds_remaining`.
|
||||
**Cosmetics and boosts:** `active_title`, `underdog_boost_seconds_remaining`,
|
||||
`contract_boost_seconds_remaining`.
|
||||
|
||||
**Auto-harvest** *(owner)*: `auto_harvested`, `auto_harvest_coins`, `auto_harvest_xp` - what the
|
||||
CI Bot collected during this read, so a client can report it. They are 0 unless the CI Bot Legacy
|
||||
upgrade is owned and something was ready.
|
||||
|
||||
**Era:** `era_active`, `era_name`, `era_coins`, `era_harvests`.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user