Adjust the terrain and fallback camera for bobup trials
Now there are two targets at 15 and 40 feet. The fallback camera has minimal FoV that still shows the instruments.
This commit is contained in:
parent
f6b002c718
commit
0514c64f02
4 changed files with 62 additions and 8 deletions
|
|
@ -24,6 +24,7 @@ transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 2.4, 0)
|
|||
editor_description = "Target position for Local XR tracking"
|
||||
transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0.214, -0.7, 1.594)
|
||||
script = ExtResource("3_gf6ud")
|
||||
use_mouse = false
|
||||
|
||||
[node name="PilotFloor" type="Node3D" parent="AttitudeRoot/PilotEyes"]
|
||||
editor_description = "Required for floor tracking
|
||||
|
|
@ -62,9 +63,11 @@ ignore_time_scale = true
|
|||
|
||||
[node name="FallbackCamera" type="Camera3D" parent="AttitudeRoot/PilotEyes"]
|
||||
transform = Transform3D(1, 0, 0, 0, 0.980955, 0.194234, 0, -0.194234, 0.980955, 0, 0, 0)
|
||||
fov = 60.0
|
||||
|
||||
[node name="Instruments" parent="AttitudeRoot" instance=ExtResource("3_5w717")]
|
||||
transform = Transform3D(-0.5, -1.27582e-08, 7.43353e-08, 4.33325e-10, 0.4923, 0.0874084, -7.5421e-08, 0.0874084, -0.4923, 0.00724897, -1.1581, 2.40391)
|
||||
lidia_hostname = "127.0.0.1"
|
||||
|
||||
[node name="MarshConnector" type="MarshConnector" parent="."]
|
||||
hostname = "192.168.1.2"
|
||||
|
|
|
|||
|
|
@ -8,6 +8,8 @@ const CAMERA_MOUSE_ROTATION_SPEED := 0.001
|
|||
const CAMERA_X_ROT_MIN := deg_to_rad(-85)
|
||||
const CAMERA_X_ROT_MAX := deg_to_rad(70)
|
||||
|
||||
@export var use_mouse: bool = true
|
||||
|
||||
var active: bool = false
|
||||
var initial_rotation: Vector3
|
||||
|
||||
|
|
@ -46,7 +48,7 @@ func _input(event):
|
|||
(float(get_viewport().size.y) / get_viewport().get_visible_rect().size.y)
|
||||
)
|
||||
|
||||
if event is InputEventMouseMotion:
|
||||
if use_mouse and event is InputEventMouseMotion:
|
||||
var camera_speed_this_frame = CAMERA_MOUSE_ROTATION_SPEED
|
||||
rotate_camera(event.relative * camera_speed_this_frame * scale_factor)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue