Commit Graph
70 Commits
Author SHA1 Message Date
shenleiandClaude Opus 5.5 30ea96f418 Allocate item cells for PCs only
CHARACTER_POINT_INSTANT carried the inventory/equipment, dragon soul and
special storage cells (~13 KB) in every CHARACTER, mobs and NPCs included.
They now live in CHARACTER_ITEM_CELLS, allocated in Create(isPC) and freed
in Destroy(); non-PCs read a shared empty set. On channel1/game2's maps a
core drops from 522/442 MB VSZ/RSS to 177/159 MB (live 275c7e52: 341/301).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 22:08:16 +09:00
shenleiandClaude Opus 5.5 96f8486306 Five character slots (AVA2 ENABLE_PLAYER_PER_ACCOUNT5)
PLAYER_PER_ACCOUNT 5: player_index.pid5 in the login/empire/monarch
queries, char_change_empire sized by PLAYER_PER_ACCOUNT, slot check
relaxed; client gate mt20261029. tools/player-slots5 adds pid5.

tools/player-deleted-sync: PLAYER_DELETE copies with SELECT *, so
player_deleted must match player column for column; the conqueror
schema now adds its columns to player_deleted too.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 20:33:51 +09:00
shenleiandClaude Opus 5.5 31ebae050b server: AVA2 conqueror level (ENABLE_CONQUEROR_LEVEL)
- Conqueror level/exp/step/points and the four sungma stats on the player
  (db load/save, simple player, actor add/update packets), POINT_CONQUEROR_*.
- Conqueror maps 129-132 give conqueror exp instead of exp; per-map sungma
  requirements from map/<name>/sungma_attr.txt, sent as GC_SUNGMA_ATTR_UPDATE,
  with the AVA2 damage/defence penalties when below them.
- /conqueror_stat, pc.set_conqueror_level / pc.get_conqueror_level, 9th skills
  176-183 (+ Cheonun affects); DAMAGE_BLOCK is spelled (1 << 3) in char_battle.
- tools/conqueror: schema, skill_proto rows, sungma_attr maps, the
  conqueror_unlock quest (lv 120 login/levelup) and install.sh.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 20:06:32 +09:00
shenleiandClaude Opus 5.5 794ac41a41 server: AVA2 wolfman character (ENABLE_WOLFMAN_CHARACTER)
Race 8 / JOB_WOLFMAN with claw weapons, skills 170-175 (split slash,
wind death, reef attack, wreckage, red/blue possession), bleeding affect,
ANTI_WOLFMAN item flag and the wolfman apply types. Mob bleeding maps to
poison and claw resist to dagger (USE_MOB_BLEEDING_AS_POISON /
USE_MOB_CLAW_AS_DAGGER) so mob_proto keeps its layout. No packet layout
change. Tested on sbtest channel5 (game.wolfman-20261024).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 16:32:48 +09:00
shenleiandClaude Opus 5.5 103805998c game: port AVA2 Won (cheque) currency
Won point (quest flag cheque.points, max 999), /won_exchange sell|buy N at
100,000,000 Yang per Won, Won in trades and private shop prices (int32
cheque[] after the CG_MYSHOP items for clients >= mt20261027). The Won
point is sent again at Entergame because the quest-load update arrives
before PHASE_GAME.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 15:30:38 +09:00
shenleiandClaude Opus 5.5 f5b8424266 game: make special storage cells reachable through GetItem
CHARACTER::IsValidItemPosition had no case for windows 8-12, so GetItem
returned NULL for every special storage cell. ClearItem never freed those
items on logout; the next login of the same character failed with
ITEM_ID_DUP and the items went missing (dangling owner pointer). The
MoveItem routing for these windows was unreachable for the same reason.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 15:30:38 +09:00
shenleiandClaude Opus 5.5 3058ad6002 game: port AVA2 cube renewal (HEADER_CG/GC_CUBE_RENEWAL 216/221)
Cube_open hands mt>=20261026 clients the AVA2 cuberenewal window: the
recipes of the clicked NPC from the loaded cube.txt, sent as GC 221
CLEAR/DATES/LOADING/OPEN; CG 216 MAKE_ITEM/CLOSE does the craft.
Unlike AVA2 the reward scales with successes, count is bounded to one
stack (<=200), the free cell is checked before anything is consumed,
materials are taken from inventory + special storages (never equipped,
locked, traded or shop items) and gold is int64. Older clients keep the
classic "cube open" window; the DB-transactional cube stays disabled.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-24 14:06:25 +09:00
shenandshen b5e06c9a43 feat: implement CH5 cube renewal, SQL fence routing, and transactional crafting 2026-10-23 20:17:22 -07:00
shenandshen 6924dc9b49 Merge remote-tracking branch 'origin/feature/ava2-unlock' into feature/ava2-unlock 2026-10-23 06:35:00 -07:00
shenleiandClaude Opus 5.5 aa0afefe86 game: instantiate COfflineShopManager under ENABLE_OFFLINESHOP_SYSTEM
Without the singleton, channel boot segfaults in CInputDB::Boot ->
LoadSearchLanguage. Verified on the sbtest cluster.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 21:12:09 +09:00
shenandshen e8ace59fcd feat: add quiver ammunition rules and negotiated state sync 2026-10-22 17:41:48 -07:00
shenandshen 5b7442ea37 feat(server): save economy hardening and CH5 continuation work 2026-10-22 06:22:23 -07:00
shenandshen c979b53762 feat: implement 64-bit gold system across server, DB, exchange, safebox, and guild (Stage 7) 2026-10-20 05:57:25 -07:00
shenandshen a7152750fb feat: complete Stage 6 item shop, durable point queue, Gaya market, and alchemy parity
- Implement durable point drop intent journal on disk with fsync before network send
- Fix DB point settlement day by fixing CURDATE() on initial account row lock within transaction
- Implement Gaya market subsystem (port_gaya.cpp/h, 27 slots, 55 items, filesystem persistence, /gem command)
- Add POINT_GEM (248) to CHARACTER and support 39063 / 39064 right-click usage
- Fix treasure key (77921~77923) and box (77918~77920) stack decrement in char_item.cpp
- Verify Dragon Soul recharge items 100001 / 100002 and holly bean 100500 DoRefineStrength
- Add 8 verified products (144, 145, 149, 233, 234, 240, 241, 242) to verified-products.json (count: 57)
- Add comprehensive test suites for durable queue, Gaya market, key stacks, and dragon soul alchemy
2026-10-20 04:53:49 -07:00
shenandshen d1c1572ddb feat: implement offline shop and shop search systems (Stage 5 Part 2)
- Enable ENABLE_OFFLINESHOP_SYSTEM and ENABLE_SHOP_SEARCH_SYSTEM in service.h
- Define OFFLINE_SHOP_HOST_ITEM_MAX_NUM (80) and SHOP_SIGN_MAX_LEN (45) in length.h
- Add CG57, CG58, CG143, GC47, GC48, GC156 packet definitions and subheaders
- Port offline shop, shop manager, search manager, and DB client manager
- Auto-bootstrap offline shop SQL tables and player.shop_money/shopFlag columns
- Add 72319 item consumption for shop slot expansion (bPos 40..79)
- Add comprehensive feature tests in test_offlineshop.py
2026-10-20 03:38:28 -07:00
shenandshen 792d4d50b3 feat: implement special storage windows 8-12 and 72320 inventory unlock 2026-10-20 02:38:21 -07:00
shenandshen 0b995c480d feat: add 6th and 7th rare attribute system, skills 176-182, and tests 2026-10-20 01:46:07 -07:00
shenandshen 85b831db91 feat: add active branch pet system, lifecycle management, and commands 2026-10-20 00:50:06 -07:00
shenandshen d63781e5fd feat: implement costume weapon, sash skin, shining slots and enchants 2026-10-19 23:58:56 -07:00
shenandshen f8bb455d9f feat: add 64-bit gold points sync and overflow guards 2026-10-19 23:23:44 -07:00
shenandshen 65db9fc365 feat: add account point rewards and extended item storage
Implement configurable kill rewards with account-wide daily limits, transactional deduplication, and game-to-db retries. Add the approved wide rules and tested isolation tooling.

Stage wear40 equipment and persistent extra item metadata with an explicit migration plan and client revision gate. Track all 168 remaining offers; sixteen have staged data/assets, while live acceptance and other systems remain incomplete. This commit is not a production deployment.
2026-10-19 18:30:19 -07:00
shenandshen 275c7e5211 Deploy verified native itemshop to production with economic backups 2026-10-19 16:59:31 -07:00
shenandshen 32831010c0 Port native AVA2 itemshop with transactional purchases and verified catalogue 2026-10-19 07:08:51 -07:00
shenandshen abda2c1cda feat: serve native AVA2 battle pass, drop finder and event calendar 2026-10-18 23:35:29 -07:00
shenandshen 2016f20d58 Synchronize owner attribute locks for links and active switchbot 2026-10-18 22:08:48 -07:00
shenandshen ec60c38492 docs: record isolated attr lock view validation and cleanup 2026-10-18 21:37:48 -07:00
shenandshen 5b8cc3069f feat: add read-only attr lock views for exchange, shop, safebox and inspect 2026-10-18 18:21:59 -07:00
shenandshen bce34954d9 feat: add AVA2 native channel warp with peer map routes 2026-10-18 17:05:17 -07:00
shenandshen 71c299c98f Record verified switchbot handover between isolated cores 2026-10-18 16:43:51 -07:00
shenandshen 2048808c75 Add safe AVA2 lock material selection and tooltip query 2026-10-18 16:28:16 -07:00
shenandshen ff6163a685 Add AVA2 boss scheduler, dungeon tracking and ticket shop 2026-10-18 10:41:51 -07:00
shenandshen 0b9c2bb6b0 feat: port AVA2 batch chests and CG235 pickup to test server 2026-10-18 04:04:38 -07:00
shenandshen ac4a05a0c3 fix: align spirit stone insertion and stack consumption with AVA2 2026-10-17 23:32:59 -07:00
shenandshen d7d0de3ae9 test: reject attack speed when switchbot requests cast speed 2026-10-17 17:01:05 -07:00
shenandshen b625ba5695 fix: allow auto hunt gather commands during combat 2026-10-17 16:40:11 -07:00
shenleiandClaude Opus 5.5 e097b927de Skill power: bounds-check skill group/level (party crash), level 120 test results
A player row with skill_group 50 made CParty::ComputeRolePoint index past
m_aiSkillPowerByLevelFromType and crash the core once the character was in a party.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 12:17:59 +09:00
shenleiandClaude Opus 5.5 c9268424ab Level 120: QUEST_INFO size fix, boss melee range 800 (hydra)
- questpc.cpp: SendQuestInfoPakcet built the optional fields after sending the
  header, so qi.size was short and the client parsed the rest as a new packet.
- battle.cpp: a non-PC victim of rank BOSS or higher allows 800 melee distance.
  The ship-defence hydra 6812 sits on the water ~620 from the deck, and the old
  300 (AVA2: 600) dropped every hit as VICTIM_FAR.
- docs: snow / ship / party run status.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 11:09:32 +09:00
shenleiandClaude Opus 5.5 3c0141d639 Level 120 (L1-L5): exp curve, AVA2 maps/drops, AVA2 dungeon quest support
- L1: level cap 120 with the AVA2 exp curve, 64-bit exp sums, unsigned exp
  column; level-difference exp/drop floors kept as before.
- L2/L3/L5: AVA2 maps and their mob drops (data side in the client repo's
  tools/server/ava2-maps).
- L4: quest functions the AVA2 snow / ship defence / Meley quests call
  (port_ava2_dungeon.cpp), QUEST_ATTACK_EVENT (<vnum>.attack), Meley and
  hydra HP helpers. A hit never takes a dragon statue (6230) below 1 HP so
  only npc.dead_by_vnum kills it (AVA2 could leave the lair stuck).
- docs/FEATURE-LEVEL-120.md: plan and sbtest test record (Meley full run
  passed: 9 floors + chest + exit warp, 837 s).

Only installed on sbtest; not deployed live.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 08:13:32 +09:00
shenleiandClaude Opus 5.5 3222614dd2 Switchbot docs: record live test results on channel5 and sbtest
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 23:03:07 +09:00
shenleiandClaude Opus 5.5 972c200cd0 Switchbot gate: find the mt<date> mark anywhere in the client timestamp
Every locale.cfg client build is LOCALE_SERVICE_EUROPE and sends
CG_CLIENT_VERSION2, and 203 compares that timestamp with atoi against
1215955205. The client now sends "1215955205 mt20261016", so the gate
looks for "mt" instead of requiring it at the start. Found on channel5.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 20:35:08 +09:00
shenleiandClaude Opus 5.5 a28393b16b Port the AVA2 switchbot (自动洗练) 1:1
AVA2 new_switchbot ported as port_switchbot.{h,cpp}: SWITCHBOT item window (7),
CG/GC 171 and GG 31 with AVA2 subheaders and field order, pack(1) structs pinned
by static_assert, 0.1 s roll, P2P hand-over on warp, boot ALTER of
player.item.window. Switchers come from the inventory; current checks and
ItemLog are kept. Clients sending "mt20261016" or newer as the version
timestamp get the switchbot; older clients are left alone.

The v1 /mt_switchbot chat command, its lock verb and query capability bit 64
are removed (cap mask 1023 -> 959).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 20:26:06 +09:00
shenleiandClaude Opus 5.5 c6813cd653 Merge main into feature/ava2-unlock
Conflicts resolved by keeping both sides: AVA2 attribute lock materials
(50348/50349) and battle pass tickets from main alongside the unlock
branch's costume enchants, talismans and new rings.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 18:14:39 +09:00
shenandshen 22228857ff feat: port AVA2 travel/teleport, attribute lock materials, and battlepass ticket activation 2026-10-16 01:29:43 -07:00
shenleiandClaude Opus 5.5 e313d9ea85 AVA2 unlock P8: new rings (ITEM_NEW_RINGS, WEAR_RINGS_1/2)
Rings are socket accessories with AVA2's jewel per family and the
item_attr_rings pool (port_rings.cpp); the 40250 switchers / adders accept
them, the switchbot and rare attributes skip them. New ProtoReader type,
so the db binary changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 14:40:26 +09:00
shenleiandClaude Opus 5.5 f09ffd8a35 AVA2 unlock P7: talismans (ARMOR_PENDANT / WEAR_PENDANT, element enchants)
- ARMOR_PENDANT subtype, WEAR_PENDANT=27, APPLY_ENCHANT_ELEC..DARK (123-128)
  and POINT_ENCHANT_* (242-247); battle.cpp adds the enchant % vs element mobs
- port_pendant.cpp: talisman attribute pool (AVA2 item_attr pendant column),
  71302/53996 reroll and 71301/53997 add (max 5), MTPENDANT client messages
- switchbot skips talisman scrolls; tests for pendant + applies

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 14:28:35 +09:00
shenleiandClaude Opus 5.5 6199b2cbff AVA2 unlock P6: costume enchants (USE_CHANGE_ATTRIBUTE 54001-54267)
Enchant stones add one fixed attribute to an unequipped body / hair /
mount-skin costume (max 3, no duplicates); gear and the switchbot refuse
them. MTCATTR chat commands report the result.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 14:12:30 +09:00
shenleiandClaude Opus 5.5 fb066e7046 AVA2 unlock P5: mount costume and mount skin
COSTUME_MOUNT=2 / COSTUME_MOUNT_SKIN=4, WEAR_COSTUME_MOUNT 25 / _SKIN 26.
port_mount.cpp summons/unsummons the horse on equip, skin overrides the
mount vnum in GetMyHorseVnum; costume subtypes no longer map onto the
armor attribute sets. db ProtoReader learns COSTUME_MOUNT_SKIN.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 14:00:24 +09:00
shenleiandClaude Opus 5.5 c30258ef5e AVA2 unlock P4: sash (COSTUME_SASH, WEAR 24, PART_SASH, CG 211/GC 215, pc.open_sash)
Ports AVA2's sash system into port_sash.cpp: combine and absorb windows,
absorbed bonuses scaled by absorption, and a fifth character equip part.
The character packets grow by one WORD, so old clients break.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 13:44:49 +09:00
shenleiandClaude Opus 5.5 14c4491469 AVA2 unlock P3: document dragon armor
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 11:13:41 +09:00
shenleiandClaude Opus 5.5 5ad07886ea AVA2 unlock P1/P2: stone and Boss bonus apply types
APPLY_ATTBONUS_STONE 139 / APPLY_ATTBONUS_BOSS 140 (AVA2 numbering, 92-138
reserved) in the game and the db proto reader; docs/FEATURE-AVA2-UNLOCK.md.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-16 11:05:16 +09:00