fix(movement): remove unreferenced [0.25,3.0] clamp on local player's movSpd scale
CInstanceBase::SetMoveSpeed only guards moving_speed > 1100 -> 0; the local player's set_server_speed() was additionally floor/ceil-clamping the scale to an arbitrary [0.25, 3.0] band with no basis in the reference or in this project's already-fixed remote-entity equivalent (EntityStore::motion_move_speed). A heavy haste stack or slow debuff on the local player would silently diverge from what everyone else sees. Removed the extra clamp; kept the moving_speed<=0 early-return guard against pre-spawn/malformed values. audit: movement.keyboard.motion/server-speed-scale-clamp closed with reference citation, regression test, and full related-suite pass; contract stays PARTIAL. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5
parent
a4ac48db24
commit
c5c183da37
@@ -306,3 +306,30 @@ GC_STUN 主角分流。**
|
||||
`network.login.phase_flow/auth-game-phase-matrix/live-package-order/server-initiated-phase-close`:
|
||||
本地结构和 owner 分支均已覆盖,只等新的真实服务端/Windows fixture;在没有新 fixture 前不要
|
||||
重复 `/logout` 探针或重复修改已闭合的 owner 分支。
|
||||
|
||||
### 2026-09-22T03:15Z:`movement.keyboard.motion/server-speed-scale-clamp` 修复
|
||||
|
||||
追查上一轮列出的四个候选之一(`AccumulationMovement` 根运动/连续速度替代差异)时,先确认
|
||||
远端 `entity_store.cpp::advance_walk_by_motion` 和本地 `_process()` 的位移积分在种类上同构
|
||||
(都是恒速 `speed*dt` 直线插值),排除了「需要整体迁移到逐帧根运动采样」这个更大方向;转而
|
||||
逐项核对两条路径各自的速度缩放公式,发现真正的差异:本地 `set_server_speed()` 把
|
||||
`moving_speed/100.0` 塞进 `clampf(..., 0.25, 3.0)`,而参考 `CInstanceBase::SetMoveSpeed`
|
||||
(`InstanceBaseMovement.cpp`)和本项目已修复的远端 `EntityStore::motion_move_speed` 都只有
|
||||
`moving_speed>1100 → 0` 一个门,没有下限/上限夹钳。已修复为
|
||||
`0.0 if moving_speed > 1100 else moving_speed/100.0`,新增 `keyboard_motion_timeline_test.gd`
|
||||
断言覆盖旧边界内外和 1100 冻结门,随同全部相关回归套件(`test_wasd_steering_parity`、
|
||||
`test_no_auto_move_regression`、`game_camera_test`、`movement_parity_test`、`player_move_test`、
|
||||
`mouse_controller_test`、`test_alignment_parity`、`netplay_test`)通过。详见
|
||||
`audit/contracts/movement.keyboard-motion.md` 的 `Implementation fix round 2026-09-22 —
|
||||
server-speed-scale-clamp` 小节。**该分支已关闭,不要在没有新证据的情况下重新调整
|
||||
`set_server_speed` 的缩放边界。**
|
||||
|
||||
副产品发现(未下定论,供下一轮参考):`CInstanceBase::SHORSE::SetMoveSpeed`
|
||||
(`InstanceBase.cpp:40-135`)是坐骑上玩家的独立速度设定,只在 `IsMounting()` 时生效;
|
||||
远端实体对 `mount_vnum!=0` 直接归零,而本地玩家改走 `MOTION_MODE_HORSE` 动作资源——
|
||||
两者是否构成差异本轮未核实,不要不经调查直接假设一致或假设有 bug。
|
||||
|
||||
`movement.keyboard.motion` 下一轮候选收窄为:`AccumulationMovement` 固定 300cm
|
||||
根运动/连续速度替代差异(积分种类已确认同构,但逐帧时序/`.msa` motion event 源仍未对拍)、
|
||||
`OnMove/OnMoving/OnWaiting/OnStop` 资源事件源、同步/受击/死亡/传送门叠加顺序、真实模型骨骼
|
||||
快切不翻转的模型级测试、坐骑速度设定(`SHORSE::SetMoveSpeed`)——五者均仍未闭合。
|
||||
|
||||
Reference in New Issue
Block a user