27 lines
748 B
TypeScript
27 lines
748 B
TypeScript
// Aircraft catalog — in-code constants for now (no DB table yet). One type is
|
|
// enough for the MVP; add more entries to PLANE_TYPES as they are designed.
|
|
|
|
export interface PlaneType {
|
|
id: string;
|
|
name: string;
|
|
// Fuel capacity, liters.
|
|
maxFuel: number;
|
|
// Fuel burn per km of flight, liters/km (cruise).
|
|
burnPerKm: number;
|
|
// Cruise speed, km/h — used by the sim tick to advance planes along routes.
|
|
speedKmh: number;
|
|
}
|
|
|
|
export const PLANE_TYPES: Record<string, PlaneType> = {
|
|
atr72: {
|
|
id: 'atr72',
|
|
name: 'ATR 72-600',
|
|
maxFuel: 6300,
|
|
burnPerKm: 1.75, // ~900 kg/h at 510 km/h cruise (Jet-A1 ≈ 0.8 kg/L)
|
|
speedKmh: 510,
|
|
},
|
|
};
|
|
|
|
// The plane the player starts with.
|
|
export const STARTER_MODEL = 'atr72';
|