diff --git a/AVVR/Assets/Prefabs/Complete XR Origin Set Up Variant AVVR.prefab b/AVVR/Assets/Prefabs/Complete XR Origin Set Up Variant AVVR.prefab index 25ce1d3d371e1cf2d5069afbd4a136dfa4b33010..637f32d3200beab617cdcd0f5249897d4410db93 100644 --- a/AVVR/Assets/Prefabs/Complete XR Origin Set Up Variant AVVR.prefab +++ b/AVVR/Assets/Prefabs/Complete XR Origin Set Up Variant AVVR.prefab @@ -1,5 +1,178 @@ %YAML 1.1 %TAG !u! tag:unity3d.com,2011: +--- !u!1 &3595680582673134672 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 4075259292299637730} + - component: {fileID: 5742413650280917386} + m_Layer: 0 + m_Name: DisplayManager + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &4075259292299637730 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3595680582673134672} + serializedVersion: 2 + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 2.5984073, y: 1.3109349, z: -0.265801} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 8298045291338814965} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &5742413650280917386 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3595680582673134672} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f86999510c81f1347962db37765a2031, type: 3} + m_Name: + m_EditorClassIdentifier: + xrCamera: {fileID: 7277802327414017196} + spectatorCamera: {fileID: 7249712585786564757} + useSecondaryWindow: 0 + windowSize: {x: 1920, y: 1080} + windowedMode: 1 +--- !u!1 &5619876154759688209 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 24857229647593761} + - component: {fileID: 7249712585786564757} + - component: {fileID: 3027666375171427404} + - component: {fileID: 5041059882800856174} + m_Layer: 2 + m_Name: Spectator Camera + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &24857229647593761 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5619876154759688209} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 8298045291338814965} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!20 &7249712585786564757 +Camera: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5619876154759688209} + m_Enabled: 1 + serializedVersion: 2 + m_ClearFlags: 1 + m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0} + m_projectionMatrixMode: 1 + m_GateFitMode: 2 + m_FOVAxisMode: 1 + m_Iso: 200 + m_ShutterSpeed: 0.005 + m_Aperture: 16 + m_FocusDistance: 10 + m_FocalLength: 50 + m_BladeCount: 5 + m_Curvature: {x: 2, y: 11} + m_BarrelClipping: 0.25 + m_Anamorphism: 0 + m_SensorSize: {x: 36, y: 24} + m_LensShift: {x: 0, y: 0} + m_NormalizedViewPortRect: + serializedVersion: 2 + x: 0 + y: 0 + width: 1 + height: 1 + near clip plane: 0.01 + far clip plane: 1000 + field of view: 90 + orthographic: 0 + orthographic size: 5 + m_Depth: 0 + m_CullingMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_RenderingPath: -1 + m_TargetTexture: {fileID: 0} + m_TargetDisplay: 0 + m_TargetEye: 3 + m_HDR: 1 + m_AllowMSAA: 1 + m_AllowDynamicResolution: 0 + m_ForceIntoRT: 0 + m_OcclusionCulling: 1 + m_StereoConvergence: 10 + m_StereoSeparation: 0.022 +--- !u!114 &3027666375171427404 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5619876154759688209} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fb47d93d4e6cb45498b98c41d9fc2b4c, type: 3} + m_Name: + m_EditorClassIdentifier: + toggleKey: 283 + enableWindowDrag: 1 + renderResolution: {x: 1920, y: 1080} + minWindowSize: {x: 400, y: 225} + maxWindowSize: {x: 1920, y: 1080} +--- !u!114 &5041059882800856174 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 5619876154759688209} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: eeadcb6c2b1156149b5b7de36c38b5e0, type: 3} + m_Name: + m_EditorClassIdentifier: + xrOrigin: {fileID: 8298045291338814965} + xrCamera: {fileID: 7277802327414017193} + positionOffset: {x: 0, y: 0, z: 0} + rotationOffset: {x: 0, y: 0, z: 0} + positionSmoothTime: 0.15 + rotationSmoothTime: 0.15 + smoothRotation: 1 + smoothPosition: 1 + positionDamping: 0.5 + rotationDamping: 0.5 --- !u!1001 &1865269505668036478 PrefabInstance: m_ObjectHideFlags: 0 @@ -1160,6 +1333,12 @@ PrefabInstance: - targetCorrespondingSourceObject: {fileID: 1717954561962503726, guid: f6336ac4ac8b4d34bc5072418cdc62a0, type: 3} insertIndex: -1 addedObject: {fileID: 536801052177267210} + - targetCorrespondingSourceObject: {fileID: 1717954561962503726, guid: f6336ac4ac8b4d34bc5072418cdc62a0, type: 3} + insertIndex: -1 + addedObject: {fileID: 24857229647593761} + - targetCorrespondingSourceObject: {fileID: 1717954561962503726, guid: f6336ac4ac8b4d34bc5072418cdc62a0, type: 3} + insertIndex: -1 + addedObject: {fileID: 4075259292299637730} - targetCorrespondingSourceObject: {fileID: 1767192434, guid: f6336ac4ac8b4d34bc5072418cdc62a0, type: 3} insertIndex: -1 addedObject: {fileID: 5518899284880179292} @@ -1391,6 +1570,11 @@ MonoBehaviour: z: 0 radius: 0 mProbeBatchesUsed: [] +--- !u!20 &7277802327414017196 stripped +Camera: + m_CorrespondingSourceObject: {fileID: 1767192439, guid: f6336ac4ac8b4d34bc5072418cdc62a0, type: 3} + m_PrefabInstance: {fileID: 7277802326999645147} + m_PrefabAsset: {fileID: 0} --- !u!4 &7277802327528778794 stripped Transform: m_CorrespondingSourceObject: {fileID: 1670256625, guid: f6336ac4ac8b4d34bc5072418cdc62a0, type: 3} diff --git a/AVVR/Assets/Prefabs/InteractableAudioSource.prefab b/AVVR/Assets/Prefabs/InteractableAudioSource.prefab index 33388a426c6abbd3c31dbe91b4d6569078894790..d02681959947df42a6d76ce5bfdd7ba925d9131e 100644 --- a/AVVR/Assets/Prefabs/InteractableAudioSource.prefab +++ b/AVVR/Assets/Prefabs/InteractableAudioSource.prefab @@ -317,7 +317,7 @@ MonoBehaviour: m_StartingInteractionStrengthFilters: [] m_AttachTransform: {fileID: 0} m_SecondaryAttachTransform: {fileID: 0} - m_UseDynamicAttach: 0 + m_UseDynamicAttach: 1 m_MatchAttachPosition: 1 m_MatchAttachRotation: 1 m_SnapToColliderVolume: 1 @@ -378,7 +378,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: m_PermittedDisplacementAxes: -1 - m_ConstrainedAxisDisplacementMode: 1 + m_ConstrainedAxisDisplacementMode: 0 m_TwoHandedRotationMode: 1 m_AllowOneHandedScaling: 1 m_AllowTwoHandedScaling: 0 diff --git a/AVVR/Assets/Scenes/MenuInterface.unity b/AVVR/Assets/Scenes/MenuInterface.unity index d480f501887d37d52a5cf78eef8d83f69c9d90bc..8a2d12acf7b4a2993417058a39101feaf155661d 100644 --- a/AVVR/Assets/Scenes/MenuInterface.unity +++ b/AVVR/Assets/Scenes/MenuInterface.unity @@ -445,6 +445,71 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 83724562} m_CullTransparentMesh: 1 +--- !u!1 &109015360 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 109015361} + - component: {fileID: 109015363} + - component: {fileID: 109015362} + m_Layer: 5 + m_Name: Space + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &109015361 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 109015360} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1386895546} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 2} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &109015362 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 109015360} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: 1 + m_FlexibleHeight: -1 + m_LayoutPriority: 1 +--- !u!222 &109015363 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 109015360} + m_CullTransparentMesh: 1 --- !u!1 &129111067 GameObject: m_ObjectHideFlags: 0 @@ -803,6 +868,7 @@ RectTransform: m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: + - {fileID: 185485304} - {fileID: 1031778498} - {fileID: 1528905251} - {fileID: 815677738} @@ -814,6 +880,7 @@ RectTransform: - {fileID: 129111068} - {fileID: 8423873864886031584} - {fileID: 235670128} + - {fileID: 1386895546} m_Father: {fileID: 1743335630} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 1} @@ -869,6 +936,111 @@ MonoBehaviour: m_EditorClassIdentifier: m_HorizontalFit: 0 m_VerticalFit: 2 +--- !u!1 &185485303 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 185485304} + - component: {fileID: 185485307} + - component: {fileID: 185485306} + - component: {fileID: 185485305} + m_Layer: 5 + m_Name: WindowTooltip + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &185485304 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 185485303} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 340990967} + - {fileID: 1926803190} + - {fileID: 1959041095} + m_Father: {fileID: 170541293} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 50} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &185485305 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 185485303} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 30649d3a9faa99c48a7b1166b86bf2a0, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 10 + m_Right: 10 + m_Top: 10 + m_Bottom: 10 + m_ChildAlignment: 4 + m_Spacing: 10 + m_ChildForceExpandWidth: 0 + m_ChildForceExpandHeight: 1 + m_ChildControlWidth: 1 + m_ChildControlHeight: 0 + m_ChildScaleWidth: 0 + m_ChildScaleHeight: 0 + m_ReverseArrangement: 0 +--- !u!114 &185485306 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 185485303} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &185485307 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 185485303} + m_CullTransparentMesh: 1 --- !u!1 &185566786 GameObject: m_ObjectHideFlags: 0 @@ -1856,6 +2028,102 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 308177624} m_CullTransparentMesh: 1 +--- !u!1 &340990966 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 340990967} + - component: {fileID: 340990970} + - component: {fileID: 340990969} + - component: {fileID: 340990968} + m_Layer: 5 + m_Name: Line + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &340990967 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 340990966} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 185485304} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 2} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &340990968 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 340990966} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: 1 + m_FlexibleHeight: -1 + m_LayoutPriority: 1 +--- !u!114 &340990969 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 340990966} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &340990970 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 340990966} + m_CullTransparentMesh: 1 --- !u!1 &359808176 GameObject: m_ObjectHideFlags: 0 @@ -2980,7 +3248,7 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 938156552} m_CullTransparentMesh: 1 ---- !u!1 &965513161 +--- !u!1 &957139425 GameObject: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -2988,42 +3256,45 @@ GameObject: m_PrefabAsset: {fileID: 0} serializedVersion: 6 m_Component: - - component: {fileID: 965513162} - - component: {fileID: 965513164} - - component: {fileID: 965513163} + - component: {fileID: 957139426} + - component: {fileID: 957139430} + - component: {fileID: 957139429} + - component: {fileID: 957139428} + - component: {fileID: 957139427} m_Layer: 5 - m_Name: Space + m_Name: Button m_TagString: Untagged m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 m_IsActive: 1 ---- !u!224 &965513162 +--- !u!224 &957139426 RectTransform: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 965513161} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_GameObject: {fileID: 957139425} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 - m_Children: [] - m_Father: {fileID: 235670128} + m_Children: + - {fileID: 1134820289} + m_Father: {fileID: 1386895546} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} m_AnchoredPosition: {x: 0, y: 0} - m_SizeDelta: {x: 0, y: 2} + m_SizeDelta: {x: 0, y: 30} m_Pivot: {x: 0.5, y: 0.5} ---- !u!114 &965513163 +--- !u!114 &957139427 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 965513161} + m_GameObject: {fileID: 957139425} m_Enabled: 1 m_EditorHideFlags: 0 m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3} @@ -3032,21 +3303,172 @@ MonoBehaviour: m_IgnoreLayout: 0 m_MinWidth: -1 m_MinHeight: -1 - m_PreferredWidth: -1 + m_PreferredWidth: 120 m_PreferredHeight: -1 - m_FlexibleWidth: 1 + m_FlexibleWidth: -1 m_FlexibleHeight: -1 m_LayoutPriority: 1 ---- !u!222 &965513164 -CanvasRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 965513161} - m_CullTransparentMesh: 1 ---- !u!1 &1031778497 -GameObject: +--- !u!114 &957139428 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 957139425} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Navigation: + m_Mode: 3 + m_WrapAround: 0 + m_SelectOnUp: {fileID: 0} + m_SelectOnDown: {fileID: 0} + m_SelectOnLeft: {fileID: 0} + m_SelectOnRight: {fileID: 0} + m_Transition: 1 + m_Colors: + m_NormalColor: {r: 1, g: 1, b: 1, a: 1} + m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1} + m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} + m_SelectedColor: {r: 1, g: 1, b: 1, a: 1} + m_DisabledColor: {r: 0.5019608, g: 0.5019608, b: 0.5019608, a: 0.5019608} + m_ColorMultiplier: 1 + m_FadeDuration: 0.1 + m_SpriteState: + m_HighlightedSprite: {fileID: 0} + m_PressedSprite: {fileID: 0} + m_SelectedSprite: {fileID: 0} + m_DisabledSprite: {fileID: 0} + m_AnimationTriggers: + m_NormalTrigger: Normal + m_HighlightedTrigger: Highlighted + m_PressedTrigger: Pressed + m_SelectedTrigger: Selected + m_DisabledTrigger: Disabled + m_Interactable: 1 + m_TargetGraphic: {fileID: 957139429} + m_OnClick: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1386895551} + m_TargetAssemblyTypeName: QuitApplication, Assembly-CSharp + m_MethodName: QuitApp + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 +--- !u!114 &957139429 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 957139425} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0} + m_Type: 1 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &957139430 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 957139425} + m_CullTransparentMesh: 1 +--- !u!1 &965513161 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 965513162} + - component: {fileID: 965513164} + - component: {fileID: 965513163} + m_Layer: 5 + m_Name: Space + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &965513162 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 965513161} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 235670128} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 2} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &965513163 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 965513161} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: 1 + m_FlexibleHeight: -1 + m_LayoutPriority: 1 +--- !u!222 &965513164 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 965513161} + m_CullTransparentMesh: 1 +--- !u!1 &1031778497 +GameObject: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} @@ -3240,6 +3662,140 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: m_ShowMaskGraphic: 0 +--- !u!1 &1134820288 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1134820289} + - component: {fileID: 1134820291} + - component: {fileID: 1134820290} + m_Layer: 5 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1134820289 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1134820288} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 957139426} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0.5, y: 0.5} + m_AnchorMax: {x: 0.5, y: 0.5} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 200, y: 50} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1134820290 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1134820288} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: QUIT + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 2e498d1c8094910479dc3e1b768306a4, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 2e498d1c8094910479dc3e1b768306a4, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: + serializedVersion: 2 + rgba: 4278190335 + m_fontColor: {r: 1, g: 0, b: 0, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: 97690656 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 14 + m_fontSizeBase: 14 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 1 + m_HorizontalAlignment: 2 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 0 + m_wordWrappingRatios: 0.4 + m_overflowMode: 1 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!222 &1134820291 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1134820288} + m_CullTransparentMesh: 1 --- !u!1 &1145799603 GameObject: m_ObjectHideFlags: 0 @@ -4567,6 +5123,124 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1366789779} m_CullTransparentMesh: 1 +--- !u!1 &1386895545 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1386895546} + - component: {fileID: 1386895550} + - component: {fileID: 1386895549} + - component: {fileID: 1386895548} + - component: {fileID: 1386895551} + m_Layer: 5 + m_Name: QuitButton + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1386895546 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1386895545} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 109015361} + - {fileID: 957139426} + - {fileID: 1522653215} + m_Father: {fileID: 170541293} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 50} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1386895548 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1386895545} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 30649d3a9faa99c48a7b1166b86bf2a0, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Padding: + m_Left: 10 + m_Right: 10 + m_Top: 10 + m_Bottom: 10 + m_ChildAlignment: 4 + m_Spacing: 10 + m_ChildForceExpandWidth: 0 + m_ChildForceExpandHeight: 1 + m_ChildControlWidth: 1 + m_ChildControlHeight: 0 + m_ChildScaleWidth: 0 + m_ChildScaleHeight: 0 + m_ReverseArrangement: 0 +--- !u!114 &1386895549 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1386895545} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 0} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1386895550 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1386895545} + m_CullTransparentMesh: 1 +--- !u!114 &1386895551 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1386895545} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c76c1fc4dacdf7149b0c0342b2bc35cb, type: 3} + m_Name: + m_EditorClassIdentifier: --- !u!1 &1415786478 GameObject: m_ObjectHideFlags: 0 @@ -4943,7 +5617,72 @@ CanvasRenderer: m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1515933024} + m_GameObject: {fileID: 1515933024} + m_CullTransparentMesh: 1 +--- !u!1 &1522653214 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1522653215} + - component: {fileID: 1522653217} + - component: {fileID: 1522653216} + m_Layer: 5 + m_Name: Space + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1522653215 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1522653214} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1386895546} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 2} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1522653216 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1522653214} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: 1 + m_FlexibleHeight: -1 + m_LayoutPriority: 1 +--- !u!222 &1522653217 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1522653214} m_CullTransparentMesh: 1 --- !u!224 &1528905251 stripped RectTransform: @@ -6367,6 +7106,257 @@ RectTransform: m_AnchoredPosition: {x: 0, y: 0} m_SizeDelta: {x: 0, y: 28} m_Pivot: {x: 0.5, y: 1} +--- !u!1 &1926803189 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1926803190} + - component: {fileID: 1926803193} + - component: {fileID: 1926803192} + - component: {fileID: 1926803191} + m_Layer: 5 + m_Name: Title + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1926803190 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1926803189} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 185485304} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 30} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1926803191 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1926803189} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_text: Press F2 to toggle VR stabilised camera view window. + m_isRightToLeft: 0 + m_fontAsset: {fileID: 11400000, guid: 2e498d1c8094910479dc3e1b768306a4, type: 2} + m_sharedMaterial: {fileID: 2180264, guid: 2e498d1c8094910479dc3e1b768306a4, type: 2} + m_fontSharedMaterials: [] + m_fontMaterial: {fileID: 0} + m_fontMaterials: [] + m_fontColor32: + serializedVersion: 2 + rgba: 4278190080 + m_fontColor: {r: 0, g: 0, b: 0, a: 1} + m_enableVertexGradient: 0 + m_colorMode: 3 + m_fontColorGradient: + topLeft: {r: 1, g: 1, b: 1, a: 1} + topRight: {r: 1, g: 1, b: 1, a: 1} + bottomLeft: {r: 1, g: 1, b: 1, a: 1} + bottomRight: {r: 1, g: 1, b: 1, a: 1} + m_fontColorGradientPreset: {fileID: 0} + m_spriteAsset: {fileID: 0} + m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: -1183493901 + m_overrideHtmlColors: 0 + m_faceColor: + serializedVersion: 2 + rgba: 4294967295 + m_fontSize: 20 + m_fontSizeBase: 20 + m_fontWeight: 400 + m_enableAutoSizing: 0 + m_fontSizeMin: 18 + m_fontSizeMax: 72 + m_fontStyle: 0 + m_HorizontalAlignment: 2 + m_VerticalAlignment: 512 + m_textAlignment: 65535 + m_characterSpacing: 0 + m_wordSpacing: 0 + m_lineSpacing: 0 + m_lineSpacingMax: 0 + m_paragraphSpacing: 0 + m_charWidthMaxAdj: 0 + m_enableWordWrapping: 0 + m_wordWrappingRatios: 0.4 + m_overflowMode: 1 + m_linkedTextComponent: {fileID: 0} + parentLinkedComponent: {fileID: 0} + m_enableKerning: 1 + m_enableExtraPadding: 0 + checkPaddingRequired: 0 + m_isRichText: 1 + m_parseCtrlCharacters: 1 + m_isOrthographic: 1 + m_isCullingEnabled: 0 + m_horizontalMapping: 0 + m_verticalMapping: 0 + m_uvLineOffset: 0 + m_geometrySortingOrder: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 + m_useMaxVisibleDescender: 1 + m_pageToDisplay: 1 + m_margin: {x: 0, y: 0, z: 0, w: 0} + m_isUsingLegacyAnimationComponent: 0 + m_isVolumetricText: 0 + m_hasFontAssetChanged: 0 + m_baseMaterial: {fileID: 0} + m_maskOffset: {x: 0, y: 0, z: 0, w: 0} +--- !u!114 &1926803192 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1926803189} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: -1 + m_FlexibleHeight: -1 + m_LayoutPriority: 1 +--- !u!222 &1926803193 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1926803189} + m_CullTransparentMesh: 1 +--- !u!1 &1959041094 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1959041095} + - component: {fileID: 1959041098} + - component: {fileID: 1959041097} + - component: {fileID: 1959041096} + m_Layer: 5 + m_Name: Line + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1959041095 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1959041094} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 185485304} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 2} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1959041096 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1959041094} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreLayout: 0 + m_MinWidth: -1 + m_MinHeight: -1 + m_PreferredWidth: -1 + m_PreferredHeight: -1 + m_FlexibleWidth: 1 + m_FlexibleHeight: -1 + m_LayoutPriority: 1 +--- !u!114 &1959041097 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1959041094} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 0, g: 0, b: 0, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 0} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1959041098 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1959041094} + m_CullTransparentMesh: 1 --- !u!1 &2044274854 GameObject: m_ObjectHideFlags: 0 diff --git a/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/LR_NoVR.unity b/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/LR_NoVR.unity index f1e5db54c4e9cc63b856908910701307dc0d94b5..a20daa067fb2a40b591bc7578209dd6cba024d1f 100644 --- a/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/LR_NoVR.unity +++ b/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/LR_NoVR.unity @@ -149,7 +149,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 7324637061791894319, guid: e8704b2cb89ef5f4c900ad41600ea441, type: 3} propertyPath: m_LocalRotation.w - value: 1 + value: 0 objectReference: {fileID: 0} - target: {fileID: 7324637061791894319, guid: e8704b2cb89ef5f4c900ad41600ea441, type: 3} propertyPath: m_LocalRotation.x @@ -157,7 +157,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 7324637061791894319, guid: e8704b2cb89ef5f4c900ad41600ea441, type: 3} propertyPath: m_LocalRotation.y - value: 0 + value: 1 objectReference: {fileID: 0} - target: {fileID: 7324637061791894319, guid: e8704b2cb89ef5f4c900ad41600ea441, type: 3} propertyPath: m_LocalRotation.z @@ -169,7 +169,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 7324637061791894319, guid: e8704b2cb89ef5f4c900ad41600ea441, type: 3} propertyPath: m_LocalEulerAnglesHint.y - value: 0 + value: 180 objectReference: {fileID: 0} - target: {fileID: 7324637061791894319, guid: e8704b2cb89ef5f4c900ad41600ea441, type: 3} propertyPath: m_LocalEulerAnglesHint.z diff --git a/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/ST_NoVR.unity b/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/ST_NoVR.unity index 4a541482ee068ab9082e0e9eb057f31573f632ee..098358d2ff133bc350be2fd9387af80545161e65 100644 --- a/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/ST_NoVR.unity +++ b/AVVR/Assets/Scenes/SteamAudioScenes/Subjective-Evaluation-Scenes/ST_NoVR.unity @@ -372,13 +372,14 @@ Material: m_Parent: {fileID: 0} m_ModifiedSerializedProperties: 0 m_ValidKeywords: - - _ALPHABLEND_ON + - _ALPHAPREMULTIPLY_ON m_InvalidKeywords: [] m_LightmapFlags: 4 m_EnableInstancingVariants: 0 m_DoubleSidedGI: 0 m_CustomRenderQueue: 2999 - stringTagMap: {} + stringTagMap: + RenderType: Transparent disabledShaderPasses: [] m_LockedProperties: m_SavedProperties: @@ -434,9 +435,9 @@ Material: - _Parallax: 0.02 - _SmoothnessTextureChannel: 0 - _SpecularHighlights: 1 - - _SrcBlend: 5 + - _SrcBlend: 1 - _UVSec: 0 - - _ZWrite: 1 + - _ZWrite: 0 m_Colors: - _Color: {r: 0, g: 0, b: 0.784314, a: 0.5} - _EmissionColor: {r: 0.05, g: 0.05, b: 0.05, a: 1} @@ -454,13 +455,14 @@ Material: m_Parent: {fileID: 0} m_ModifiedSerializedProperties: 0 m_ValidKeywords: - - _ALPHABLEND_ON + - _ALPHAPREMULTIPLY_ON m_InvalidKeywords: [] m_LightmapFlags: 4 m_EnableInstancingVariants: 0 m_DoubleSidedGI: 0 m_CustomRenderQueue: 2999 - stringTagMap: {} + stringTagMap: + RenderType: Transparent disabledShaderPasses: [] m_LockedProperties: m_SavedProperties: @@ -516,9 +518,9 @@ Material: - _Parallax: 0.02 - _SmoothnessTextureChannel: 0 - _SpecularHighlights: 1 - - _SrcBlend: 5 + - _SrcBlend: 1 - _UVSec: 0 - - _ZWrite: 1 + - _ZWrite: 0 m_Colors: - _Color: {r: 0, g: 0, b: 0, a: 0.5} - _EmissionColor: {r: 0.05, g: 0.05, b: 0.05, a: 1} @@ -823,13 +825,14 @@ Material: m_Parent: {fileID: 0} m_ModifiedSerializedProperties: 0 m_ValidKeywords: - - _ALPHABLEND_ON + - _ALPHAPREMULTIPLY_ON m_InvalidKeywords: [] m_LightmapFlags: 4 m_EnableInstancingVariants: 0 m_DoubleSidedGI: 0 m_CustomRenderQueue: 2999 - stringTagMap: {} + stringTagMap: + RenderType: Transparent disabledShaderPasses: [] m_LockedProperties: m_SavedProperties: @@ -885,9 +888,9 @@ Material: - _Parallax: 0.02 - _SmoothnessTextureChannel: 0 - _SpecularHighlights: 1 - - _SrcBlend: 5 + - _SrcBlend: 1 - _UVSec: 0 - - _ZWrite: 1 + - _ZWrite: 0 m_Colors: - _Color: {r: 0.81568605, g: 0.807843, b: 0.28235298, a: 0.5} - _EmissionColor: {r: 0.05, g: 0.05, b: 0.05, a: 1} @@ -1193,7 +1196,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 759189137} serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0.7071068, z: 0, w: -0.7071068} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: -0, z: 0} m_LocalScale: {x: 2.67, y: 3.125, z: 2.93} m_ConstrainProportionsScale: 0 @@ -1335,13 +1338,14 @@ Material: m_Parent: {fileID: 0} m_ModifiedSerializedProperties: 0 m_ValidKeywords: - - _ALPHABLEND_ON + - _ALPHAPREMULTIPLY_ON m_InvalidKeywords: [] m_LightmapFlags: 4 m_EnableInstancingVariants: 0 m_DoubleSidedGI: 0 m_CustomRenderQueue: 2999 - stringTagMap: {} + stringTagMap: + RenderType: Transparent disabledShaderPasses: [] m_LockedProperties: m_SavedProperties: @@ -1397,9 +1401,9 @@ Material: - _Parallax: 0.02 - _SmoothnessTextureChannel: 0 - _SpecularHighlights: 1 - - _SrcBlend: 5 + - _SrcBlend: 1 - _UVSec: 0 - - _ZWrite: 1 + - _ZWrite: 0 m_Colors: - _Color: {r: 0.39999998, g: 0.39999998, b: 0.39999998, a: 0.5} - _EmissionColor: {r: 0.05, g: 0.05, b: 0.05, a: 1} @@ -2305,13 +2309,14 @@ Material: m_Parent: {fileID: 0} m_ModifiedSerializedProperties: 0 m_ValidKeywords: - - _ALPHABLEND_ON + - _ALPHAPREMULTIPLY_ON m_InvalidKeywords: [] m_LightmapFlags: 4 m_EnableInstancingVariants: 0 m_DoubleSidedGI: 0 m_CustomRenderQueue: 2999 - stringTagMap: {} + stringTagMap: + RenderType: Transparent disabledShaderPasses: [] m_LockedProperties: m_SavedProperties: @@ -2367,9 +2372,9 @@ Material: - _Parallax: 0.02 - _SmoothnessTextureChannel: 0 - _SpecularHighlights: 1 - - _SrcBlend: 5 + - _SrcBlend: 1 - _UVSec: 0 - - _ZWrite: 1 + - _ZWrite: 0 m_Colors: - _Color: {r: 0.733333, g: 0.505882, b: 0.61176497, a: 0.5} - _EmissionColor: {r: 0.05, g: 0.05, b: 0.05, a: 1} @@ -2900,11 +2905,11 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 7285903358191246061, guid: b530b1bba69907248a498d576cd552e1, type: 3} propertyPath: m_LocalPosition.z - value: -3.278 + value: 2.069 objectReference: {fileID: 0} - target: {fileID: 7285903358191246061, guid: b530b1bba69907248a498d576cd552e1, type: 3} propertyPath: m_LocalRotation.w - value: 1 + value: 0 objectReference: {fileID: 0} - target: {fileID: 7285903358191246061, guid: b530b1bba69907248a498d576cd552e1, type: 3} propertyPath: m_LocalRotation.x @@ -2912,7 +2917,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 7285903358191246061, guid: b530b1bba69907248a498d576cd552e1, type: 3} propertyPath: m_LocalRotation.y - value: 0 + value: 1 objectReference: {fileID: 0} - target: {fileID: 7285903358191246061, guid: b530b1bba69907248a498d576cd552e1, type: 3} propertyPath: m_LocalRotation.z @@ -2924,7 +2929,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 7285903358191246061, guid: b530b1bba69907248a498d576cd552e1, type: 3} propertyPath: m_LocalEulerAnglesHint.y - value: 0 + value: 180 objectReference: {fileID: 0} - target: {fileID: 7285903358191246061, guid: b530b1bba69907248a498d576cd552e1, type: 3} propertyPath: m_LocalEulerAnglesHint.z @@ -3059,13 +3064,14 @@ Material: m_Parent: {fileID: 0} m_ModifiedSerializedProperties: 0 m_ValidKeywords: - - _ALPHABLEND_ON + - _ALPHAPREMULTIPLY_ON m_InvalidKeywords: [] m_LightmapFlags: 4 m_EnableInstancingVariants: 0 m_DoubleSidedGI: 0 m_CustomRenderQueue: 2999 - stringTagMap: {} + stringTagMap: + RenderType: Transparent disabledShaderPasses: [] m_LockedProperties: m_SavedProperties: @@ -3121,9 +3127,9 @@ Material: - _Parallax: 0.02 - _SmoothnessTextureChannel: 0 - _SpecularHighlights: 1 - - _SrcBlend: 5 + - _SrcBlend: 1 - _UVSec: 0 - - _ZWrite: 1 + - _ZWrite: 0 m_Colors: - _Color: {r: 0.36078396, g: 0.521569, b: 0.466667, a: 0.5} - _EmissionColor: {r: 0.05, g: 0.05, b: 0.05, a: 1} diff --git a/AVVR/Assets/_Scripts/DisplayManager.cs b/AVVR/Assets/_Scripts/DisplayManager.cs new file mode 100644 index 0000000000000000000000000000000000000000..43d1893061a7b436fe85110e10942078465fa811 --- /dev/null +++ b/AVVR/Assets/_Scripts/DisplayManager.cs @@ -0,0 +1,73 @@ +using UnityEngine; +using UnityEngine.XR; +using System.Linq; + +public class DisplayManager : MonoBehaviour +{ + [Header("Camera References")] + [SerializeField] private Camera xrCamera; + [SerializeField] private Camera spectatorCamera; + + [Header("Display Settings")] + [SerializeField] private bool useSecondaryWindow = false; + [SerializeField] private Vector2Int windowSize = new Vector2Int(1920, 1080); + [SerializeField] private bool windowedMode = true; + + private void Start() + { + if (xrCamera == null || spectatorCamera == null) + { + Debug.LogError("Camera references not set in Display Manager!"); + return; + } + + SetupDisplays(); + } + + private void SetupDisplays() + { + // Configure XR Camera + xrCamera.targetDisplay = 0; // VR Display + + if (useSecondaryWindow) + { + CreateSecondaryWindow(); + } + else + { + // Use main display for spectator view + spectatorCamera.targetDisplay = 0; + xrCamera.depth = 0; + spectatorCamera.depth = 1; // Ensure spectator camera renders over XR camera on desktop + } + + // Set up spectator camera to not render to the VR display + spectatorCamera.stereoTargetEye = StereoTargetEyeMask.None; + } + + private void CreateSecondaryWindow() + { +#if UNITY_STANDALONE_WIN || UNITY_EDITOR + // Create a secondary window + if (!UnityEngine.Display.displays.Any(d => d.active && d != UnityEngine.Display.main)) + { + if (UnityEngine.Display.displays.Length > 1) + { + UnityEngine.Display.displays[1].Activate(); + spectatorCamera.targetDisplay = 1; + } + } +#endif + } + +#if UNITY_EDITOR + [UnityEditor.MenuItem("Window/Create Game View 2")] + public static void CreateSecondGameView() + { + var assembly = typeof(UnityEditor.EditorWindow).Assembly; + var gameViewType = assembly.GetType("UnityEditor.GameView"); + var gameView = UnityEditor.EditorWindow.GetWindow(gameViewType, false, "Game (Spectator)", true); + gameView.Show(); + } +#endif +} \ No newline at end of file diff --git a/AVVR/Assets/_Scripts/DisplayManager.cs.meta b/AVVR/Assets/_Scripts/DisplayManager.cs.meta new file mode 100644 index 0000000000000000000000000000000000000000..103f9f24522ee950ffb241391bab6268d410dff8 --- /dev/null +++ b/AVVR/Assets/_Scripts/DisplayManager.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: f86999510c81f1347962db37765a2031 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/AVVR/Assets/_Scripts/MenuInterface/QuitApplication.cs b/AVVR/Assets/_Scripts/MenuInterface/QuitApplication.cs new file mode 100644 index 0000000000000000000000000000000000000000..603ad79be984d7782d8da343ab22c1cb60fc7139 --- /dev/null +++ b/AVVR/Assets/_Scripts/MenuInterface/QuitApplication.cs @@ -0,0 +1,13 @@ +using UnityEngine; + +public class QuitApplication : MonoBehaviour +{ + public void QuitApp() + { + #if UNITY_EDITOR + UnityEditor.EditorApplication.isPlaying = false; + #else + Application.Quit(); + #endif + } +} \ No newline at end of file diff --git a/AVVR/Assets/_Scripts/MenuInterface/QuitApplication.cs.meta b/AVVR/Assets/_Scripts/MenuInterface/QuitApplication.cs.meta new file mode 100644 index 0000000000000000000000000000000000000000..34140219770e4c51640021f6afcf5c78981aa4eb --- /dev/null +++ b/AVVR/Assets/_Scripts/MenuInterface/QuitApplication.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c76c1fc4dacdf7149b0c0342b2bc35cb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/AVVR/Assets/_Scripts/SpectatorCamera.cs b/AVVR/Assets/_Scripts/SpectatorCamera.cs new file mode 100644 index 0000000000000000000000000000000000000000..e92e5733e64cc0673f1ca42f1de1a338c8651e02 --- /dev/null +++ b/AVVR/Assets/_Scripts/SpectatorCamera.cs @@ -0,0 +1,130 @@ +using UnityEngine; +using UnityEngine.XR; + +[RequireComponent(typeof(Camera))] +public class SpectatorCamera : MonoBehaviour +{ + [Header("Target Settings")] + [SerializeField] private Transform xrOrigin; + [SerializeField] private Transform xrCamera; + [SerializeField] private Vector3 positionOffset = Vector3.zero; + [SerializeField] private Vector3 rotationOffset = Vector3.zero; + + [Header("Smoothing")] + [SerializeField] private float positionSmoothTime = 0.15f; + [SerializeField] private float rotationSmoothTime = 0.15f; + [SerializeField] private bool smoothRotation = true; + [SerializeField] private bool smoothPosition = true; + + [Header("Damping")] + [Range(0f, 1f)] + [SerializeField] private float positionDamping = 0.5f; + [Range(0f, 1f)] + [SerializeField] private float rotationDamping = 0.5f; + + // Internal tracking variables + private Vector3 currentVelocity; + private Vector3 currentAngularVelocity; + private Vector3 targetPosition; + private Quaternion targetRotation; + + private void Start() + { + if (xrOrigin == null || xrCamera == null) + { + Debug.LogError("XR Origin or Camera reference not set in Spectator Camera!"); + enabled = false; + return; + } + + // Initialize position and rotation + transform.position = xrCamera.position + xrCamera.TransformDirection(positionOffset); + transform.rotation = xrCamera.rotation * Quaternion.Euler(rotationOffset); + } + + private void LateUpdate() + { + UpdateTargetTransform(); + SmoothlyFollowTarget(); + } + + private void UpdateTargetTransform() + { + // Match XR camera position exactly + targetPosition = xrCamera.position; + + // Match XR camera rotation exactly + targetRotation = xrCamera.rotation; + } + + private void SmoothlyFollowTarget() + { + if (smoothPosition) + { + // Smooth position following + transform.position = Vector3.SmoothDamp( + transform.position, + targetPosition, + ref currentVelocity, + positionSmoothTime, + Mathf.Infinity, + Time.deltaTime + ); + } + else + { + transform.position = targetPosition; + } + + if (smoothRotation) + { + // Smooth rotation following + transform.rotation = SmoothDampQuaternion( + transform.rotation, + targetRotation, + ref currentAngularVelocity, + rotationSmoothTime + ); + } + else + { + transform.rotation = targetRotation; + } + } + + // Custom quaternion smooth damp function + private Quaternion SmoothDampQuaternion(Quaternion current, Quaternion target, ref Vector3 currentVelocity, float smoothTime) + { + Vector3 currentEuler = current.eulerAngles; + Vector3 targetEuler = target.eulerAngles; + + // Ensure we rotate the shortest path + float deltaX = Mathf.DeltaAngle(currentEuler.x, targetEuler.x); + float deltaY = Mathf.DeltaAngle(currentEuler.y, targetEuler.y); + float deltaZ = Mathf.DeltaAngle(currentEuler.z, targetEuler.z); + + Vector3 targetAngles = currentEuler + new Vector3(deltaX, deltaY, deltaZ); + + Vector3 smoothedEuler = Vector3.SmoothDamp( + currentEuler, + targetAngles, + ref currentVelocity, + smoothTime, + Mathf.Infinity, + Time.deltaTime + ); + + return Quaternion.Euler(smoothedEuler); + } + + // Editor gizmos for visualization + private void OnDrawGizmosSelected() + { + if (xrCamera != null) + { + Gizmos.color = Color.green; + Gizmos.DrawWireSphere(xrCamera.position + xrCamera.TransformDirection(positionOffset), 0.1f); + Gizmos.DrawLine(xrCamera.position, xrCamera.position + xrCamera.TransformDirection(positionOffset)); + } + } +} \ No newline at end of file diff --git a/AVVR/Assets/_Scripts/SpectatorCamera.cs.meta b/AVVR/Assets/_Scripts/SpectatorCamera.cs.meta new file mode 100644 index 0000000000000000000000000000000000000000..b8a14c9508fc35bb92013ca76adb01186d02899e --- /dev/null +++ b/AVVR/Assets/_Scripts/SpectatorCamera.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: eeadcb6c2b1156149b5b7de36c38b5e0 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/AVVR/Assets/_Scripts/SpectatorWindow.cs b/AVVR/Assets/_Scripts/SpectatorWindow.cs new file mode 100644 index 0000000000000000000000000000000000000000..a10aa7710183e3f717a36452663e92306ecb159c --- /dev/null +++ b/AVVR/Assets/_Scripts/SpectatorWindow.cs @@ -0,0 +1,194 @@ +using UnityEngine; + +public class SpectatorWindow : MonoBehaviour +{ + private static SpectatorWindow instance; + private Camera spectatorCam; + private RenderTexture renderTexture; + private bool showWindow = true; + [SerializeField] private KeyCode toggleKey = KeyCode.Tab; + private Rect windowRect; + + private void Start() + { + // Set initial window size + float windowWidth = 400; + float windowHeight = 225; + + // Calculate position for bottom right + float xPos = Screen.width - windowWidth - 20; // 20 pixels padding from right + float yPos = Screen.height - windowHeight - 40; // 40 pixels padding from bottom for taskbar etc + + // Initialize window rectangle + windowRect = new Rect(xPos, yPos, windowWidth, windowHeight); + } + + [Header("Window Settings")] + [SerializeField] private bool enableWindowDrag = true; + [SerializeField] private Vector2Int renderResolution = new Vector2Int(1920, 1080); + [SerializeField] private Vector2 minWindowSize = new Vector2(400, 225); + [SerializeField] private Vector2 maxWindowSize = new Vector2(1920, 1080); + + private bool isResizing = false; + private Rect resizeHandleRect; + private Vector2 resizeStartMouse; + private Vector2 resizeStartSize; + private readonly float resizeHandleSize = 20f; + + private void Awake() + { + if (instance == null) + { + instance = this; + DontDestroyOnLoad(gameObject); + } + else + { + Destroy(gameObject); + return; + } + + spectatorCam = GetComponent<Camera>(); + if (spectatorCam == null) + { + Debug.LogError("No camera attached to Stabilised View Window!"); + return; + } + + InitializeRenderTexture(); + } + + private void InitializeRenderTexture() + { + renderTexture = new RenderTexture(renderResolution.x, renderResolution.y, 24); + renderTexture.antiAliasing = 4; + spectatorCam.targetTexture = renderTexture; + } + + private void Update() + { + // Check for key press to toggle window + if (Input.GetKeyDown(toggleKey)) + { + showWindow = !showWindow; + } + } + + private void OnGUI() + { + if (!showWindow) return; + + // Create a solid background style + var backgroundStyle = new GUIStyle(GUI.skin.window); + var tex = new Texture2D(1, 1); + tex.SetPixel(0, 0, new Color(0.2f, 0.2f, 0.2f, 1f)); + tex.Apply(); + backgroundStyle.normal.background = tex; + + // Draw the window with solid background + GUI.backgroundColor = Color.black; + windowRect = GUI.Window(0, windowRect, DrawWindowContents, "Stabilised View", backgroundStyle); + + // Handle resizing outside of the window function + HandleResizing(); + } + + private void DrawWindowContents(int windowID) + { + // Draw black background for render texture area + GUI.Box(new Rect(0, 20, windowRect.width, windowRect.height - 20), ""); + + // Draw the render texture + GUI.DrawTexture(new Rect(0, 20, windowRect.width, windowRect.height - 20), renderTexture); + + // Close button + if (GUI.Button(new Rect(windowRect.width - 25, 2, 20, 16), "X")) + { + showWindow = false; + } + + // Draw resize handle (visual indicator) + resizeHandleRect = new Rect(windowRect.width - resizeHandleSize, + windowRect.height - resizeHandleSize, + resizeHandleSize, resizeHandleSize); + + GUI.Box(resizeHandleRect, "↘"); + + // Window dragging (only if not resizing) + if (enableWindowDrag && !isResizing) + { + GUI.DragWindow(new Rect(0, 0, windowRect.width - resizeHandleSize, 20)); + } + } + + private void HandleResizing() + { + // Convert resize handle to screen coordinates + Rect screenResizeRect = new Rect( + windowRect.x + windowRect.width - resizeHandleSize, + windowRect.y + windowRect.height - resizeHandleSize, + resizeHandleSize, + resizeHandleSize + ); + + Event e = Event.current; + if (e.type == EventType.MouseDown && e.button == 0 && screenResizeRect.Contains(e.mousePosition)) + { + isResizing = true; + resizeStartMouse = e.mousePosition; + resizeStartSize = new Vector2(windowRect.width, windowRect.height); + e.Use(); + } + else if (e.type == EventType.MouseUp && e.button == 0) + { + isResizing = false; + } + else if (isResizing && e.type == EventType.MouseDrag) + { + // Calculate new size + float newWidth = Mathf.Clamp(resizeStartSize.x + (e.mousePosition.x - resizeStartMouse.x), + minWindowSize.x, maxWindowSize.x); + float newHeight = Mathf.Clamp(resizeStartSize.y + (e.mousePosition.y - resizeStartMouse.y), + minWindowSize.y, maxWindowSize.y); + + // Maintain aspect ratio (16:9) + float targetAspect = 16f / 9f; + float currentAspect = newWidth / newHeight; + + if (currentAspect > targetAspect) + { + newWidth = newHeight * targetAspect; + } + else + { + newHeight = newWidth / targetAspect; + } + + // Apply new size + windowRect.width = newWidth; + windowRect.height = newHeight; + + e.Use(); + } + } + + private void OnDestroy() + { + if (renderTexture != null) + { + renderTexture.Release(); + Destroy(renderTexture); + } + } + + // Public methods + public void ShowWindow() => showWindow = true; + public void HideWindow() => showWindow = false; + public void ToggleWindow() => showWindow = !showWindow; + + public void SetWindowSize(float width, float height) + { + windowRect.width = Mathf.Clamp(width, minWindowSize.x, maxWindowSize.x); + windowRect.height = Mathf.Clamp(height, minWindowSize.y, maxWindowSize.y); + } +} \ No newline at end of file diff --git a/AVVR/Assets/_Scripts/SpectatorWindow.cs.meta b/AVVR/Assets/_Scripts/SpectatorWindow.cs.meta new file mode 100644 index 0000000000000000000000000000000000000000..8748a508e55a6baab2a649a79c0c97037f7e0d58 --- /dev/null +++ b/AVVR/Assets/_Scripts/SpectatorWindow.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: fb47d93d4e6cb45498b98c41d9fc2b4c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: