Implement production vertical slice foundation
This commit is contained in:
1 parent
9d4a89f355
commit
a18e82eb44
104 files changed
+10595
-268
No files matched your search
@@ -0,0 +1,27 @@
|
||||
class_name SubmarineTelemetryAdapter
|
||||
extends RefCounted
|
||||
|
||||
const VehicleTelemetry = preload("res://game/application/dive/vehicle_telemetry.gd")
|
||||
const SubmarineActor = preload("res://game/world/submarine/submarine_actor.gd")
|
||||
|
||||
var _actor: SubmarineActor
|
||||
|
||||
|
||||
func _init(actor: SubmarineActor) -> void:
|
||||
_actor = actor
|
||||
|
||||
|
||||
func sample(session_id: StringName, sequence: int) -> VehicleTelemetry:
|
||||
return VehicleTelemetry.new(
|
||||
session_id,
|
||||
sequence,
|
||||
_actor.global_position,
|
||||
_actor.global_transform.basis.get_rotation_quaternion(),
|
||||
_actor.velocity,
|
||||
Vector3(0.0, _actor.current_yaw_velocity_rps(), 0.0),
|
||||
_actor.current_depth_m(),
|
||||
_actor.actual_longitudinal_effort(),
|
||||
_actor.actual_steering_effort(),
|
||||
_actor.actual_vertical_effort(),
|
||||
_actor.high_thrust_active()
|
||||
)
|
||||
Reference in new issue
Block a user