mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-02-22 04:49:12 -06:00
Rename bind_keys.lua script file to bind_common_keys.lua
Move SPICE kernel declaration from osirisrex.scene into the osirisrex mod file
This commit is contained in:
20
scripts/bind_common_keys.lua
Normal file
20
scripts/bind_common_keys.lua
Normal file
@@ -0,0 +1,20 @@
|
||||
--[[ OpenSpace keybinding script ]]--
|
||||
|
||||
-- Load the common helper functions
|
||||
dofile(openspace.absPath('${SCRIPTS}/common.lua'))
|
||||
|
||||
openspace.clearKeys()
|
||||
helper.setCommonKeys()
|
||||
helper.setDeltaTimeKeys({
|
||||
-- 1 2 3 4 5 6 7 8 9 0
|
||||
--------------------------------------------------------------------------------------------------------------------------
|
||||
-- 1s 2s 5s 10s 30s 1m 2m 5m 10m 30m
|
||||
1, 2, 5, 10, 30, 60, 120, 300, 600, 1800,
|
||||
|
||||
-- 1h 2h 3h 6h 12h 1d 2d 4d 1w 2w
|
||||
3600, 7200, 10800, 21600, 43200, 86400, 172800, 345600, 604800, 1209600,
|
||||
|
||||
-- 1mo 2mo 3mo 6mo 1yr 2y 5y 10y 20y 50y
|
||||
2592000, 5184000, 7776000, 15552000, 31536000, 63072000, 157680000, 315360000, 630720000, 1576800000
|
||||
})
|
||||
-- OBS: One month (1mo) is approximated by 30 days.
|
||||
@@ -1,20 +0,0 @@
|
||||
--[[ OpenSpace keybinding script ]]--
|
||||
|
||||
-- Load the common helper functions
|
||||
dofile(openspace.absPath('${SCRIPTS}/common.lua'))
|
||||
|
||||
openspace.clearKeys()
|
||||
helper.setCommonKeys()
|
||||
helper.setDeltaTimeKeys({
|
||||
-- 1 2 3 4 5 6 7 8 9 0
|
||||
--------------------------------------------------------------------------------------------------------------------------
|
||||
-- 1s 2s 5s 10s 30s 1m 2m 5m 10m 30 min
|
||||
1, 2, 5, 10, 30, 60, 120, 300, 600, 1800,
|
||||
|
||||
-- 1h 2h 3h 6h 12h 1d 2d 4d 1w 2w
|
||||
3600, 7200, 10800, 21600, 43200, 86400, 172800, 345600, 604800, 1209600,
|
||||
|
||||
-- 1mo 2mo 3mo 6mo 1yr 2y 5y 10y 20y 50y
|
||||
2592000, 5184000, 7776000, 15552000, 31536000, 63072000, 157680000, 315360000, 630720000, 1576800000
|
||||
})
|
||||
-- OBS: One month (1mo) is approximated by 30 days.
|
||||
@@ -1,11 +1,10 @@
|
||||
--[[ OpenSpace keybinding script ]]--
|
||||
--[[ OpenSpace keybinding script loaded from the newhorizons.scene file ]]--
|
||||
|
||||
-- Load the common helper functions
|
||||
dofile(openspace.absPath('${SCRIPTS}/common.lua'))
|
||||
|
||||
openspace.clearKeys()
|
||||
helper.setCommonKeys()
|
||||
|
||||
helper.setDeltaTimeKeys({
|
||||
1, 5, 10, 20, 40, 60, 120, 360, 540, 1080,
|
||||
2160, 4320, 8640
|
||||
|
||||
@@ -1,19 +1,17 @@
|
||||
--[[ OpenSpace keybinding script ]]--
|
||||
--[[ OpenSpace keybinding script loaded from the osirisrex.scene file ]]--
|
||||
|
||||
-- Load the common helper functions
|
||||
dofile(openspace.absPath('${SCRIPTS}/common.lua'))
|
||||
|
||||
--openspace.clearKeys()
|
||||
--helper.setCommonKeys()
|
||||
dofile(openspace.absPath('${SCRIPTS}/bind_common_keys.lua'))
|
||||
|
||||
-- Set focuses
|
||||
openspace.bindKey(
|
||||
"o",
|
||||
"a",
|
||||
"openspace.setPropertyValue('Interaction.origin', 'OsirisRex')",
|
||||
"Sets the focus of the camera on 'Osiris Rex'."
|
||||
)
|
||||
openspace.bindKey(
|
||||
"b",
|
||||
"s",
|
||||
"openspace.setPropertyValue('Interaction.origin', 'BennuBarycenter')",
|
||||
"Sets the focus of the camera on 'Bennu'."
|
||||
)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
--[[ OpenSpace keybinding script ]]--
|
||||
--[[ OpenSpace keybinding script loaded from the rosetta.scene file ]]--
|
||||
-- This script sets the default keybindings and is executed at startup
|
||||
|
||||
-- Load the common helper functions
|
||||
|
||||
Reference in New Issue
Block a user