-
Notifications
You must be signed in to change notification settings - Fork 0
SphereInput
Imported from @elite-dangerous-almanac/galaxy-map.
What a host passes to addSpheres. The type states the contract and the reader holds
it: every field is still checked at run time, because the data comes from a file or a
network call the compiler does not see.
The index signature lets a record carry fields the reader drops.
[
field:string]:unknown
A field the reader drops.
readonlyoptionalcategories?: readonlystring[]
The names of categories the table holds, in the order the sphere reads them. The first one that is on for shapes gives the colour, where the sphere carries none.
readonlyoptionalcolor?: readonly [number,number,number]
Red, green and blue, each from 0 to 255. A sphere that names a category may leave it out and take the colour of the first category it names that is on.
readonlyoptionalname?:string
What the shape stands for. The map draws no label for it.
readonlyoptionalopacity?:number
How deep the shell reads at its middle. The default is 0.18.
readonlyposition: readonly [number,number,number]
The centre in game coordinates, in light years.
readonlyoptionalprimaryCategory?:undefined
The two names categories replaces. Each one is never, so a shape that carries it
fails the compile. The index signature below turns off TypeScript's excess-property
check, so without the pair the old name would compile and the reader would drop it.
readonlyradius:number
The radius in light years. It is above 0.
readonlyoptionalsecondaryCategories?:undefined
Examples
Interfaces
- AddReport
- Category
- CategoryInput
- CategoryReject
- CategoryReport
- DatasetContent
- DatasetEntry
- DatasetInfo
- DatasetLoadResult
- FlyToOptions
- FlyToTarget
- FragmentWriter
- FragmentWriterOptions
- GalaxyMap
- GalaxyMapOptions
- HudAction
- HudHandle
- HudInfoFields
- HudOptions
- InteractionSwitches
- Line
- LineInput
- MapView
- NebulaSource
- RealSystem
- Reject
- ResolvedIcon
- ShapeInfo
- ShapeReject
- ShapeReport
- Sphere
- SphereInput
- StartView
- SystemDetailValue
- SystemDetails
- SystemImage
- SystemRecordInput