diff --git a/assets/blender/fbc_blackout_props.blend b/assets/blender/fbc_blackout_props.blend index ef426d9..d84480e 100644 Binary files a/assets/blender/fbc_blackout_props.blend and b/assets/blender/fbc_blackout_props.blend differ diff --git a/assets/models/props/case_frame.glb b/assets/models/props/case_frame.glb index 92840aa..4e757ee 100644 Binary files a/assets/models/props/case_frame.glb and b/assets/models/props/case_frame.glb differ diff --git a/assets/models/props/case_glass.glb b/assets/models/props/case_glass.glb index a619df3..5abcd44 100644 Binary files a/assets/models/props/case_glass.glb and b/assets/models/props/case_glass.glb differ diff --git a/assets/models/props/phone_table.glb b/assets/models/props/phone_table.glb index 3b70416..8c2a597 100644 Binary files a/assets/models/props/phone_table.glb and b/assets/models/props/phone_table.glb differ diff --git a/docs/BLACKOUT_RITUAL.md b/docs/BLACKOUT_RITUAL.md index d5fc093..8464993 100644 --- a/docs/BLACKOUT_RITUAL.md +++ b/docs/BLACKOUT_RITUAL.md @@ -83,20 +83,27 @@ Edge cases: waves; post FX and the containment clock stay visible throughout. - No blackout HUD. Only the normal objective panel and containment clock remain, so the clock's pressure stays legible; the puzzle is read from the world. - `draw_blackout_labels()` projects small FBC placards above the screen, the - nearest unanswered phone (within 6 m) and the case (within 9 m). + `draw_blackout_labels()` projects a small FBC placard above the screen and, + once revealed, above the OoP case (within 9 m). The phone tables carry no + helper labels — the red glow is the whole prompt. ## 5. Blender assets (`tools/blender/build_blackout_props.py`) | GLB | Contents | Tris | Rendering in game | |---|---|---|---| -| `phone_table.glb` | Desk, drawer, red handset, rotary dial, hot indicator, cord | 746 | opaque actor shader, pulsing flash + red glow | -| `case_frame.glb` | Plinth, brass trim, four posts, **yellow Board roof**, roof seal | 176 | opaque actor shader, 1.5× scale | -| `case_glass.glb` | Four translucent panes | 64 | actor shader with new `uAlpha` uniform (0.30) and depth-mask-free alpha blending | +| `phone_table.glb` | Desk, drawer, red handset, rotary dial, hot indicator, cord (authored 1.5× size) | 746 | opaque actor shader, pulsing flash + red glow | +| `case_frame.glb` | Plinth, brass trim, four posts, **yellow Board roof**, roof seal (authored 2× size) | 176 | opaque actor shader, 1.5× scale | +| `case_glass.glb` | Four translucent panes (authored 2× size) | 64 | actor shader with new `uAlpha` uniform (0.30) and depth-mask-free alpha blending | Conventions: one merged mesh per GLB, painted `Color` vertex attribute, origin at feet, facing +Z in engine (-Y in Blender), exports via `actor_kit.export_actor`. -The existing `switch.glb` is drawn inside the case (2.2× scale). +`CASE_SCALE = 2.0` in the generator doubles the case frame/glass geometry; the +game keeps its 1.5× draw scale, so the OoP container ships at twice the original +footprint and height. The existing `switch.glb` is drawn inside it (4.4× scale, +also doubled so the switch still fills the case). `PHONE_TABLE_SCALE = 1.5` +likewise scales the hotline desks at source so they read as full-size furniture +beside the ~1.9 m agent; their draw scale stays 0.78× and the red ground ring +is tightened to match the wider footprint. Concept: `docs/concept/blackout_props_lineup.png`. Source scene: `assets/blender/fbc_blackout_props.blend`. diff --git a/docs/concept/blackout_props_lineup.png b/docs/concept/blackout_props_lineup.png index 163cbac..172d015 100644 Binary files a/docs/concept/blackout_props_lineup.png and b/docs/concept/blackout_props_lineup.png differ diff --git a/src/game/blackout.hpp b/src/game/blackout.hpp index 9a12999..ab42f89 100644 --- a/src/game/blackout.hpp +++ b/src/game/blackout.hpp @@ -16,7 +16,7 @@ class BlackoutSequence { public: static constexpr int kPhoneCount = 20; // 5 columns x 4 rows static constexpr float kPhoneRadius = 2.2f; - static constexpr float kCaseRadius = 2.6f; + static constexpr float kCaseRadius = 2.6f; // step-inside radius, independent of the art size static constexpr float kLightsOutDelay = 2.0f; // grace period in the screen void init(const Floor& floor); // derive layout from the authored Screen prop diff --git a/src/render/presenter.cpp b/src/render/presenter.cpp index d34ae75..3c968ec 100644 --- a/src/render/presenter.cpp +++ b/src/render/presenter.cpp @@ -1136,26 +1136,13 @@ void Presenter::draw_blackout_labels(const Game& game) { const BlackoutSequence& b = game.blackout; const Vec2 p = game.player.pos; - int nearest = -1; - float best = 6.0f; // inspection range - for (int i = 0; i < BlackoutSequence::kPhoneCount; ++i) { - if (b.phone_answered(i)) continue; - const float d = distance(p, b.phone(i)); - if (d < best) { - best = d; - nearest = i; - } - } - if (nearest >= 0) { - const Vec2 q = b.phone(nearest); - const Vector2 s = GetWorldToScreen({q.x, 1.4f, q.y}, camera_); - draw_inspection_placard(s, "FBC HOTLINE", "LINE STILL OPEN", - Color{245, 197, 24, 255}); - } + // No placards over the phone tables — the ringing desks read the puzzle on + // their own. The one world label left is the OoP case, lifted to clear its + // doubled-height roof. if (b.phase() == BlackoutPhase::CaseRevealed && distance(p, b.case_pos()) < 9.0f) { const Vec2 c = b.case_pos(); - const Vector2 s = GetWorldToScreen({c.x, 2.8f, c.y}, camera_); + const Vector2 s = GetWorldToScreen({c.x, 5.6f, c.y}, camera_); draw_inspection_placard(s, "OBJECT OF POWER", "LIGHT SWITCH / CLASS IV", Color{245, 197, 24, 255}); } @@ -1190,12 +1177,14 @@ void Presenter::draw_blackout(Game& game) { answered ? Color{80, 80, 86, 255} : WHITE, ring_flash, false, 0.0f, 0.0f, anim_time_ * (answered ? 0.2f : 1.2f)); if (!answered) { - DrawCylinder({q.x, 0.04f, q.y}, 0.9f, 0.9f, 0.012f, 12, + // The GLB is authored 1.5x; the ring hugs the desk instead of + // dwarfing it, and the glows ride the taller handset. + DrawCylinder({q.x, 0.04f, q.y}, 1.1f, 1.1f, 0.012f, 12, Color{255, 45, 55, static_cast(70 + 40 * pulse)}); - glow_batch.add_billboard({q.x, 1.15f, q.y}, 3.2f, 3.2f, + glow_batch.add_billboard({q.x, 1.4f, q.y}, 3.6f, 3.6f, cam_right, cam_up, Color{255, 80, 90, 200}); - glow_batch.add_ground({q.x, 0.02f, q.y}, 1.4f, + glow_batch.add_ground({q.x, 0.02f, q.y}, 1.7f, Color{220, 30, 40, 85}); } } @@ -1203,15 +1192,16 @@ void Presenter::draw_blackout(Game& game) { if (b.phase() == BlackoutPhase::CaseRevealed) { const Vec2 c = b.case_pos(); models_.draw(ActorModel::CaseFrame, {c.x, 0.0f, c.y}, 0.0f, 1.5f, WHITE); - models_.draw(ActorModel::Switch, {c.x, 0.0f, c.y}, 0.0f, 2.2f, + models_.draw(ActorModel::Switch, {c.x, 0.0f, c.y}, 0.0f, 4.4f, WHITE, 0.0f, false, 0.0f, 0.0f, 0.0f, 0.55f); // Glass last, blended, with the switch visible through the panes. + // Frame/glass GLBs are authored 2x larger; only this draw scale is used. models_.draw(ActorModel::CaseGlass, {c.x, 0.0f, c.y}, 0.0f, 1.5f, Color{190, 225, 235, 255}, 0.0f, false, 0.0f, 0.0f, 0.0f, 0.0f, {0.0f, 0.0f, 0.0f}, 0.30f); - DrawCylinder({c.x, 0.06f, c.y}, 3.0f, 3.0f, 0.02f, 24, + DrawCylinder({c.x, 0.06f, c.y}, 6.0f, 6.0f, 0.02f, 24, Color{245, 197, 24, 120}); - glow_batch.add_billboard({c.x, 1.3f, c.y}, 4.5f, 4.5f, + glow_batch.add_billboard({c.x, 2.6f, c.y}, 9.0f, 9.0f, cam_right, cam_up, Color{245, 197, 24, 70}); } diff --git a/tools/blender/build_blackout_props.py b/tools/blender/build_blackout_props.py index 182de9c..e91b4de 100644 --- a/tools/blender/build_blackout_props.py +++ b/tools/blender/build_blackout_props.py @@ -34,6 +34,14 @@ P = K.PALETTE P.update({"plastic": "#2a2d33", "glass": "#9fc4cf", "concrete_lt": "#9d9c96", "brass": "#b89348"}) +# The OoP container is authored at half its shipped size: the frame and glass +# GLBs are uniformly doubled here, so both the game and the concept scene get +# one single, reproducible size change (no second scale in the presenter). +CASE_SCALE = 2.0 +# Hotline desks ship 1.5x their authored size so a ringing table reads as real +# office furniture next to the ~1.9 m agent instead of doll-house dressing. +PHONE_TABLE_SCALE = 1.5 + def rect(rx, ry): return [(-rx, -ry), (rx, -ry), (rx, ry), (-rx, ry)] @@ -120,6 +128,14 @@ roots = {} for name, builder, cap in BUILDERS: root = builder() K.merge_actor(root, name) + # export_actor uses export_apply=True, so this object scale is baked into + # the GLB; the .blend keeps it editable on the merged mesh. + art_scale = CASE_SCALE if name.startswith("case_") else ( + PHONE_TABLE_SCALE if name == "phone_table" else 1.0) + if art_scale != 1.0: + for child in root.children_recursive: + if child.type == "MESH": + child.scale = (art_scale, art_scale, art_scale) tris = K.triangle_count(root) print("[budget] %-12s %5d tris (cap %d) %s" % (name, tris, cap, "OK" if tris <= cap else "OVER")) @@ -146,11 +162,11 @@ for pane in roots["case_glass"].children_recursive: bpy.ops.object.select_all(action="DESELECT") bpy.ops.import_scene.gltf(filepath=os.path.join(MODEL_DIR, "switch.glb")) switch_root = bpy.context.object -for name, x in (("phone_table", -2.4), ("case_frame", 0.6), +for name, x in (("phone_table", -3.0), ("case_frame", 0.6), ("case_glass", 0.6)): roots[name].location.x = x -switch_root.location = (0.6, 0, -0.16) -switch_root.scale = (1.7, 1.7, 1.7) +switch_root.location = (0.6, 0, -0.16 * CASE_SCALE) +switch_root.scale = (1.7 * CASE_SCALE, 1.7 * CASE_SCALE, 1.7 * CASE_SCALE) world = bpy.data.worlds.new("BlackoutWorld") bpy.context.scene.world = world @@ -177,8 +193,8 @@ for name, loc, power, col in ( cam_data = bpy.data.cameras.new("BlackoutCam") cam = bpy.data.objects.new("BlackoutCam", cam_data) bpy.context.scene.collection.objects.link(cam) -cam.location = (0.4, -9.5, 4.2) -cam.rotation_euler = (Vector((0.6, 0, 1.1)) - cam.location).to_track_quat("-Z", "Y").to_euler() +cam.location = (0.4, -14.0, 5.8) +cam.rotation_euler = (Vector((0.6, 0, 2.2)) - cam.location).to_track_quat("-Z", "Y").to_euler() cam_data.lens = 42 scene = bpy.context.scene scene.camera = cam