40250 classic: parallel-dev checkpoint through increment 49 (W0 interface freeze)
Captures the uncommitted parallel-development work (increments 46-49) on the
40250 classic client port, folded into docs/CLIENT-GAP.md + CLIENT-GAP-FIX.md.
Increment 49 (W0 interface-freeze batch, Phase 1 prerequisite) lands the
cross-workflow shared-file scaffolding so the 4 Phase 1 workflows can run in
isolated worktrees without contention:
- entity_store.{h,cpp}: Entity gains empire/affect_flags/owner_vid/state_flags;
new mut_spawn_full() (single-shot two-packet merge, §2.3), mut_ownership()
(§2.5), mut_map_bgm() + take_bgm_dirty()/bgm_name()/bgm_volume() (§9.1),
drain_dirty() (§2.1/§2.5 bare-field-update queue); mut_char_info() now stores
empire; reset_for_map_change() clears m_dirty.
- m2_client.cpp: new bgm_changed(name, volume) signal; classic + m2dev pump
loops drain drain_dirty() -> entity_info and take_bgm_dirty() -> bgm_changed;
entity_dict() exposes the 4 new keys.
- classic/classic_parser.{h,cpp}: GC_MAIN_CHARACTER3_BGM /
GC_MAIN_CHARACTER4_BGM_VOL route bgm_name/bgm_volume to mut_map_bgm() (was
discarded); new m_pending_actor staging map (W1 fills §2.2 merge logic).
- project/bgm_director.gd (new) + game_scene.gd: BGM consumption split out of
net_world.gd so W2/W4 don't collide; §8.6/§4.8 keybind convergence (digits
1-4 -> quickslots 0-3, F1-F4 -> quickslots 4-7, Ctrl+1..9 -> _emote()).
Tests: cmake --build build clean; ctest 16/16; 15 GDScript regressions green
(netbridge, gamescene, netplay, p9, p10, p2b, p8, system_menu_ui, skill,
combat_fx, skill_fx, player_motion, char_status_ui, chat, inventory), no skips.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014yvAPqPivoY7vmBbzgqK4W
This commit is contained in:
co-authored by
Claude Sonnet 5
parent
70f200e885
commit
f32064c74a
@@ -7,6 +7,7 @@ extends CanvasLayer
|
||||
var _world: Node
|
||||
var _player: Node3D
|
||||
var _minimap_rect: TextureRect
|
||||
var _minimap_frame: Control
|
||||
var _dot: ColorRect
|
||||
var _map_w_m := 1024.0
|
||||
var _map_h_m := 1280.0
|
||||
@@ -43,6 +44,21 @@ func setup(world: Node, player: Node3D) -> void:
|
||||
_build_hotbar()
|
||||
_build_inventory()
|
||||
|
||||
func reload_world(new_world: Node) -> void:
|
||||
_world = new_world
|
||||
if _world == null:
|
||||
return
|
||||
var rep: Dictionary = _world.call("get_load_report")
|
||||
_map_w_m = float(rep.get("map_size_x", 1)) * 256.0
|
||||
_map_h_m = float(rep.get("map_size_y", 1)) * 256.0
|
||||
if _minimap_frame and is_instance_valid(_minimap_frame):
|
||||
_minimap_frame.queue_free()
|
||||
_minimap_frame = null
|
||||
_minimap_rect = null
|
||||
_dot = null
|
||||
if int(rep.get("map_size_x", 0)) > 0 and int(rep.get("map_size_y", 0)) > 0:
|
||||
_build_minimap(int(rep["map_size_x"]), int(rep["map_size_y"]))
|
||||
|
||||
# --- real UI texture loading (§6.1) -------------------------------------------
|
||||
|
||||
func _ui_tex(name: String) -> Texture2D:
|
||||
@@ -149,6 +165,7 @@ func _build_minimap(nx: int, ny: int) -> void:
|
||||
big.blit_rect(img, Rect2i(0, 0, cell, cell), Vector2i(tx * cell, ty * cell))
|
||||
var mm_h := 192 * ny / nx if nx > 0 else 192
|
||||
var frame := _nine("board", 32, 128)
|
||||
_minimap_frame = frame
|
||||
frame.set_anchors_preset(Control.PRESET_TOP_RIGHT)
|
||||
frame.position = Vector2(-192 - 24 - 12, 12)
|
||||
frame.size = Vector2(192 + 24, mm_h + 24)
|
||||
|
||||
Reference in New Issue
Block a user