mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-04-24 13:08:49 -05:00
7d480552a9
* Added all trail toggle * Added actions for trails and planets/moons * Added planet lighting assetd; updated action paths * Add mars layers actions * Added new layers from Carter * Cleaned up trail action names, cleaned up some default keybindings Co-authored-by: Alexander Bock <mail@alexanderbock.eu>
28 lines
650 B
Lua
28 lines
650 B
Lua
local action = asset.require("actions/trails/toggle_trail")
|
|
|
|
asset.onInitialize(function()
|
|
openspace.event.registerEventAction(
|
|
"CameraFocusTransition",
|
|
action.show_trail,
|
|
{ Transition = "Exiting" }
|
|
)
|
|
openspace.event.registerEventAction(
|
|
"CameraFocusTransition",
|
|
action.hide_trail,
|
|
{ Transition = "Approaching" }
|
|
)
|
|
end)
|
|
|
|
asset.onDeinitialize(function()
|
|
openspace.event.unregisterEventAction(
|
|
"CameraFocusTransition",
|
|
action.show_trail,
|
|
{ Transition = "Exiting" }
|
|
)
|
|
openspace.event.unregisterEventAction(
|
|
"CameraFocusTransition",
|
|
action.hide_trail,
|
|
{ Transition = "Approaching" }
|
|
)
|
|
end)
|