commit 26e7bfcd12a3c1ae6e6cb2eadc38c86f9024968a
parent d4f613f6ade51ac7a271a7effa262bdddafc6055
Author: anon <anon@example.com>
Date: Wed, 28 Oct 2026 05:23:22 +0000
Verify earned levels unlock mission reward equipment
Diffstat:
5 files changed, 217 insertions(+), 5 deletions(-)
diff --git a/TODO.md b/TODO.md
@@ -68,10 +68,13 @@ Conditional completion token/XP, obstacle routing and historical population/rewa
generation remain open.
An ordinarily created Enforcer has now funded a request with corpse cash, entered
the fixed mission, collected and returned its exact book, and retained the earned
-cash/glove across rejected wear, reconnect and cold restart. The QL2 reward needs
-Agility 11; this level-1 Atrox has 9. The basic shop's original backyard exit also
-requires level 2 or 1000 credits. Those requirements and the remaining equipment
-purchase budget keep the ordinary upgrade gate open. See
+cash/glove across rejected wear, reconnect and cold restart. The same character
+then earned level 2 through fifteen full-health kills, spent 38 earned IP to
+train Agility 9->11, and wore/removed/re-wore that exact QL2 reward. Native armor
+effects and all ten owned items survived another cold restart. The character
+now meets the backyard-to-city level requirement. Earning the remaining
+equipment budget, selling loot and completing the ordinary shop purchase remain
+open. See
[earned fixed-mission reward](docs/starter-progression.md#earned-fixed-mission-reward).
After fixing an inactive-mesh projectile that blocked repeated native casts,
a fresh Atrox Nano-Technician completed fifteen ordinary Leet kills without
@@ -644,7 +647,10 @@ for exact records, protocol, tests and remaining reconstruction assumptions.
Repeat normal creation, skill choices, issued equipment, several fights,
recovery and the first level using shared combat/resource rules. Retain the
failed Solitus Enforcer attempts and the Atrox Enforcer's thirteen-kill run
- that exhausted 25 laboratories before leveling. Resolve health First Aid,
+ that exhausted 25 laboratories before leveling. A later Atrox Enforcer run
+ reached level 2 in fifteen kills and wore its earned mission reward; it does
+ not erase the earlier deaths or establish reliable historical balance.
+ Resolve health First Aid,
defenses, initial skills and provisional enemy balance from evidence before
changing balance. The shipped training playfields contain no reclaim placement;
these failures do not establish a new training reclaim terminal.
@@ -1642,6 +1648,16 @@ client rendering fixes and checks are in [nano damage](docs/nano-damage.md).
contract, not conditional XP/token, generated rewards or the remaining funded
equipment purchase/equip gate. See
[ordinary mission reward](docs/starter-progression.md#earned-fixed-mission-reward).
+- [x] Verify an earned mission reward becomes wearable through earned level/IP.
+ The ordinarily created Enforcer's fifteen full-health fights earn level 2
+ and 4000 IP without grants or changed enemies. Agility remains 9, and native
+ reward wear still rejects without losing the item. Normal 38-IP training to
+ 11 permits wear/remove/re-wear of that same QL2 instance, with the expected
+ armor effects and exact ownership retained across cold restarts. A separate
+ creation-to-level public-handler regression starts at zero XP, uses full-health
+ replacement lives and recovery ticks, and checks each earned level/IP state
+ on a cold load. Its controlled rolls do not establish canonical balance. See
+ [earned level and wear](docs/starter-progression.md#earned-level-and-mission-reward-wear).
- [x] Advertise and atomically grant a selected-quality mission item reward.
RewardBox's original ACG list retains both endpoints and QL; acceptance stores
that promise independently of YAML/level changes. Completion consumes the
diff --git a/docs/combat-healing-delivery.md b/docs/combat-healing-delivery.md
@@ -178,3 +178,11 @@ impact and authoritative HP resolution as one event. They do not justify a
fixed reconciliation delay or a change to native queues. Original-server
publication and healing ordering remain unresolved. Complete retained-source
records and scope are in `local/heal-timing-followup/publish/README.md`.
+
+The Funcom/Simula paper
+[Network Traffic from Anarchy Online](https://web-backend.simula.no/sites/default/files/publications/Simula.simula.1162.pdf)
+describes a public server-side capture, but its trace section explicitly says
+that only packet headers were recorded. It retains network timing while
+excluding game payloads and player locations. That corpus cannot supply the
+missing correlated healing/AttackInfo bodies, even if its download remains
+available; no protocol or healing rule follows from its traffic statistics.
diff --git a/docs/ip-training.md b/docs/ip-training.md
@@ -144,6 +144,21 @@ earned-reward race run passes 16 top-level tests and 73 results. `go vet
cold restart retain the accepted raw skill, IP and exact owned items; see the
[issued buff and training run](starter-progression.md#issued-buff-and-durable-training).
+`server/starter_level_test.go` additionally begins with ordinary HTTP character
+creation, zero XP and the actual seven issued items. Public training spends
+110 IP on Agility, Stamina and Body Development, without refilling current HP;
+the issued bat is equipped normally. Fifteen full-health Leets, their ordinary
+replacement lives and intervening seated recovery ticks earn level 2 and 4000
+IP. Corpse expiry cannot erase that earned progression. Agility 11 is rejected
+before leveling and then costs 38 IP; every kill and the final training retain
+their state and exact issued-item ownership on a cold load. No XP, resources
+or enemy health are reset. The fixture arranges one nearby spawn and controls
+damage/drop rolls, so it checks connected server progression rather than
+random survival balance or native travel.
+It passes normally and with the two earned-reward/failure regressions under
+`-race` (3 top-level tests, 10 results); records are retained in
+`local/earned-armor/starter-level-test-verification.json`.
+
## Verification
`client/tests/ip_training.c` executes the unchanged lifted implementations
diff --git a/docs/starter-progression.md b/docs/starter-progression.md
@@ -429,3 +429,45 @@ three unused First Aid charges are accounted for in
`local/earned-armor/hunt-verification.json`. This further exposes the sustained
recovery cost; missing health stims and hit/evade rules remain open, and no
provisional enemy balance was changed to complete the run.
+
+### Earned level and mission-reward wear
+
+The same normally created Enforcer continued to fifteen full-health level-1
+Leet kills without a death, using its issued bat and shirt. Every fight began
+at 84 HP against 100 HP. After exhausting its laboratories, normal seated
+recovery restored health between fights. The fifteenth kill crossed the
+1450-XP threshold: native cumulative XP became 1500, current-level progress 50,
+and IP rose from 1177 to 5177. Maximum HP rose to 91 while current HP remained
+25; maximum nano rose to 24 while current nano remained 22. These encounters
+use the existing provisional enemy balance and XP reward, without admin edits.
+
+Collected corpse cash and the completed mission leave 59 credits. Four exact
+Monster Parts, instances 27/29/30/31, remain owned. The seventh corpse's untaken
+part expired normally and is excluded. The empty laboratory, uploaded crystal,
+returned book and revoked mission key remain consumed. An out-of-range attack
+attempt before the tenth kill left player/target HP and XP unchanged across
+407 samples; moving closer then allowed the ordinary fight.
+
+Level 2 did not automatically raise Agility. Native wear still rejected the
+earned QL2 glove (26) at Agility 9, explaining the requirement of 11 and retaining
+the item. A cold restart retained the earned level, IP and all ten owned items.
+Two native skill-arrow taps and ACCEPT then trained Agility 9->11 for exactly
+38 IP, leaving 5139. The single captured SkillIIR contains all 75 raw fields;
+every unrelated trained skill remains unchanged.
+
+Normal right-click wear moved that same glove from inventory slot 67 to hands
+slot 24. Native melee AC rose from the issued shirt's 10 to 12; AC90..97 became
+`2/12/2/2/1/1/1/1`. Wear/Clothes shows its glove icon. Removal returned instance
+26 to slot 67 and restored the shirt-only protection. Re-wear restored all eight
+glove contributions. A second cold server/client restart retained the worn
+instance, abilities, IP, XP, credits and all unrelated item identities/counts.
+The learned Thug's Delight program remains; its timed buff expired normally.
+
+The assertion-based native records are
+`local/earned-armor/first-level-native-verification.json` and
+`earned-wear-verification.json`, with packet captures, screenshots and frozen
+SQLite snapshots alongside them. There were no page exceptions or adapter
+aborts. The separate creation-to-level server regression uses controlled rolls
+and is described in [IP training](ip-training.md#training-earned-rewards-and-persistence-failures).
+Owned test browsers are closed, with one preview on the default ports retained.
+Earned loot sales and the funded equipment-purchase gate remain open.
diff --git a/server/starter_level_test.go b/server/starter_level_test.go
@@ -0,0 +1,131 @@
+package main
+
+import (
+ "encoding/binary"
+ "net/http"
+ "slices"
+ "testing"
+ "time"
+)
+
+func TestCreatedEnforcerEarnsFirstAbilityCapWithoutSeededExperience(t *testing.T) {
+ // Keep one admitted full-health Leet beside the ordinary creation position.
+ data := testNPCData()
+ group := &data.Playfields[0].Districts[0].Groups[0]
+ group.Levels, group.AppearanceStatus = [2]uint16{1, 1}, "inferred_species"
+ group.Positions = [][3]float32{{54.5, 14.75, 58}}
+ originalResources := resources
+ useNPCData(t, data)
+ resources = originalResources
+ world := newTestServer(t)
+ fields := creationForm()
+ fields.Set("head_mesh", "40132")
+ fields.Set("profession", "9")
+ if response := creationRequest(world, accountVisitor(t, world), fields); response.Code != http.StatusNoContent {
+ t.Fatal(response.Code, response.Body.String())
+ }
+ player := world.characters[2]
+ client := &worldClient{id: 2, conn: &combatTestConn{}, target: true, ready: true, npcs: map[uint32]bool{1000000: true}}
+ world.clients[2] = client
+ items := slices.Clone(player.inventory.Items)
+ if player.level != 1 || player.experience != 0 || player.inventory.Credits != 0 || player.stats.ImprovementPoints != 1500 || len(items) != 7 {
+ t.Fatal("ordinary creation did not start with zero earned progression", player.profile(), player.inventory)
+ }
+
+ trained := player.baseStats()
+ trained.Abilities.Agility, trained.Abilities.Stamina, trained.Body.BodyDevelopment = 9, 13, 10
+ request := skillTrainingRequest(trained)
+ binary.BigEndian.PutUint32(request[28:32], player.id)
+ if err := world.handleSkillTraining(client, request[20:]); err != nil {
+ t.Fatal(err)
+ }
+ if err := world.handleInventory(client, inventoryMovePacket(2, 67, 6)[20:]); err != nil || client.equipment == nil {
+ t.Fatal("issued bat did not begin equipping", err)
+ }
+ world.advanceEquipment(client.equipment.readyAt)
+ items[3].Slot = 6
+ trained = player.baseStats()
+ trained.Abilities.Agility = 11
+ request = skillTrainingRequest(trained)
+ binary.BigEndian.PutUint32(request[28:32], player.id)
+ if err := world.handleSkillTraining(client, request[20:]); err != nil {
+ t.Fatal(err)
+ }
+
+ if player.stats.ImprovementPoints != 1390 || player.stats.Abilities.Agility != 9 || player.maximumHealth() != 84 || player.health != 60 ||
+ !slices.Equal(player.inventory.Items, items) {
+ t.Fatal("training/equipping granted health, bypassed the level cap or changed issued items", player.stats, player.health, player.inventory)
+ }
+
+ // Controlled endpoint rolls isolate progression, rather than random survival balance.
+ world.combatRoll = func(limit uint32) uint32 {
+ if limit == 100 {
+ return 99
+ }
+ if limit == 4 {
+ return 3
+ }
+ return 0
+ }
+ now := time.Now().Add(time.Second)
+ client.regenerationAt = now
+ npc := world.characters[1000000]
+
+ for index, experience := range []uint32{100, 200, 300, 400, 500, 600, 700, 800, 900, 1000, 1100, 1200, 1300, 1400, 50} {
+ // Advance real recovery ticks; never refill resources or reset an enemy's HP.
+ if err := world.handlePosture(client, characterActionPacket(2, [5]uint32{86})[20:]); err != nil {
+ t.Fatal(err)
+ }
+ for ticks := 0; ticks < 500 && (player.health < player.maximumHealth() || len(world.npcRespawns) != 0); ticks++ {
+ now = now.Add(2 * time.Second)
+ world.advanceRegeneration(now)
+ world.advanceNPCRespawns(now)
+ }
+ if index != 0 {
+ world.advanceCorpseExpiry(now)
+ npc = world.characters[world.nextNPC-1]
+ }
+ if player.health != 84 || npc == nil || npc.health != 100 || npc.corpse != nil {
+ t.Fatal("ordinary recovery/respawn did not prepare a full-health encounter", index, player.health, npc)
+ }
+ if err := world.handlePosture(client, characterActionPacket(2, [5]uint32{87})[20:]); err != nil {
+ t.Fatal(err)
+ }
+ if err := world.handleCombat(client, attackPacket(2, npc.id)[20:]); err != nil {
+ t.Fatal(err)
+ }
+ for ticks := 0; ticks < 1200 && player.health != 0 && npc.health != 0; ticks++ {
+ now = now.Add(100 * time.Millisecond)
+ world.advanceCombat(now)
+ world.advanceRegeneration(now)
+ }
+ cold := newTestInventoryServer(t).characters[2]
+
+ level, points := uint16(1), uint32(1390)
+ if index == 14 {
+ level, points = 2, 5390
+ }
+ if player.health == 0 || npc.health != 0 || npc.corpse == nil || npc.corpse.looter != 2 ||
+ player.level != level || player.experience != experience || player.stats.ImprovementPoints != points ||
+ cold.level != level || cold.experience != experience || cold.stats != player.stats ||
+ !slices.Equal(player.inventory.Items, items) || !slices.Equal(cold.inventory.Items, items) ||
+ player.inventory.Credits != 0 || cold.inventory.Credits != 0 {
+ t.Fatal("full encounter changed the earned level, IP or issued ownership", index, player.health, npc.health, player.profile(), cold.profile())
+ }
+ }
+
+ trained = player.baseStats()
+ trained.Abilities.Agility = 11
+ request = skillTrainingRequest(trained)
+ binary.BigEndian.PutUint32(request[28:32], player.id)
+ if err := world.handleSkillTraining(client, request[20:]); err != nil {
+ t.Fatal(err)
+ }
+ cold := newTestInventoryServer(t).characters[2]
+
+ if player.level != 2 || player.experience != 50 || player.stats.Abilities.Agility != 11 || player.stats.ImprovementPoints != 5352 ||
+ player.maximumHealth() != 91 || cold.stats != player.stats || cold.level != 2 || cold.experience != 50 ||
+ !slices.Equal(player.inventory.Items, items) || !slices.Equal(cold.inventory.Items, items) {
+ t.Fatal("earned cap training changed its price, level or original item identities", player.profile(), cold.profile())
+ }
+}