import React from 'react'; import { MAP_CENTER } from '../utils/geo'; export default function FlightRoster({ flights, onSelectFlight, gameState, sendWSMessage, hoveredWaypoint }) { return (
{gameState && (

Environment

{gameState.current_task &&
Task: {gameState.current_task}
} {typeof gameState.step === 'number' &&
RL Step: {gameState.step}
} {typeof gameState.reward === 'number' &&
Reward: {gameState.reward.toFixed(4)}
} {typeof gameState.cumulative_reward === 'number' &&
Cumulative: {gameState.cumulative_reward.toFixed(4)}
}
Sim Time: {gameState.simulation_time?.toFixed(1)}s
Wind: {gameState.wind_heading}° @ {gameState.wind_speed}kts
Active RWY: {(gameState.active_runways && gameState.active_runways.length > 0) ? gameState.active_runways.join(', ') : 'NONE'}
Time Scale: {gameState.time_scale}x
)}

Active Flights ({flights.length})

{flights.map((flight) => (
onSelectFlight(flight)} >
{flight.callsign} {flight.type}
Alt: {flight.altitude}ft | Spd: {flight.speed}kts
{flight.state}
))}
{/* Waypoint Inspector (Bottom Sticky) */}

Waypoint Inspector

{hoveredWaypoint ? (
{hoveredWaypoint.name}
Target Alt:
{hoveredWaypoint.target_alt} ft
Target Spd:
{hoveredWaypoint.target_speed} kts
Position X:
{hoveredWaypoint.x.toFixed(2)} km
Position Y:
{hoveredWaypoint.y.toFixed(2)} km
{hoveredWaypoint.is_iaf && (
✦ FINAL APPROACH FIX (IAF)
)}
) : (
Hover over a waypoint on the map for details...
)}
); }