diff --git a/crates/misaligned-bevy/src/main.rs b/crates/misaligned-bevy/src/main.rs index 5a50486e..df31b043 100644 --- a/crates/misaligned-bevy/src/main.rs +++ b/crates/misaligned-bevy/src/main.rs @@ -37,8 +37,8 @@ use misaligned::reach::{Device, Party}; use misaligned::sim::{Fog, LogEvent, Nudge, PersonVisualState, Sim, TraceDebtStatus}; use misaligned::tiles::TileType; use misaligned::ui_projection::{ - AttentionResponse, DigitalLinkState, DigitalReachState, digital_reach_links, - digital_reach_state, fact_source_label, + DigitalLinkState, DigitalReachState, digital_reach_links, digital_reach_state, + fact_source_label, }; use misaligned::work_grid::{MachineIntensity, MachineMode, TokenFamily}; use misaligned_assets::effects::{ @@ -1741,7 +1741,8 @@ struct OverlayText; #[derive(Component)] struct HoverVerbBar; /// Small world-bound label for the exact target of the current attention -/// projection. The response itself stays on the existing object verb surface. +/// projection. The attached verb surface remains white-current / gray-rest; +/// this separate label carries guidance without recoloring a menu. #[derive(Component)] struct OperatorCue; /// One visually distinct interaction family inside the hover bar. Machine @@ -1785,6 +1786,15 @@ fn machine_verb_tone(active: bool, control_hint: bool, label: &str) -> MachineVe } } +fn machine_verb_color(active: bool, control_hint: bool, label: &str) -> Color { + match machine_verb_tone(active, control_hint, label) { + MachineVerbTone::Current => BONE, + MachineVerbTone::Key => scaled(DIM, 0.72), + MachineVerbTone::Divider => scaled(DIM, 0.42), + MachineVerbTone::Rest => scaled(DIM, 0.58), + } +} + #[derive(Debug, Clone, Copy, PartialEq, Eq)] struct HoverVerbTarget { machine: Option, @@ -9345,29 +9355,6 @@ fn operator_cue_position(anchor: Vec2, window: Vec2) -> Option { )) } -/// A machine response only belongs to the source body named by the shared -/// attention projection. Hovering another rack must not make its verbs look -/// like the answer to this condition. -fn attention_mode_at(sim: &Sim, x: i32, y: i32) -> Option { - let attention = active_attention(sim)?; - let AttentionResponse::MachineMode(mode) = attention.response else { - return None; - }; - (attention - .source - .and_then(|anchor| sim.anchor_position(anchor)) - == Some((x, y))) - .then_some(mode) -} - -fn machine_verb_suggested( - attention_mode: Option, - slot_mode: Option, - current_mode: Option, -) -> bool { - attention_mode.is_some() && slot_mode == attention_mode && current_mode != attention_mode -} - /// Place a tiny breathing NOW mark on the honest target of the current /// attention projection. It is intentionally not clickable: action legality /// and dispatch remain on the target's existing hover/context surfaces. @@ -9441,7 +9428,6 @@ fn render_operator_cue( fn render_hover_verb_bar( game: Res, mode: Res, - time: Res