War God of Mountains and Seas

✅ 可玩

山海战神

shzs

🔑 fluffos / Mud@2026 更新 4c44f7f 2026-09-01 源码 下载 ZIP

▶ 开始游玩 · Play Now

不要被"山海战神"这个名字骗了——这并不是传统武侠/仙侠泥巴,而是史巴克(Spock)开发的英文科幻引擎"Final Frontier v0.6e"(`simple`/ES II 引擎系列)二次改造而成的中文版硬科幻"战斗模拟"游戏:人物属性叫力量/敏捷/智力/注意/体质/技术,护甲分传统、动能、光学、粒子、爆破五种类型,攻击方式带着浓厚的机甲/激光对抗色彩,是这批归档里题材最"硬科幻"的一个。整体规模不大,更像是一个演示引擎战斗系统的小型试验场,而非内容丰富的大型世界。

English

A Chinese-language adaptation of Spock's English-language science-fiction engine "Final Frontier v0.6e," part of the simple/ES II engine family. Despite the wuxia-sounding name, it's not a martial-arts MUD but a hard-sci-fi combat simulator, with stats like Strength, Agility, and Technique and mecha- and laser-flavored battles.

README

在线试玩

https://mudlibs.fluffos.info/shzs/

管理员账号 / Admin account

警告:对外公开架设前请务必修改此密码。

本地运行

cd libs/shzs
~/src/fluffos/build-debug/src/driver config.fluffos

游戏端口:40001

NOTES · 移植与修复记录

山海战神.rar → shzs

Status: DONE — boots clean, playable over telnet

Login banner, Chinese prompts, and character-creation flow all render correctly. This lib was the pilot used to build scripts/convert_lib.sh and the fix catalog in AGENTS.md — see that file's "Common driver-compatibility issues" catalog (§1-§14) for the general write-up of every issue found here. Lib-specific specifics only, below.

What was fixed

1. Encoding: all .c/.h files GB18030→UTF-8 (774 converted, 124 already ASCII/UTF-8, 0 hard failures). Also converted data/*.o save files (dict/emote/daemon/ballot_box/stars — these are plain-text save_object() format, not binary) — data/emoted.o needed the lossy -c fallback (one stray invalid byte at position 25324, pre-existing data corruption in the original archive, unrelated to us). Also adm/etc/welcome (login banner) and config.fluffos itself (see AGENTS.md §5 for the double-corruption trap hit here on first attempt — fixed by re-copying fresh from raw/ and converting before any edits). 2. .c.lpc rename: 855 files. Fixed 117 literal ".c" string references across .lpc files, plus 36 in include/globals.h (the F_DBASE macro — AGENTS.md §2, this is the one that cost the most time to find since it surfaced as a runtime "Inherited file does not exist" rather than a compile error). One orphaned non-LPC file caught by the blind rename (d/shenmin/shenminmap.c, ASCII-art map, unreferenced anywhere) — renamed to .txt instead (AGENTS.md §12). 3. staticnosave: 89 occurrences across the lib (AGENTS.md §3). 4. master.lpc's valid_read()/valid_write() had the lazy load_object(SECURITY_D) recursion bug (AGENTS.md §4) — added the re-entrancy-guard + catch() fix. 5. master.lpc's valid_override() was the old 2-arg signature, which wrongly rejects efun:: overrides written in #included simul_efun fragments (AGENTS.md §14) — added the 3rd main_file parameter. (Never actually manifested in a real boot, only in the lpcc sweep testing a fragment file as a standalone object — fixed anyway since it's free and more correct.) 6. master.lpc does NOT have get_root_uid() (driver printed a non-fatal warning and continued — did not need the AGENTS.md §7 stub fix here; this lib's exit(-1) path apparently doesn't fire the way lib #2's did. Left as-is since the lib boots and plays fine regardless). 7. Config: removed 5 obsolete keys (address server ip/port, binary directory, swap file, reserved size), set port number : 40001, mudlib directory to the absolute work/ path. 8. Full lpcc_check.sh sweep run (854 files after the shenminmap.txt rename; 832 pass / 22 fail). Fixed 6 pre-existing typo bugs found this way (all unrelated to our conversion — verified against raw archive bytes): - d/zuichen/{cdkedian3,cdkedian4,cdyaopu,chengzhong}.lpc: fullwidth comma used as an argument separator (AGENTS.md §9). - d/shiwang/qianqingon.lpc: fullwidth period in #include <ansi。h> (AGENTS.md §9). - std/room/shop.lpc, cmds/std/put.lpc: missing closing " before string concatenation (AGENTS.md §10). - adm/daemons/rankd.lpc: 8× switch(x) { default: ... } with no real case label (modern grammar requires at least one) — removed the pointless switch wrapper, kept the body (indentation not perfectly preserved, cosmetic only). - cmds/wiz/invis.lpc: declared void main(...) but returned 1/0 (command-dispatch status codes) — changed to int main(...). - obj/weapon/axe.lpc: copy-paste bug, inherit AXE/init_axe(...) but /std/weapon/axe.lpc was never implemented in this lib and the file's own header comment/id/name all say "dagger" — redirected to inherit DAGGER/init_dagger(...) (AGENTS.md §11). - obj/cloth.lpc: same pattern, inherit CLOTH with no /std/armor/cloth.lpc to back it — redirected to inherit U_ARMOR (matches its setup() call and "basic starting equipment" role).

Known remaining issues (not fixed — documented, low priority)

How to run

cd libs/shzs
~/src/fluffos/build-debug/src/driver config.fluffos
# separately:
python3 ../../scripts/mudclient.py 127.0.0.1 40001 --timeout 10 --send "" --send "look" --send "quit"

Post-hoc fix: UTF8-native is_chinese/registration (AGENTS.md §15h)

Applied in a later batch pass across the whole project: is_chinese/is_chinese2 in the shared chinese.lpc simul_efun fragment used GBK byte-range checks that silently never match real Chinese text once strings are UTF-8 (this driver's str[i] returns a Unicode codepoint, not a GBK byte). This broke character registration specifically -- any real Chinese name was rejected. Fixed the range check to test the CJK Unicode block instead, and halved the GBK-byte-calibrated length bounds in check_legal_name to match. See AGENTS.md §15h for the full writeup; confirmed via a real interactive registration test (Chinese surname + given name reaching the next prompt).

Re-verification pass: driver rebuild + formatter + WASM (2026-07-23)

WASM-enablement pass (2026-07-24): admin seeding only (no gates found)

Checked for all four standard gate classes (AGENTS.md §1.3b/e): no band.lpc/BAN_D-style ban daemon, no site-restriction daemon, no uptime() check anywhere in the login path, and no per-IP anti-flood/ multi-login throttle (logind.lpc/logind2.lpc only use query_ip_number/query_ip_name cosmetically, in log lines and "who connected from where" messages — confirmed by grep, not just absence of symptoms). So items 1-3 of the standard pass (loopback-allow, uptime-bypass, throttle-exemption) are not applicable to this lib — nothing to patch.

Admin account: registered fluffos / Mud@2026 through the real registration flow (id fluffos accepted directly — no length/reserved- word conflict), Chinese name 浮浮, gender m, attributes 10/10/10/10/10/10. Granted (admin) via /adm/etc/wizlist (this file already had a fluffos (admin) line staged from an earlier interrupted pass; verified /adm/daemons/securityd.lpc reads this file for wizard-level decisions). Verified in ONE continuous session: login as fluffos, look, then update /adm/daemons/securityd.lpc recompiled successfully (ACL grants write/compile access), then clean quit. Re-verified a fresh normal registration end-to-end afterwards (id qinfeng, name 秦风, same attribute split) reaching 梦旅馆大厅 with working look/score/quit; its test save (data/login/q/qinfeng.o, data/user/q/qinfeng.o) was removed afterwards. debug.log clean (compiler warnings only, no errors) across both sessions. Save files for the orchestrator to force-add: data/login/f/fluffos.o, data/user/f/fluffos.o (untracked, not gitignored).

Note: an earlier same-batch agent's driver process for this lib (PID 4045698, started 00:37, before this session began) was found still bound to port 40001 with no admin work done yet; it was killed (exact PID) and the driver relaunched fresh before doing the registration above.

深度功能测试 / Deep functional test (2026-07-24, round two)

First genuine hands-on *playthrough* pass on this lib (all prior passes verified registration + look/score/quit/update, never a real walk through content). Native driver (build-debug), one continuous session per check, scripts/mudclient.py. Test character: id linfeng, Chinese name 林风, password Abc12345, attributes 15 力量/ 10 敏捷/10 智力/6 注意/17 体质/2 技术 (the game's own example split from help's attribute-allocation screen) — kept as a representative playthrough character, currently standing on a d/lwe/jie* street (state below). Save files: work/data/user/l/linfeng.o, work/data/login/l/linfeng.o.

This lib's help newbie/help intro don't exist as such; its actual newbie doc is help (topics: story, cmds) — read first, per the checklist, and immediately found broken (see bug 1).

Bug 1 — help/help cmds/help story and the day/night broadcast

text were still raw GBK bytes, never converted (AGENTS.md §4.1 class, just missed on this lib's original pass)

Bug 2 — per-command 指令格式: (syntax) help lines mis-decoded as

GBK when the source byte run was actually BIG5 (same §4.1 class, a narrower/more surgical instance)

Bug 3 — a player who disconnects uncleanly is stranded in the void,

via TWO independent code paths (new bug class — see report for the AGENTS.md draft)

Found by literally doing what §10.7 step 5 asks: quit, grep debug.log, reconnect after a real gap, confirm state — except the very first "reconnect after real gap" (a session that ended by the mudclient.py connection simply going away, i.e. exactly what a real player's dropped wifi/closed laptop lid looks like, not a clean quit) landed linfeng in "影子世界" (obj/void.lpc, the VOID_OB net-dead holding room — zero exits) instead of back where they'd been.

What else was tested and confirmed working

Explicitly NOT verified live (with reason)

深度功能测试第二轮 / Deep functional test round two (2026-08-15, post driver-upgrade re-test)

驱动于 2026-08-12 升级后的重测。标准检查清单发现并修复三处问题:

1. config.fluffosmaximum evaluation cost700000(已知 风险区间)提升到 5000000。 2. adm/simul_efun/file.lpclog_file() 没有 assure_file() 目录预建保护,补上调用及前向声明;cat() 补上 read_file() || "" 空值防护。 3. obj/user.lpc::reconnect()(AGENTS.md §7.108,第五条独立确认 的血统——本档案与此前命中过的 shenzhou/shiji/shujian2008/shujian3 均无关联,是完全不同的 obj/user.lpc 架构,同一 bug 在这条独立 血统上再次出现)adm/daemons/logind.lpc 有同款 exec(old_link, user); 踢掉重复登录写法,reconnect() 缺少 enable_commands()。 按 §7.108 记录的写法预防性修复,现场用两个真实连线复现"保持第一 个连线不断开→第二个连线登录→答 y 踢掉旧连线"验证:score 修复 后立即正常显示完整角色档案。

cmds/wiz/update.lpc(§7.106)与 master.lpc::log_error()(§7.10 的 "arning:" 大小写无关写法)均已是正确写法,无需改动;本档案无 adm/daemons/closed.lpc,不受 §7.107 影响。

现场验证摘要

驱动干净启动,管理员 fluffos/Mud@2026 登录确认 目前权限: (admin)update /adm/daemons/logind 成功验证真实写入权 限。踢掉重复登录重连路径现场验证通过(见上)。debug.log 全程干净 (448 行,无真实错误)。

本轮修改的文件

深度功能测试第三轮 / Deep functional test round three (2026-08-18)

Standard §7.111/§7.112/logind-save/case-mismatch checklist (all clean, no action needed):

Bug found and fixed — adm/simul_efun/gender.lpc was BIG5 bytes

mis-decoded as GBK during the original conversion pass (same class as round two's Bug 2, much wider blast radius)

Bug found and fixed — netdead reconnect never restores heart_beat,

permanently soft-locking anyone who dies and ever has one dropped connection (new bug class, not previously in AGENTS.md)

What else was tested this round

Files modified this round

§7.114 fix: private input_line() broke multi-line to/board/mail input (2026-08-19)

Same ES2/FF-ancestry bug as zzhj/dfgs2 (see AGENTS.md §7.114): work/feature/edit.lpc (this lib's F_EDIT mixin, inherited by std/char.lpc) declared its input_to() re-arm target private: private void input_line(string line, string text, function callback). The recursive re-arm from inside input_line() silently failed to register once reached through the inherited mixin, so any multi-line .-terminated input session (board post, to, mail) dropped everything after the first line. Fix: dropped private.

Live-verified on a fresh driver boot (port 40001), fresh character (秦捌捌/qinbaba): to say → two lines of text → . → resulting say output showed both lines (你 说道: hello line one\nhello line two), not truncated after line 1. This lib has no chfn.lpc and its board object isn't placed in any reachable room in this archive, so cmds/usr/to.lpc (which drives the identical edit()/input_line() flow) was used as the representative live test instead of post. Killed the driver by exact PID when done.

Files modified this pass:

§7.100 sub-threshold instance (2026-08-20)

Found during the §7.100 tail-sweep (below the original 166-lib survey's

=100-occurrence threshold, never checked). 10 live

replace_program(ROOM); occurrences across 10 room files (obj/void.lpc, d/zuichen/jinshedong.lpc, d/shiwang/yongdingmen.lpc, d/mohao/*.lpc x4, d/death/*.lpc x3) — same fatal redundant-replace-after-inherit shape as the rest of the §7.100 family. No room-building tool exists in this lib. Fixed by deleting the redundant lines. Verified via a clean native driver boot (zero new debug.log errors, port listening, killed by exact PID after ~8s).

§7.30 uninitialized-mapping accessor sweep (2026-08-20)

Corpus-wide mechanical sweep of the feature/skill.lpc shared-lineage bug (confirmed independently on xiakexing2017/jqxz2015/haiyang2 via round-four testing): 3 accessor(s) in this file returned a raw never-initialized mapping instance variable (defaults to int 0, not ([]), until first assigned), crashing any unguarded keys()/sizeof()/indexing caller for a fresh/untrained character. Fixed at the accessor level (mapp(x) ? x : ([])) per the documented remedy. Verified via lpcc --batch static compile check only (not a live boot) as part of a large mechanical sweep; not individually functionally re-tested live on this lib.