Add the ability to use integer NAIF IDs in a SpiceTranslation

This commit is contained in:
Alexander Bock
2022-08-01 18:25:55 +02:00
parent 41a4171aeb
commit 351eb33d61
17 changed files with 42 additions and 31 deletions
@@ -23,8 +23,8 @@ local lem_model = asset.syncedResource({
--landing - 1969-07-20T20:17:40
local apolloSpiceId = "-911"
local apolloLemSpiceId = "-911500"
local apolloSpiceId = -911
local apolloLemSpiceId = -911500
local Apollo11Position = {
Identifier = "Apollo11Position",
@@ -9,7 +9,7 @@ local models = asset.syncedResource({
Version = 4
})
local apolloSpiceId = "-908"
local apolloSpiceId = -908
local Apollo8Launch = {
Identifier = "Apollo8Launch",
@@ -9,7 +9,7 @@ local models = asset.syncedResource({
Version = 4
})
local apolloSpiceId = "-908"
local apolloSpiceId = -908
local Apollo8 = {
Identifier = "Apollo8",
@@ -2,7 +2,7 @@ local earth_transforms = asset.require("scene/solarsystem/planets/earth/transfor
local moon_transforms = asset.require("scene/solarsystem/planets/earth/moon/moon")
local kernels = asset.require("./kernels").kernels
local apolloSpiceId = "-908"
local apolloSpiceId = -908
local LaunchTrail = {
@@ -104,7 +104,7 @@ local TranslationKeyframes = {
Frame = "IAU_MARS",
Kernels = iKernels,
FixedDate = "2018 NOV 26 19:45:34"
},
}
}
local RotationKeyframes = {
@@ -770,7 +770,7 @@ local Insight_Trail = {
Type = "RenderableTrailTrajectory",
Translation = {
Type = "SpiceTranslation",
Target = "-189",
Target = -189,
Observer = "MARS",
Frame = "IAU_MARS",
Kernels = iKernels
@@ -29,7 +29,7 @@ local JWSTTrailLaunch = {
Type = "RenderableTrailTrajectory",
Translation = {
Type = 'SpiceTranslation',
Target = '170', -- JWST
Target = 170, -- JWST
Observer = 'EARTH',
Frame = 'IAU_EARTH',
Kernels = { kernels .. "webb.bsp" }
@@ -62,7 +62,7 @@ local JWSTTrailCruise = {
Type = "RenderableTrailTrajectory",
Translation = {
Type = 'SpiceTranslation',
Target = '170', -- JWST
Target = 170, -- JWST
Observer = 'EARTH',
Frame = 'GALACTIC',
Kernels = { kernels .. "webb.bsp" }
@@ -95,8 +95,8 @@ local JWSTTrailOrbit = {
Type = "RenderableTrailOrbit",
Translation = {
Type = 'SpiceTranslation',
Target = '170', -- JWST
Observer = '392', -- L2
Target = 170, -- JWST
Observer = 392, -- L2
Frame = 'GALACTIC',
Kernels = { kernels .. "webb.bsp" }
},
@@ -125,7 +125,7 @@ local JWSTSunTrail = {
Type = "RenderableTrailOrbit",
Translation = {
Type = 'SpiceTranslation',
Target = '170', -- JWST
Target = 170, -- JWST
Observer = 'SSB',
Frame = 'GALACTIC',
Kernels = { kernels .. "webb.bsp" }
@@ -23,22 +23,22 @@ local JWSTPosition = {
Keyframes = {
[launchTime] = {
Type = 'SpiceTranslation',
Target = '170', -- JWST
Target = 170, -- JWST
Observer = 'EARTH',
Frame = 'IAU_EARTH',
Kernels = { kernels .. "webb.bsp" }
},
[detachTime] = {
Type = 'SpiceTranslation',
Target = '170', -- JWST
Target = 170, -- JWST
Observer = 'EARTH',
Frame = 'GALACTIC',
Kernels = { kernels .. "webb.bsp" }
},
[L2orbitInsertionTime] = {
Type = 'SpiceTranslation',
Target = '170', -- JWST
Observer = '392', -- L2
Target = 170, -- JWST
Observer = 392, -- L2
Frame = 'GALACTIC',
Kernels = { kernels .. "webb.bsp" }
}
@@ -4,7 +4,7 @@ local earthTransforms = asset.require("scene/solarsystem/planets/earth/transform
local BENNU_BODY = "2101955"
local BENNU_BODY = 2101955
local OsirisRexTrailEarth = {
Identifier = "OsirisRexTrailEarth",
@@ -2,7 +2,7 @@ local transforms = asset.require("scene/solarsystem/sun/transforms")
local BENNU_BODY = "2101955"
local BENNU_BODY = 2101955
local BennuBarycenter = {
Identifier = "BennuBarycenter",
@@ -8,7 +8,7 @@ local kernels = asset.syncedResource({
Version = 2
})
local perseverance_id = "-168"
local perseverance_id = -168
local m2020_kernels = {
kernels .. "m2020.tf",
@@ -11,7 +11,7 @@ local kernelsFolder = asset.syncedResource({
local kernelsList = { kernelsFolder .. "p10-a.bsp" }
local Pioneer10NAIF = "-23"
local Pioneer10NAIF = -23
local Pioneer10 = {
Identifier = "Pioneer_10",
@@ -14,7 +14,7 @@ local kernelsList = {
kernelsFolder .. "p11_sat336.bsp"
}
local Pioneer11NAIF = "-24"
local Pioneer11NAIF = -24
local Pioneer11 = {
Identifier = "Pioneer_11",
@@ -21,7 +21,7 @@ local L1Position = {
Transform = {
Translation = {
Type = "SpiceTranslation",
Target = "391", -- L1
Target = 391, -- L1
Observer = "SSB",
Kernels = kernels .. "L1_de431.bsp"
}
@@ -21,7 +21,7 @@ local L2Position = {
Transform = {
Translation = {
Type = "SpiceTranslation",
Target = "392", -- L2
Target = 392, -- L2
Observer = "SSB",
Kernels = kernels .. "L2_de431.bsp"
}
@@ -21,7 +21,7 @@ local L4Position = {
Transform = {
Translation = {
Type = "SpiceTranslation",
Target = "394", -- L4
Target = 394, -- L4
Observer = "SSB",
Kernels = kernels .. "L4_de431.bsp"
}
@@ -21,7 +21,7 @@ local L5Position = {
Transform = {
Translation = {
Type = "SpiceTranslation",
Target = "395", -- L5
Target = 395, -- L5
Observer = "SSB",
Kernels = kernels .. "L5_de431.bsp"
}