Files
space-game/apps/viewer/src/contractsCelestial.ts

69 lines
1.5 KiB
TypeScript

import type { Vector3Dto } from "./contractsCommon";
export interface SystemSnapshot {
id: string;
label: string;
galaxyPosition: Vector3Dto;
starKind: string;
starCount: number;
starColor: string;
starSize: number;
planets: PlanetSnapshot[];
}
export interface PlanetSnapshot {
label: string;
planetType: string;
shape: string;
moonCount: number;
orbitRadius: number;
orbitSpeed: number;
orbitEccentricity: number;
orbitInclination: number;
orbitLongitudeOfAscendingNode: number;
orbitArgumentOfPeriapsis: number;
orbitPhaseAtEpoch: number;
size: number;
color: string;
hasRing: boolean;
}
export interface ResourceNodeSnapshot {
id: string;
systemId: string;
localPosition: Vector3Dto;
anchorNodeId?: string | null;
sourceKind: string;
oreRemaining: number;
maxOre: number;
itemId: string;
}
export interface ResourceNodeDelta extends ResourceNodeSnapshot {}
export interface SpatialNodeSnapshot {
id: string;
systemId: string;
kind: string;
localPosition: Vector3Dto;
bubbleId: string;
parentNodeId?: string | null;
occupyingStructureId?: string | null;
orbitReferenceId?: string | null;
}
export interface SpatialNodeDelta extends SpatialNodeSnapshot {}
export interface LocalBubbleSnapshot {
id: string;
nodeId: string;
systemId: string;
radius: number;
occupantShipIds: string[];
occupantStationIds: string[];
occupantClaimIds: string[];
occupantConstructionSiteIds: string[];
}
export interface LocalBubbleDelta extends LocalBubbleSnapshot {}