Cleaned up and commented version.
This commit is contained in:
+2
-1
@@ -1,5 +1,6 @@
|
|||||||
fileFormatVersion: 2
|
fileFormatVersion: 2
|
||||||
guid: 78e36c78dac19c5479c35bbdcd23c65b
|
guid: 9df4708a6ce320b4099bc35a2184d44e
|
||||||
|
folderAsset: yes
|
||||||
DefaultImporter:
|
DefaultImporter:
|
||||||
externalObjects: {}
|
externalObjects: {}
|
||||||
userData:
|
userData:
|
||||||
@@ -1,845 +0,0 @@
|
|||||||
%YAML 1.1
|
|
||||||
%TAG !u! tag:unity3d.com,2011:
|
|
||||||
--- !u!29 &1
|
|
||||||
OcclusionCullingSettings:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
serializedVersion: 2
|
|
||||||
m_OcclusionBakeSettings:
|
|
||||||
smallestOccluder: 5
|
|
||||||
smallestHole: 0.25
|
|
||||||
backfaceThreshold: 100
|
|
||||||
m_SceneGUID: 00000000000000000000000000000000
|
|
||||||
m_OcclusionCullingData: {fileID: 0}
|
|
||||||
--- !u!104 &2
|
|
||||||
RenderSettings:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
serializedVersion: 10
|
|
||||||
m_Fog: 0
|
|
||||||
m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1}
|
|
||||||
m_FogMode: 3
|
|
||||||
m_FogDensity: 0.01
|
|
||||||
m_LinearFogStart: 0
|
|
||||||
m_LinearFogEnd: 300
|
|
||||||
m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1}
|
|
||||||
m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1}
|
|
||||||
m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1}
|
|
||||||
m_AmbientIntensity: 1
|
|
||||||
m_AmbientMode: 0
|
|
||||||
m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1}
|
|
||||||
m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0}
|
|
||||||
m_HaloStrength: 0.5
|
|
||||||
m_FlareStrength: 1
|
|
||||||
m_FlareFadeSpeed: 3
|
|
||||||
m_HaloTexture: {fileID: 0}
|
|
||||||
m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0}
|
|
||||||
m_DefaultReflectionMode: 0
|
|
||||||
m_DefaultReflectionResolution: 128
|
|
||||||
m_ReflectionBounces: 1
|
|
||||||
m_ReflectionIntensity: 1
|
|
||||||
m_CustomReflection: {fileID: 0}
|
|
||||||
m_Sun: {fileID: 0}
|
|
||||||
m_UseRadianceAmbientProbe: 0
|
|
||||||
--- !u!157 &3
|
|
||||||
LightmapSettings:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
serializedVersion: 13
|
|
||||||
m_BakeOnSceneLoad: 0
|
|
||||||
m_GISettings:
|
|
||||||
serializedVersion: 2
|
|
||||||
m_BounceScale: 1
|
|
||||||
m_IndirectOutputScale: 1
|
|
||||||
m_AlbedoBoost: 1
|
|
||||||
m_EnvironmentLightingMode: 0
|
|
||||||
m_EnableBakedLightmaps: 1
|
|
||||||
m_EnableRealtimeLightmaps: 0
|
|
||||||
m_LightmapEditorSettings:
|
|
||||||
serializedVersion: 12
|
|
||||||
m_Resolution: 2
|
|
||||||
m_BakeResolution: 40
|
|
||||||
m_AtlasSize: 1024
|
|
||||||
m_AO: 0
|
|
||||||
m_AOMaxDistance: 1
|
|
||||||
m_CompAOExponent: 1
|
|
||||||
m_CompAOExponentDirect: 0
|
|
||||||
m_ExtractAmbientOcclusion: 0
|
|
||||||
m_Padding: 2
|
|
||||||
m_LightmapParameters: {fileID: 0}
|
|
||||||
m_LightmapsBakeMode: 1
|
|
||||||
m_TextureCompression: 1
|
|
||||||
m_ReflectionCompression: 2
|
|
||||||
m_MixedBakeMode: 2
|
|
||||||
m_BakeBackend: 1
|
|
||||||
m_PVRSampling: 1
|
|
||||||
m_PVRDirectSampleCount: 32
|
|
||||||
m_PVRSampleCount: 512
|
|
||||||
m_PVRBounces: 2
|
|
||||||
m_PVREnvironmentSampleCount: 256
|
|
||||||
m_PVREnvironmentReferencePointCount: 2048
|
|
||||||
m_PVRFilteringMode: 1
|
|
||||||
m_PVRDenoiserTypeDirect: 1
|
|
||||||
m_PVRDenoiserTypeIndirect: 1
|
|
||||||
m_PVRDenoiserTypeAO: 1
|
|
||||||
m_PVRFilterTypeDirect: 0
|
|
||||||
m_PVRFilterTypeIndirect: 0
|
|
||||||
m_PVRFilterTypeAO: 0
|
|
||||||
m_PVREnvironmentMIS: 1
|
|
||||||
m_PVRCulling: 1
|
|
||||||
m_PVRFilteringGaussRadiusDirect: 1
|
|
||||||
m_PVRFilteringGaussRadiusIndirect: 1
|
|
||||||
m_PVRFilteringGaussRadiusAO: 1
|
|
||||||
m_PVRFilteringAtrousPositionSigmaDirect: 0.5
|
|
||||||
m_PVRFilteringAtrousPositionSigmaIndirect: 2
|
|
||||||
m_PVRFilteringAtrousPositionSigmaAO: 1
|
|
||||||
m_ExportTrainingData: 0
|
|
||||||
m_TrainingDataDestination: TrainingData
|
|
||||||
m_LightProbeSampleCountMultiplier: 4
|
|
||||||
m_LightingDataAsset: {fileID: 20201, guid: 0000000000000000f000000000000000, type: 0}
|
|
||||||
m_LightingSettings: {fileID: 0}
|
|
||||||
--- !u!196 &4
|
|
||||||
NavMeshSettings:
|
|
||||||
serializedVersion: 2
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_BuildSettings:
|
|
||||||
serializedVersion: 3
|
|
||||||
agentTypeID: 0
|
|
||||||
agentRadius: 0.5
|
|
||||||
agentHeight: 2
|
|
||||||
agentSlope: 45
|
|
||||||
agentClimb: 0.4
|
|
||||||
ledgeDropHeight: 0
|
|
||||||
maxJumpAcrossDistance: 0
|
|
||||||
minRegionArea: 2
|
|
||||||
manualCellSize: 0
|
|
||||||
cellSize: 0.16666667
|
|
||||||
manualTileSize: 0
|
|
||||||
tileSize: 256
|
|
||||||
buildHeightMesh: 0
|
|
||||||
maxJobWorkers: 0
|
|
||||||
preserveTilesOutsideBounds: 0
|
|
||||||
debug:
|
|
||||||
m_Flags: 0
|
|
||||||
m_NavMeshData: {fileID: 0}
|
|
||||||
--- !u!1 &1039256585
|
|
||||||
GameObject:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
serializedVersion: 6
|
|
||||||
m_Component:
|
|
||||||
- component: {fileID: 1039256589}
|
|
||||||
- component: {fileID: 1039256588}
|
|
||||||
- component: {fileID: 1039256587}
|
|
||||||
- component: {fileID: 1039256586}
|
|
||||||
- component: {fileID: 1039256590}
|
|
||||||
- component: {fileID: 1039256591}
|
|
||||||
m_Layer: 1
|
|
||||||
m_Name: Plane
|
|
||||||
m_TagString: Untagged
|
|
||||||
m_Icon: {fileID: 0}
|
|
||||||
m_NavMeshLayer: 0
|
|
||||||
m_StaticEditorFlags: 0
|
|
||||||
m_IsActive: 1
|
|
||||||
--- !u!64 &1039256586
|
|
||||||
MeshCollider:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1039256585}
|
|
||||||
m_Material: {fileID: 0}
|
|
||||||
m_IncludeLayers:
|
|
||||||
serializedVersion: 2
|
|
||||||
m_Bits: 0
|
|
||||||
m_ExcludeLayers:
|
|
||||||
serializedVersion: 2
|
|
||||||
m_Bits: 0
|
|
||||||
m_LayerOverridePriority: 0
|
|
||||||
m_IsTrigger: 0
|
|
||||||
m_ProvidesContacts: 0
|
|
||||||
m_Enabled: 1
|
|
||||||
serializedVersion: 5
|
|
||||||
m_Convex: 0
|
|
||||||
m_CookingOptions: 30
|
|
||||||
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
|
|
||||||
--- !u!23 &1039256587
|
|
||||||
MeshRenderer:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1039256585}
|
|
||||||
m_Enabled: 1
|
|
||||||
m_CastShadows: 1
|
|
||||||
m_ReceiveShadows: 1
|
|
||||||
m_DynamicOccludee: 1
|
|
||||||
m_StaticShadowCaster: 0
|
|
||||||
m_MotionVectors: 1
|
|
||||||
m_LightProbeUsage: 1
|
|
||||||
m_ReflectionProbeUsage: 1
|
|
||||||
m_RayTracingMode: 2
|
|
||||||
m_RayTraceProcedural: 0
|
|
||||||
m_RayTracingAccelStructBuildFlagsOverride: 0
|
|
||||||
m_RayTracingAccelStructBuildFlags: 1
|
|
||||||
m_SmallMeshCulling: 1
|
|
||||||
m_RenderingLayerMask: 1
|
|
||||||
m_RendererPriority: 0
|
|
||||||
m_Materials:
|
|
||||||
- {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, type: 2}
|
|
||||||
m_StaticBatchInfo:
|
|
||||||
firstSubMesh: 0
|
|
||||||
subMeshCount: 0
|
|
||||||
m_StaticBatchRoot: {fileID: 0}
|
|
||||||
m_ProbeAnchor: {fileID: 0}
|
|
||||||
m_LightProbeVolumeOverride: {fileID: 0}
|
|
||||||
m_ScaleInLightmap: 1
|
|
||||||
m_ReceiveGI: 1
|
|
||||||
m_PreserveUVs: 0
|
|
||||||
m_IgnoreNormalsForChartDetection: 0
|
|
||||||
m_ImportantGI: 0
|
|
||||||
m_StitchLightmapSeams: 1
|
|
||||||
m_SelectedEditorRenderState: 3
|
|
||||||
m_MinimumChartSize: 4
|
|
||||||
m_AutoUVMaxDistance: 0.5
|
|
||||||
m_AutoUVMaxAngle: 89
|
|
||||||
m_LightmapParameters: {fileID: 0}
|
|
||||||
m_SortingLayerID: 0
|
|
||||||
m_SortingLayer: 0
|
|
||||||
m_SortingOrder: 0
|
|
||||||
m_AdditionalVertexStreams: {fileID: 0}
|
|
||||||
--- !u!33 &1039256588
|
|
||||||
MeshFilter:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1039256585}
|
|
||||||
m_Mesh: {fileID: 10209, guid: 0000000000000000e000000000000000, type: 0}
|
|
||||||
--- !u!4 &1039256589
|
|
||||||
Transform:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1039256585}
|
|
||||||
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: 0}
|
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
|
||||||
--- !u!114 &1039256590
|
|
||||||
MonoBehaviour:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1039256585}
|
|
||||||
m_Enabled: 0
|
|
||||||
m_EditorHideFlags: 0
|
|
||||||
m_Script: {fileID: 11500000, guid: 2a414e41b5eb32f489ad37f31d24a9d0, type: 3}
|
|
||||||
m_Name:
|
|
||||||
m_EditorClassIdentifier:
|
|
||||||
--- !u!114 &1039256591
|
|
||||||
MonoBehaviour:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_CorrespondingSourceObject: {fileID: 0}
|
|
||||||
m_PrefabInstance: {fileID: 0}
|
|
||||||
m_PrefabAsset: {fileID: 0}
|
|
||||||
m_GameObject: {fileID: 1039256585}
|
|
||||||
m_Enabled: 1
|
|
||||||
m_EditorHideFlags: 0
|
|
||||||
m_Script: {fileID: 11500000, guid: 8983945cca89adc46aab1638d1823d76, type: 3}
|
|
||||||
m_Name:
|
|
||||||
m_EditorClassIdentifier:
|
|
||||||
textbox: {fileID: 0}
|
|
||||||
--- !u!1001 &1203254197
|
|
||||||
PrefabInstance:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
serializedVersion: 2
|
|
||||||
m_Modification:
|
|
||||||
serializedVersion: 3
|
|
||||||
m_TransformParent: {fileID: 0}
|
|
||||||
m_Modifications:
|
|
||||||
- target: {fileID: 454586362093781695, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 80
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 454586362093781695, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 454586363013833002, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 454586363013833002, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 454586363013833002, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 42.21
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 454586363013833002, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 40
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 454586363013833002, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 711874375355372565, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 711874375355372565, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 711874375355372565, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 2
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 827336434697486484, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 827336434697486484, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 827336434697486484, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 2
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 827336434697486484, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -272
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2096087249121209608, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 242
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2372364542277592973, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 91.78
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2372364542277592973, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2372364542531027992, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2372364542531027992, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2372364542531027992, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 63.78
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2372364542531027992, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 45.89
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2372364542531027992, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2509200301365282504, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2509200301365282504, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2509200301365282504, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 2
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2509200301365282504, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -136
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 3503166844991407117, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: offlinePosition.z
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 3577501535338948537, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.x
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 3577501535338948537, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6299181119493716916, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6299181119493716916, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6299181119493716916, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 36.8
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6299181119493716916, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 40
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6299181119493716916, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6299181120315349025, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 80
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6299181120315349025, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6666687303926437473, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6666687303926437473, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6666687303926437473, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 2
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 6666687303926437473, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -68
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7020043307626416877, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 80
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7020043307626416877, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7020043308476213624, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7020043308476213624, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7020043308476213624, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 42.01
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7020043308476213624, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 40
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7020043308476213624, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7600416357546044615, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7600416357546044615, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7600416357546044615, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 62.76
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7600416357546044615, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 45.379997
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7600416357546044615, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7600416357936713554, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 90.759995
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7600416357936713554, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7622460198587092014, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7622460198587092014, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7622460198587092014, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 36.8
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7622460198587092014, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 40
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7622460198587092014, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7622460199406481339, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 80
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 7622460199406481339, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8268635517507059789, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8268635517507059789, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8268635517507059789, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 142
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8268635517507059789, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -30
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8324656376034772630, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8324656376034772630, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8324656376034772630, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 26
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8324656376034772630, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -30
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8460637990670501396, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 90.759995
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8460637990670501396, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8460637990827091329, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8460637990827091329, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8460637990827091329, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 62.76
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8460637990827091329, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 45.379997
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8460637990827091329, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8585990886882328085, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 3
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalPosition.x
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalPosition.y
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalPosition.z
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.w
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.x
|
|
||||||
value: -0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.y
|
|
||||||
value: -0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.z
|
|
||||||
value: -0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalEulerAnglesHint.x
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalEulerAnglesHint.y
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291108, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalEulerAnglesHint.z
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291111, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_Name
|
|
||||||
value: XR Interaction Setup (MP Variant)
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8716202226868291111, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_IsActive
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8798636447145251062, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8798636447145251062, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8798636447145251062, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 82.3
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8798636447145251062, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 55.15
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8798636447145251062, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -23
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8798636447962674019, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.x
|
|
||||||
value: 110.3
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 8798636447962674019, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_SizeDelta.y
|
|
||||||
value: 46
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 9050835495748891254, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMax.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 9050835495748891254, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchorMin.y
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 9050835495748891254, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.x
|
|
||||||
value: 2
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 9050835495748891254, guid: 0387ad92654f0bf44b203a53c628c88f,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_AnchoredPosition.y
|
|
||||||
value: -204
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
m_RemovedComponents: []
|
|
||||||
m_RemovedGameObjects: []
|
|
||||||
m_AddedGameObjects: []
|
|
||||||
m_AddedComponents: []
|
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 0387ad92654f0bf44b203a53c628c88f, type: 3}
|
|
||||||
--- !u!1001 &1393516242
|
|
||||||
PrefabInstance:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
serializedVersion: 2
|
|
||||||
m_Modification:
|
|
||||||
serializedVersion: 3
|
|
||||||
m_TransformParent: {fileID: 0}
|
|
||||||
m_Modifications:
|
|
||||||
- target: {fileID: 2982427928418703695, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_Name
|
|
||||||
value: OVRCameraRig Variant
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalPosition.x
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalPosition.y
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalPosition.z
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.w
|
|
||||||
value: 1
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.x
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.y
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalRotation.z
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalEulerAnglesHint.x
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalEulerAnglesHint.y
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
- target: {fileID: 2982427928418993519, guid: 114dd0e59d4d3744d995722c429f5f25,
|
|
||||||
type: 3}
|
|
||||||
propertyPath: m_LocalEulerAnglesHint.z
|
|
||||||
value: 0
|
|
||||||
objectReference: {fileID: 0}
|
|
||||||
m_RemovedComponents: []
|
|
||||||
m_RemovedGameObjects: []
|
|
||||||
m_AddedGameObjects: []
|
|
||||||
m_AddedComponents: []
|
|
||||||
m_SourcePrefab: {fileID: 100100000, guid: 114dd0e59d4d3744d995722c429f5f25, type: 3}
|
|
||||||
--- !u!1660057539 &9223372036854775807
|
|
||||||
SceneRoots:
|
|
||||||
m_ObjectHideFlags: 0
|
|
||||||
m_Roots:
|
|
||||||
- {fileID: 1203254197}
|
|
||||||
- {fileID: 1039256589}
|
|
||||||
- {fileID: 1393516242}
|
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: d67b41fbba345214fb891de28190331c
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -9322,10 +9322,10 @@ RectTransform:
|
|||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 2045408655}
|
m_Father: {fileID: 2045408655}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 1}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 0, y: 1}
|
m_AnchorMax: {x: 0, y: 0}
|
||||||
m_AnchoredPosition: {x: 186, y: -150.7}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 372, y: 30}
|
m_SizeDelta: {x: 0, y: 30}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &1566043034
|
--- !u!114 &1566043034
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
@@ -10511,10 +10511,10 @@ RectTransform:
|
|||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 2045408655}
|
m_Father: {fileID: 2045408655}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 1}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 0, y: 1}
|
m_AnchorMax: {x: 0, y: 0}
|
||||||
m_AnchoredPosition: {x: 186, y: -103.7}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 372, y: 50}
|
m_SizeDelta: {x: 0, y: 50}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &1797910565
|
--- !u!114 &1797910565
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
@@ -11078,10 +11078,10 @@ RectTransform:
|
|||||||
m_Children: []
|
m_Children: []
|
||||||
m_Father: {fileID: 2045408655}
|
m_Father: {fileID: 2045408655}
|
||||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||||
m_AnchorMin: {x: 0, y: 1}
|
m_AnchorMin: {x: 0, y: 0}
|
||||||
m_AnchorMax: {x: 0, y: 1}
|
m_AnchorMax: {x: 0, y: 0}
|
||||||
m_AnchoredPosition: {x: 186, y: -35.85}
|
m_AnchoredPosition: {x: 0, y: 0}
|
||||||
m_SizeDelta: {x: 372, y: 71.7}
|
m_SizeDelta: {x: 0, y: 71.7}
|
||||||
m_Pivot: {x: 0.5, y: 0.5}
|
m_Pivot: {x: 0.5, y: 0.5}
|
||||||
--- !u!114 &1864973021
|
--- !u!114 &1864973021
|
||||||
MonoBehaviour:
|
MonoBehaviour:
|
||||||
|
|||||||
@@ -3,6 +3,8 @@ using System.Collections;
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Ein Scriptable Object zum speichern der Raumeigenschaften. Wird jeder Trainings-Szene zugeordnet und beim Hinzuladen einer neuen Szene ausgelesen.
|
||||||
|
|
||||||
[CreateAssetMenu]
|
[CreateAssetMenu]
|
||||||
public class RoomPrefs : ScriptableObject
|
public class RoomPrefs : ScriptableObject
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -3,6 +3,8 @@ using GhostSystem;
|
|||||||
using NUnit.Framework;
|
using NUnit.Framework;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Dieses Script übernimmt die eigentliche Auswertung des Eyetrackings per Raycast.
|
||||||
|
|
||||||
public class EyeTrackingCollisionPoints : MonoBehaviour
|
public class EyeTrackingCollisionPoints : MonoBehaviour
|
||||||
{
|
{
|
||||||
[SerializeField]
|
[SerializeField]
|
||||||
@@ -25,13 +27,14 @@ public class EyeTrackingCollisionPoints : MonoBehaviour
|
|||||||
|
|
||||||
Vector3 rayCastDirection = transform.TransformDirection(Vector3.forward) * rayDistance;
|
Vector3 rayCastDirection = transform.TransformDirection(Vector3.forward) * rayDistance;
|
||||||
|
|
||||||
if ( hitPoint != null && Physics.Raycast(transform.position, rayCastDirection, out hit, rayDistance, gazableLayers))
|
if ( hitPoint != null && Physics.Raycast(transform.position, rayCastDirection, out hit, rayDistance, gazableLayers)) // Sendet einen Raycast in Blickrichtung aus.
|
||||||
{
|
{
|
||||||
hitPoint.transform.position = new Vector3(hit.point.x, hit.point.y, hit.point.z);
|
hitPoint.transform.position = new Vector3(hit.point.x, hit.point.y, hit.point.z); // Wenn ein Objekt mit der passenden Layer Mask getroffen wurde, wird der Gazepoint
|
||||||
if (heatIsActive)
|
// in der Visualisierung auf die entsprechende Kollisionsposition gesetzt.
|
||||||
|
if (heatIsActive) // Ist die Heat-Visualisierung (rote Färbung der Target-Objekte) aktiviert,
|
||||||
{
|
{
|
||||||
FindVisibleTargets(hitPoint.transform.position);
|
FindVisibleTargets(hitPoint.transform.position); // wird noch einmal mit einem Radius von 20 cm im Umfeld des Hitpoints nach
|
||||||
}
|
} // Objekten gesucht, die gefärbt werden können.
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -50,7 +53,7 @@ public class EyeTrackingCollisionPoints : MonoBehaviour
|
|||||||
GameObject hitObject = col.gameObject;
|
GameObject hitObject = col.gameObject;
|
||||||
if (hitObject.GetComponent<RecieveHeat>() != null)
|
if (hitObject.GetComponent<RecieveHeat>() != null)
|
||||||
{
|
{
|
||||||
hitObject.GetComponent<RecieveHeat>().AddHeat(0.02f);
|
hitObject.GetComponent<RecieveHeat>().AddHeat(0.02f); // Jedes Mal, wenn ein passendes Objekt getroffen wird, wird desen Heat-Wert um 0,02 erhöht.
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Dieses Script ist für die Darstellung des fovealen und peripheren Sichtfelds im Replay zuständig.
|
||||||
|
|
||||||
public class FieldOfView : MonoBehaviour
|
public class FieldOfView : MonoBehaviour
|
||||||
{
|
{
|
||||||
public float viewRadius;
|
public float viewRadius;
|
||||||
@@ -27,7 +29,7 @@ public class FieldOfView : MonoBehaviour
|
|||||||
private Mesh periMesh;
|
private Mesh periMesh;
|
||||||
private Mesh foveaMesh;
|
private Mesh foveaMesh;
|
||||||
|
|
||||||
private void Start()
|
private void Start() // zum Start werden zwei neune Meshes generiert, um die Sichtfelder darstellen zu können.
|
||||||
{
|
{
|
||||||
periMesh = new Mesh();
|
periMesh = new Mesh();
|
||||||
periMesh.name = "View Mesh";
|
periMesh.name = "View Mesh";
|
||||||
@@ -40,11 +42,11 @@ public class FieldOfView : MonoBehaviour
|
|||||||
|
|
||||||
private void LateUpdate()
|
private void LateUpdate()
|
||||||
{
|
{
|
||||||
Vector3 gazeDirection = ((eyeLeft.forward + eyeRight.forward) * 0.5f).normalized;
|
Vector3 gazeDirection = ((eyeLeft.forward + eyeRight.forward) * 0.5f).normalized; // In jedem Frame wird zuerst die gemeinsame Blickrichtung der beiden Augen ermittelt.
|
||||||
eyeCenter.rotation = Quaternion.LookRotation(gazeDirection);
|
eyeCenter.rotation = Quaternion.LookRotation(gazeDirection);
|
||||||
float gazeAngle = AngleFromDir(gazeDirection, true);
|
float gazeAngle = AngleFromDir(gazeDirection, true);
|
||||||
DrawFOV(transform.eulerAngles.y, periMesh, periAngle);
|
DrawFOV(transform.eulerAngles.y, periMesh, periAngle); // Das Mesh für das periphere Sichtfeld wird im angegebenen Winkel um die Vorwärts-Achse generiert.
|
||||||
DrawFOV(gazeAngle, foveaMesh, foveaAngle);
|
DrawFOV(gazeAngle, foveaMesh, foveaAngle); // Das Mesh für das foveale Sichtfeld wird im angegebenen Winkel um die Sichtlinie herum generiert.
|
||||||
}
|
}
|
||||||
|
|
||||||
public Vector3 DirFromAngle(float angleDeg, bool angleIsGlobal)
|
public Vector3 DirFromAngle(float angleDeg, bool angleIsGlobal)
|
||||||
@@ -76,9 +78,9 @@ public class FieldOfView : MonoBehaviour
|
|||||||
return (angleDeg + 360f) % 360f;
|
return (angleDeg + 360f) % 360f;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DrawFOV(float startAngle, Mesh viewMesh, float viewAngle)
|
void DrawFOV(float startAngle, Mesh viewMesh, float viewAngle) // Die Funktion, die das eigentliche 3D-Objekt/Mesh generiert.
|
||||||
{
|
{
|
||||||
int stepCount = Mathf.RoundToInt(viewAngle * meshResolution);
|
int stepCount = Mathf.RoundToInt(viewAngle * meshResolution); // Es werden mit der angegebenen Auflösung Winkel für die Unterteilungen des Sichtfelds bestimmt.
|
||||||
float stepAngleSize = viewAngle / stepCount;
|
float stepAngleSize = viewAngle / stepCount;
|
||||||
List<Vector3> viewPoints = new List<Vector3>();
|
List<Vector3> viewPoints = new List<Vector3>();
|
||||||
ViewCastInfo oldViewCast = new ViewCastInfo();
|
ViewCastInfo oldViewCast = new ViewCastInfo();
|
||||||
@@ -87,12 +89,12 @@ public class FieldOfView : MonoBehaviour
|
|||||||
{
|
{
|
||||||
float angle = startAngle - viewAngle / 2 + stepAngleSize * i;
|
float angle = startAngle - viewAngle / 2 + stepAngleSize * i;
|
||||||
|
|
||||||
Debug.DrawLine(transform.position, transform.position + DirFromAngle(angle, true) * viewRadius, Color.red);
|
Debug.DrawLine(transform.position, transform.position + DirFromAngle(angle, true) * viewRadius, Color.red); // diese werden zu Debug-Zwecken im Viewport visualisiert.
|
||||||
|
|
||||||
ViewCastInfo newViewCast = ViewCast(angle);
|
ViewCastInfo newViewCast = ViewCast(angle); // Nun werden auf diesen Positionen Raycasts ausgesand und geguckt, ob diese ein Hindernis treffen.
|
||||||
|
|
||||||
if (i > 0)
|
if (i > 0) // Trifft ein Strahl ein Objekt und der nächste nicht, wird der Abstand zum nächsten Strakhl so lange halbiert, bis beide das Objekt treffen.
|
||||||
{
|
{ // So kann das Mesh des Sichtfelds so gebaut werden, dass die durch hindernisse nicht sichtbaren Bereiche genau ausgeschnitten werden.
|
||||||
bool edgeDistThresholdExeeded = Mathf.Abs(oldViewCast.distance - newViewCast.distance) > edgeDistanceThreshold;
|
bool edgeDistThresholdExeeded = Mathf.Abs(oldViewCast.distance - newViewCast.distance) > edgeDistanceThreshold;
|
||||||
if (oldViewCast.didHit != newViewCast.didHit || (oldViewCast.didHit && newViewCast.didHit && edgeDistThresholdExeeded))
|
if (oldViewCast.didHit != newViewCast.didHit || (oldViewCast.didHit && newViewCast.didHit && edgeDistThresholdExeeded))
|
||||||
{
|
{
|
||||||
@@ -113,11 +115,11 @@ public class FieldOfView : MonoBehaviour
|
|||||||
|
|
||||||
int vertexcount = viewPoints.Count + 1;
|
int vertexcount = viewPoints.Count + 1;
|
||||||
Vector3[] vertices = new Vector3[vertexcount];
|
Vector3[] vertices = new Vector3[vertexcount];
|
||||||
int[] triangles = new int[(vertexcount-2) * 3];
|
int[] triangles = new int[(vertexcount-2) * 3];
|
||||||
|
|
||||||
vertices[0] = Vector3.zero;
|
vertices[0] = Vector3.zero;
|
||||||
|
|
||||||
for (int i = 0; i < vertexcount-1; i++)
|
for (int i = 0; i < vertexcount-1; i++) // Schließlich werden zwischen allen Punkten Dreiecke aufgespannt, sodass ein Mesh/3D-Objekt entsteht.
|
||||||
{
|
{
|
||||||
vertices[i+1] = transform.InverseTransformPoint(viewPoints[i]);
|
vertices[i+1] = transform.InverseTransformPoint(viewPoints[i]);
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 65730a9e8bad9b840bc940e9491e98b4
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -4,6 +4,8 @@ using UnityEngine;
|
|||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using System;
|
using System;
|
||||||
|
|
||||||
|
// Die Klasse FrameModel stellt das Gerüst für die Daten dar, die über den SupabaseManager an die Datenbank gesenden und von dort empfangen werden.
|
||||||
|
|
||||||
namespace GhostSystem
|
namespace GhostSystem
|
||||||
{
|
{
|
||||||
[Table("object_positions")]
|
[Table("object_positions")]
|
||||||
|
|||||||
@@ -7,14 +7,16 @@ using System;
|
|||||||
using Oculus.Interaction;
|
using Oculus.Interaction;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
|
||||||
|
// Dieses Script ist für die Aufnahme des Replays während des Trainingsdurchlaufs zuständig.
|
||||||
|
|
||||||
namespace GhostSystem
|
namespace GhostSystem
|
||||||
{
|
{
|
||||||
public class GhostRecorderBatch : MonoBehaviour
|
public class GhostRecorderBatch : MonoBehaviour
|
||||||
{
|
{
|
||||||
public string SceneId;
|
public string SceneId; // SceneID zum Übergeben des Raumnamens an die Datenbank.
|
||||||
public float SampleRate = 0.05f;
|
public float SampleRate = 0.05f; // Entspricht einer Framerate von 20 FPS.
|
||||||
public int BatchSize = 10;
|
public int BatchSize = 10; // Anzahl der Frames nach denen ein neuer Batch beginnt. Wird nicht mehr genutzt, da manueller Flush.
|
||||||
public float FlushInterval = 2f;
|
public float FlushInterval = 2f; // Länge des Intervalls bis zum nächsten Flush. Wird nicht mehr genutzt, da manueller Flush.
|
||||||
|
|
||||||
public List<Transform> TrackedObjects;
|
public List<Transform> TrackedObjects;
|
||||||
private int doorCount;
|
private int doorCount;
|
||||||
@@ -41,8 +43,8 @@ namespace GhostSystem
|
|||||||
|
|
||||||
private void OnEnable()
|
private void OnEnable()
|
||||||
{
|
{
|
||||||
SupabaseManager.OnSuperbaseReady += HandleSupabaseReady;
|
SupabaseManager.OnSuperbaseReady += HandleSupabaseReady; // Das Skript horcht nach den beiden Events, da eine Aufnahme in die Datenbank nur möglich sien soll,
|
||||||
RoomManager.OnSceneIdReady += HandleSceneIdReady;
|
RoomManager.OnSceneIdReady += HandleSceneIdReady; // wenn die Szene komplett geladen und die Verbindung zu Supabase aufgebaut ist.
|
||||||
}
|
}
|
||||||
|
|
||||||
private void OnDisable()
|
private void OnDisable()
|
||||||
@@ -61,8 +63,8 @@ namespace GhostSystem
|
|||||||
supabaseReady = true;
|
supabaseReady = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void HandleSceneIdReady(string id, List<GameObject> doors, List<RecieveHeat> targets)
|
private void HandleSceneIdReady(string id, List<GameObject> doors, List<RecieveHeat> targets) // Die Szene muss komplett geladen sein, da mit dem Event die SceneID
|
||||||
{
|
{ // übergeben wird.
|
||||||
SceneId = id;
|
SceneId = id;
|
||||||
sceneIdReady = true;
|
sceneIdReady = true;
|
||||||
if (SceneId == "Base")
|
if (SceneId == "Base")
|
||||||
@@ -72,8 +74,8 @@ namespace GhostSystem
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
foreach (GameObject door in doors)
|
foreach (GameObject door in doors) // neben den Tracked Objects, die in jeder Szene gleich sind (Player-Root, Kopf, Hände, Augen), müssen die Türen jedes Raums
|
||||||
{
|
{ // zu den Tracked Objects hinzugefügt werden. Nur so wird die Bewegung der Tür auch im Replay wiedergegeben.
|
||||||
var rotator = door.GetComponentInChildren<OneGrabRotateTransformer>();
|
var rotator = door.GetComponentInChildren<OneGrabRotateTransformer>();
|
||||||
if (rotator != null)
|
if (rotator != null)
|
||||||
{
|
{
|
||||||
@@ -86,12 +88,12 @@ namespace GhostSystem
|
|||||||
|
|
||||||
private void Update()
|
private void Update()
|
||||||
{
|
{
|
||||||
if (!_isRecording) return;
|
if (!_isRecording) return; // Code im Update wird nur ausgeführt, während die Aufnahme läuft.
|
||||||
|
|
||||||
_sampleTimer += Time.deltaTime;
|
_sampleTimer += Time.deltaTime;
|
||||||
_flushTimer += Time.deltaTime;
|
_flushTimer += Time.deltaTime;
|
||||||
|
|
||||||
if (_sampleTimer >= SampleRate)
|
if (_sampleTimer >= SampleRate) // Es wird immer die Dauer bis zum nächsten Record-Frame runter gezählt und ein Sample aufgenommen.
|
||||||
{
|
{
|
||||||
_sampleTimer = 0f;
|
_sampleTimer = 0f;
|
||||||
RecordSample();
|
RecordSample();
|
||||||
@@ -107,11 +109,11 @@ namespace GhostSystem
|
|||||||
|
|
||||||
private void RecordSample()
|
private void RecordSample()
|
||||||
{
|
{
|
||||||
foreach (var obj in TrackedObjects)
|
foreach (var obj in TrackedObjects) // Ein Sample besteht aus einer Liste von FrameModels, die für den Zustand jedes getrackten Objekts zum aktuellen Zeitpunkt
|
||||||
{
|
{ // erstellt werden.
|
||||||
var frame = new GhostFrame(SceneId, obj.name, obj.position, obj.rotation);
|
var frame = new GhostFrame(SceneId, obj.name, obj.position, obj.rotation);
|
||||||
_frameBuffer.Add(FrameModel.FromGhostFrame(frame));
|
_frameBuffer.Add(FrameModel.FromGhostFrame(frame)); // Die Frames werden an den Buffer angehängt, um noch während der Aufnahme noch nciht so viele System-
|
||||||
}
|
} // Ressourcen zu verbrauchen.
|
||||||
}
|
}
|
||||||
|
|
||||||
private async UniTaskVoid FlushBatchAsync() // Die eigentliche Methode zum Hochladen eines Batches/leeren des Buffers.
|
private async UniTaskVoid FlushBatchAsync() // Die eigentliche Methode zum Hochladen eines Batches/leeren des Buffers.
|
||||||
@@ -148,7 +150,7 @@ namespace GhostSystem
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private async UniTask FallbackToOfflineAsync(List<FrameModel> batch) // Schreibt den Buffer in eine Datei, falls Upload nicht möglich
|
private async UniTask FallbackToOfflineAsync(List<FrameModel> batch) // Schreibt den Buffer in eine Datei, falls Upload nicht möglich. Kann zu Rucklern führen.
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
@@ -165,7 +167,7 @@ namespace GhostSystem
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void StartRecording()
|
public void StartRecording() // Wenn die Bedingungen erfüllt sind, startet diese Methode die Aufnahme. Sie kann von anderen Skripten aufgerufen werden.
|
||||||
{
|
{
|
||||||
if (!supabaseReady || !sceneIdReady) return;
|
if (!supabaseReady || !sceneIdReady) return;
|
||||||
_isRecording = true;
|
_isRecording = true;
|
||||||
@@ -173,8 +175,8 @@ namespace GhostSystem
|
|||||||
Debug.Log($"Recording {SceneId}");
|
Debug.Log($"Recording {SceneId}");
|
||||||
}
|
}
|
||||||
|
|
||||||
public void StopRecording()
|
public void StopRecording() // Diese Methode stoppt die Aufnahme, löst ein entsprechendes Event aus, das abonniert werden kann und entfernt die Türen des aktuellen
|
||||||
{
|
{ // Raums wieder aus der Liste der Tracked Objects.
|
||||||
_isRecording = false;
|
_isRecording = false;
|
||||||
sceneIdReady = false;
|
sceneIdReady = false;
|
||||||
OnStopRecord?.Invoke();
|
OnStopRecord?.Invoke();
|
||||||
|
|||||||
@@ -11,6 +11,9 @@ using System.Globalization;
|
|||||||
using Oculus.Interaction;
|
using Oculus.Interaction;
|
||||||
using System.Reactive;
|
using System.Reactive;
|
||||||
using Postgrest.Interfaces;
|
using Postgrest.Interfaces;
|
||||||
|
using UnityEngine.InputSystem;
|
||||||
|
|
||||||
|
// Dieses Script ist für die Wiedergabe des Replays mit den Daten aus der Datenbank zuständig.
|
||||||
|
|
||||||
namespace GhostSystem
|
namespace GhostSystem
|
||||||
{
|
{
|
||||||
@@ -81,18 +84,18 @@ namespace GhostSystem
|
|||||||
RoomManager.OnSceneIdReady -= HandleSceneIdReady;
|
RoomManager.OnSceneIdReady -= HandleSceneIdReady;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void HandleSupabaseReady()
|
private void HandleSupabaseReady() // Wen die Verbindung zu Supabase aufgebaut ist, wird versucht, das Replay der Szene zu initialisieren.
|
||||||
{
|
{
|
||||||
supabaseReady = true;
|
supabaseReady = true;
|
||||||
TryInitializeReplay();
|
TryInitializeReplay();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void HandleSceneIdReady(string id, List<GameObject> doors, List<RecieveHeat> targets)
|
private void HandleSceneIdReady(string id, List<GameObject> doors, List<RecieveHeat> targets) // Sobald die Szene geladen ist, wird ebenfalls versucht, das Replay zu
|
||||||
{
|
{ // initialisieren.
|
||||||
loadingScreen.SetActive(true);
|
loadingScreen.SetActive(true); // Während der erste Batch an Frames aus der Datenbank geladen wird, wird ein Ladekringel angezeigt.
|
||||||
sceneIdReady = true;
|
sceneIdReady = true;
|
||||||
loadedSceneId = id;
|
loadedSceneId = id; // die aktuelle SceneID wird gesetzt.
|
||||||
foreach (GameObject door in doors)
|
foreach (GameObject door in doors) // Auch hier müssen die Türen zugeordnet werden.
|
||||||
{
|
{
|
||||||
TrackedObjectBinding trackedObjectBinding = new TrackedObjectBinding();
|
TrackedObjectBinding trackedObjectBinding = new TrackedObjectBinding();
|
||||||
trackedObjectBinding.objectId = "Door";
|
trackedObjectBinding.objectId = "Door";
|
||||||
@@ -104,29 +107,29 @@ namespace GhostSystem
|
|||||||
TryInitializeReplay();
|
TryInitializeReplay();
|
||||||
}
|
}
|
||||||
|
|
||||||
private async UniTaskVoid TryInitializeReplay()
|
private async UniTaskVoid TryInitializeReplay() // Das Replay wird aber nur initialisiert, wenn Supabase und die Szene bereit sind.
|
||||||
{
|
{
|
||||||
if (!supabaseReady || !sceneIdReady) return;
|
if (!supabaseReady || !sceneIdReady) return;
|
||||||
|
|
||||||
sceneId = loadedSceneId;
|
sceneId = loadedSceneId;
|
||||||
awaitingFrames = true;
|
awaitingFrames = true;
|
||||||
|
|
||||||
await LoadAllFrames();
|
await LoadAllFrames(); // Es wird auf die ersten 1000 Frames (siehe Batchsize) bzw. alle verfügbaren Frames (falls unter 1000) gewartet.
|
||||||
loadingScreen.SetActive(false);
|
loadingScreen.SetActive(false); // Sind die Frames geladen, wird der Ladescreen wieder deaktiviert
|
||||||
StartReplay();
|
StartReplay(); // und das Replay gestartet.
|
||||||
_ = PeriodicUpdateFrames();
|
_ = PeriodicUpdateFrames(); // Zusätzlich wird ein Unitask ausgelöst, der immer wieder Frames nachlädt, solange noch Frames in der Datenbank vorhanden sind, die
|
||||||
}
|
} // den Filtern entsprechen und noch nicht geladen wurden.
|
||||||
|
|
||||||
public async UniTask LoadAllFrames()
|
public async UniTask LoadAllFrames()
|
||||||
{
|
{
|
||||||
Debug.Log("SceneId used in query: " + sceneId);
|
Debug.Log("SceneId used in query: " + sceneId);
|
||||||
|
|
||||||
|
|
||||||
var startTime = dateSelector.selectedDateTime();
|
var startTime = dateSelector.selectedDateTime(); // Erstellt einen Zeitstring aus den im UI eingegebenen Session-Daten
|
||||||
var endTime = dateSelector.EndTime();
|
var endTime = dateSelector.EndTime(); // und einen zweiten für den Endpunkt der Trainingssession.
|
||||||
|
|
||||||
if (dateSelector.startTimeInput.text != "")
|
if (dateSelector.startTimeInput.text != "") // Es wird dabei geprüft, ob ein fertiger Timestring in das vorgesehene Feld kopiert wurde. Dann werden die
|
||||||
{
|
{ // Dropdowns ignoriert.
|
||||||
startTimeString = dateSelector.startTimeInput.text;
|
startTimeString = dateSelector.startTimeInput.text;
|
||||||
}
|
}
|
||||||
else startTimeString = startTime.ToString("o");
|
else startTimeString = startTime.ToString("o");
|
||||||
@@ -146,36 +149,35 @@ namespace GhostSystem
|
|||||||
bool more = true;
|
bool more = true;
|
||||||
List<FrameModel> allFrames = new();
|
List<FrameModel> allFrames = new();
|
||||||
|
|
||||||
while (more)
|
while (more) // Solange Frames mit dem Filter (in chronologischer Reihenfolge) in der Datenbank vorhanden sind, wird immer ein neuer Batch von maximal 1000 Frames
|
||||||
{
|
{ // heruntergeladen.
|
||||||
List<IPostgrestQueryFilter> timestampFilter = new List<IPostgrestQueryFilter>();
|
List<IPostgrestQueryFilter> timestampFilter = new List<IPostgrestQueryFilter>(); // Es wird eine Filterverkettung für Startzeit und Endzeit erstellt.
|
||||||
timestampFilter.Add(new QueryFilter("timestamp", Postgrest.Constants.Operator.GreaterThanOrEqual, startTimeString));
|
timestampFilter.Add(new QueryFilter("timestamp", Postgrest.Constants.Operator.GreaterThanOrEqual, startTimeString));
|
||||||
timestampFilter.Add(new QueryFilter("timestamp", Postgrest.Constants.Operator.LessThan, endTimeString));
|
timestampFilter.Add(new QueryFilter("timestamp", Postgrest.Constants.Operator.LessThan, endTimeString));
|
||||||
|
|
||||||
var query = SupabaseManager.instance.supabase
|
var query = SupabaseManager.instance.supabase
|
||||||
.From<FrameModel>()
|
.From<FrameModel>()
|
||||||
.Filter("scene_id", Postgrest.Constants.Operator.Equals, sceneId)
|
.Filter("scene_id", Postgrest.Constants.Operator.Equals, sceneId) // und neben der SceneID...
|
||||||
//.Where(x => x.Timestamp >= "timestamp '2025-06-14 10:27:00' and" x => x.Timestamp.timestamp <= "timestamp '2025-06-14 10:29:00'")
|
|
||||||
//.Filter("timestamp", Postgrest.Constants.Operator.GreaterThanOrEqual, startTime.ToString("o"))
|
.And(timestampFilter) // ...dem SQL-Command hinzugefügt.
|
||||||
.And(timestampFilter)
|
|
||||||
//.Filter("timestamp", Postgrest.Constants.Operator.LessThan, endTime.ToString("o"))
|
|
||||||
.Order("timestamp", Postgrest.Constants.Ordering.Ascending)
|
.Order("timestamp", Postgrest.Constants.Ordering.Ascending)
|
||||||
.Limit(batchSize) // Limit, wie viele Frames in einem Batch geladen werden. (Standardmäßig 1000)
|
.Limit(batchSize) // Limit, wie viele Frames in einem Batch geladen werden. (Standardmäßig 1000)
|
||||||
.Offset(offset); // Um zu wissen, wo der nächste Batch anfängt
|
.Offset(offset); // Um zu wissen, wo der nächste Batch anfängt
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(UserFilter))
|
if (!string.IsNullOrEmpty(UserFilter))
|
||||||
query = query.Filter("user_id", Postgrest.Constants.Operator.Equals, UserFilter);
|
query = query.Filter("user_id", Postgrest.Constants.Operator.Equals, UserFilter); // Wenn die User ID angegebeen wurde, wird auch danach gefiltert.
|
||||||
|
|
||||||
var result = await query.Get();
|
var result = await query.Get(); // Es werden die Frames aus der Datenbank geladen
|
||||||
if (result.Models.Count == 0) break;
|
if (result.Models.Count == 0) break;
|
||||||
if (result.Models[0].SceneId != sceneId) break;
|
if (result.Models[0].SceneId != sceneId) break;
|
||||||
Debug.LogError("Model Count: " + result.Models.Count);
|
Debug.LogError("Model Count: " + result.Models.Count);
|
||||||
allFrames.AddRange(result.Models);
|
allFrames.AddRange(result.Models);
|
||||||
offset += batchSize;
|
offset += batchSize;
|
||||||
more = result.Models.Count == batchSize;
|
more = result.Models.Count == batchSize; // Und in einer lokalen Liste gespeichert. Ähnlich dem Buffer beim Ghost Recorder.
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach (var frame in allFrames)
|
foreach (var frame in allFrames) // Die Frames werden den Tracked Objects zugeordnet.
|
||||||
{
|
{
|
||||||
if (!objectTracks.ContainsKey(frame.ObjectId))
|
if (!objectTracks.ContainsKey(frame.ObjectId))
|
||||||
objectTracks[frame.ObjectId] = new List<FrameModel>();
|
objectTracks[frame.ObjectId] = new List<FrameModel>();
|
||||||
@@ -262,18 +264,18 @@ namespace GhostSystem
|
|||||||
playbackTime = Mathf.Clamp(time, 0f, totalDuration);
|
playbackTime = Mathf.Clamp(time, 0f, totalDuration);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Update()
|
private void Update() // Solange das Replay auf "Play" steht, wird durch die Liste der Frames gegangen und die Positions- und Rotationsdaten aus selbigen angewendet,
|
||||||
{
|
{ // wenn die Differenz zwischen Startzeit und Timestamp des Frames der bisherigen Playback-Time entspricht.
|
||||||
if (!isPlaying || objectTracks.Count == 0) return;
|
if (!isPlaying || objectTracks.Count == 0) return;
|
||||||
|
|
||||||
playbackTime += Time.deltaTime * PlaybackSpeed;
|
playbackTime += Time.deltaTime * PlaybackSpeed;
|
||||||
|
|
||||||
if (playbackTime > totalDuration)
|
if (playbackTime > totalDuration) // Erreicht das Replay das Ende der Frame-Liste, wird es entwerder gestoppt
|
||||||
{
|
{
|
||||||
if (Loop)
|
if (Loop)
|
||||||
{
|
{
|
||||||
playbackTime = 0f;
|
playbackTime = 0f;
|
||||||
OnRestartLoop?.Invoke();
|
OnRestartLoop?.Invoke(); // oder neu gestartet, wenn die Loop-Funktion aktiviert ist.
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
isPlaying = false;
|
isPlaying = false;
|
||||||
@@ -326,31 +328,31 @@ namespace GhostSystem
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetSliderScrubValue(float sliderValue)
|
public void SetSliderScrubValue(float sliderValue) // der aktuelle Playback-Zeitpunkt wird aktualisiert solange gescrubbt wird.
|
||||||
{
|
{
|
||||||
if (isScrubbing)
|
if (isScrubbing)
|
||||||
SetPlaybackTime(sliderValue * totalDuration);
|
SetPlaybackTime(sliderValue * totalDuration);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void OnSliderStartDrag()
|
public void OnSliderStartDrag() // Das Scrubbing wird gestartet, sobald der Slider angefasst wird.
|
||||||
{
|
{
|
||||||
isScrubbing = true;
|
isScrubbing = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void OnSliderEndDrag()
|
public void OnSliderEndDrag() // Setzt den aktuellen Playback-Zeitpunkt auf den Timestamp, der dem übergebenen Slider-Wert entspricht.
|
||||||
{
|
{
|
||||||
isScrubbing = false;
|
isScrubbing = false;
|
||||||
SetPlaybackTime(playbackSlider.value * totalDuration);
|
SetPlaybackTime(playbackSlider.value * totalDuration);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void RemoveDoors()
|
public void RemoveDoors() // Auch hier gibt es wieder eine Funktion, um vor dem Raumwechsel die Türen aus den Tracked Objects zu entfernen.
|
||||||
{
|
{
|
||||||
TrackedObjects.RemoveRange(TrackedObjects.Count - doorCount, doorCount);
|
TrackedObjects.RemoveRange(TrackedObjects.Count - doorCount, doorCount);
|
||||||
doorCount = 0;
|
doorCount = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void StopAwaitingFrames()
|
public void StopAwaitingFrames() // Kann zum Szenenwechsel aufgerufen werden, um das aktuelle Replay und das Nachladen von Frames abzubrechen.
|
||||||
{
|
{
|
||||||
awaitingFrames = false;
|
awaitingFrames = false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,6 +8,9 @@ using Client = Supabase.Client;
|
|||||||
using Cysharp.Threading.Tasks;
|
using Cysharp.Threading.Tasks;
|
||||||
using TMPro;
|
using TMPro;
|
||||||
|
|
||||||
|
// Dieses Script wickelt die gesamte Kommunikation mit der Datenbank ab. Das Skript enthält noch einige Verbindungstests (z.B. zu Google), die bei Bedarf zum Debuggen verwendet
|
||||||
|
// werden können.
|
||||||
|
|
||||||
namespace GhostSystem
|
namespace GhostSystem
|
||||||
{
|
{
|
||||||
public class SupabaseManager : MonoBehaviour
|
public class SupabaseManager : MonoBehaviour
|
||||||
@@ -36,7 +39,7 @@ namespace GhostSystem
|
|||||||
|
|
||||||
private async UniTask Initialize()
|
private async UniTask Initialize()
|
||||||
{
|
{
|
||||||
if (instance == null)
|
if (instance == null) // Zuerst wird sichergestellt, dass nur eine Instanz des Supabase-Managers existiert und beim Szenenwechsel mitgenommen wird.
|
||||||
{
|
{
|
||||||
instance = this;
|
instance = this;
|
||||||
DontDestroyOnLoad(gameObject);
|
DontDestroyOnLoad(gameObject);
|
||||||
@@ -47,29 +50,29 @@ namespace GhostSystem
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Debug.Log("🌐 Starting Supabase setup...");
|
Debug.Log("Starting Supabase setup...");
|
||||||
await RunDiagnostics();
|
await RunDiagnostics(); // Dann wird geprüft, ob die Supabase-Instanz erreichbar ist.
|
||||||
|
|
||||||
await InitSupabaseAsync();
|
await InitSupabaseAsync(); // Eigentlicher Verbindungsaufbau.
|
||||||
OnSuperbaseReady?.Invoke();
|
OnSuperbaseReady?.Invoke(); // Wenn erfolgreich eine Verbindung zu Supabase aufgebaut wurde, wird das als Event gemeldet.
|
||||||
}
|
}
|
||||||
|
|
||||||
private async UniTask InitSupabaseAsync()
|
private async UniTask InitSupabaseAsync() // Wird aufgerufen, um die Verbindung zu Supabase zu initialisieren.
|
||||||
{
|
{
|
||||||
if (supabase != null)
|
if (supabase != null)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
string path = Path.Combine(Application.persistentDataPath, authFileName);
|
string path = Path.Combine(Application.persistentDataPath, authFileName);
|
||||||
|
|
||||||
if (File.Exists(path))
|
if (File.Exists(path)) // Ist bereits eine Datei mit Email und Passwort auf dem VR-Headset hinterlegt, wird diese ausgelesen.
|
||||||
{
|
{
|
||||||
string[] lines = await UniTask.Run(() => File.ReadAllLines(path));
|
string[] lines = await UniTask.Run(() => File.ReadAllLines(path));
|
||||||
email = lines[0];
|
email = lines[0];
|
||||||
password = lines[1];
|
password = lines[1];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{ // Falls nicht, werden neue Anmeldedaten erstellt.
|
||||||
email = string.IsNullOrEmpty(SystemInfo.deviceUniqueIdentifier)
|
email = string.IsNullOrEmpty(SystemInfo.deviceUniqueIdentifier) // Fake-Email-Adresse wird aus der GUID des Gerätes generiert.
|
||||||
? $"{Guid.NewGuid()}@device.local" // Fallback, generiert theoretisch bei jeder Neuinstallation der App einen anderen User.
|
? $"{Guid.NewGuid()}@device.local" // Fallback, generiert theoretisch bei jeder Neuinstallation der App einen anderen User.
|
||||||
: $"{SystemInfo.deviceUniqueIdentifier}@device.local";
|
: $"{SystemInfo.deviceUniqueIdentifier}@device.local";
|
||||||
|
|
||||||
@@ -78,7 +81,7 @@ namespace GhostSystem
|
|||||||
await UniTask.Run(() => File.WriteAllLines(path, new[] { email, password }));
|
await UniTask.Run(() => File.WriteAllLines(path, new[] { email, password }));
|
||||||
}
|
}
|
||||||
|
|
||||||
Debug.Log($"📧 Using Email: {email}, Password: {password}");
|
Debug.Log($"Using Email: {email}, Password: {password}");
|
||||||
|
|
||||||
supabase = new Client(subabaseUrl, supabaseAnonKey);
|
supabase = new Client(subabaseUrl, supabaseAnonKey);
|
||||||
|
|
||||||
@@ -86,39 +89,39 @@ namespace GhostSystem
|
|||||||
{
|
{
|
||||||
await supabase.InitializeAsync();
|
await supabase.InitializeAsync();
|
||||||
textbox.text += "\n\rSupabase initialized.";
|
textbox.text += "\n\rSupabase initialized.";
|
||||||
Debug.Log("✅ Supabase initialized.");
|
Debug.Log("Supabase initialized.");
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
Debug.LogError($"❌ Initialization failed: {ex}");
|
Debug.LogError($"Initialization failed: {ex}");
|
||||||
textbox.text += "\n\rInitialization failed";
|
textbox.text += "\n\rInitialization failed";
|
||||||
}
|
}
|
||||||
|
|
||||||
await AuthenticateAsync(email, password);
|
await AuthenticateAsync(email, password);
|
||||||
Debug.Log($"👤 Authenticated user ID: {userId}");
|
Debug.Log($"Authenticated user ID: {userId}");
|
||||||
}
|
}
|
||||||
|
|
||||||
public async UniTask AuthenticateAsync(string email, string password)
|
public async UniTask AuthenticateAsync(string email, string password) // Diese Methode übernimmt die Anmeldung als User bei der Supabase-Instanz.
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await supabase.Auth.SignIn(email, password);
|
await supabase.Auth.SignIn(email, password); // Nutzt die übergebene Mail-Adresse und das Passwort, um den Unser anzumelden.
|
||||||
textbox.text += "\n\rSign-in successful";
|
textbox.text += "\n\rSign-in successful";
|
||||||
Debug.Log("🔓 Sign-in successful");
|
Debug.Log("Sign-in successful");
|
||||||
}
|
}
|
||||||
catch (Exception authEx)
|
catch (Exception authEx) // Funktioniert die Anmeldung nicht, wird versucht, einen neuen User mit der übergebenen Mail-Adresse und dem
|
||||||
{
|
{ // Passwort zu registrieren.
|
||||||
Debug.LogWarning($"Sign-in failed, trying sign-up: {authEx.Message}");
|
Debug.LogWarning($"Sign-in failed, trying sign-up: {authEx.Message}");
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
await supabase.Auth.SignUp(email, password);
|
await supabase.Auth.SignUp(email, password);
|
||||||
textbox.text += "\n\rSign-up successful";
|
textbox.text += "\n\rSign-up successful";
|
||||||
Debug.Log("🆕 Sign-up successful");
|
Debug.Log("Sign-up successful");
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
textbox.text += "\n\rAuthentication failed";
|
textbox.text += "\n\rAuthentication failed";
|
||||||
Debug.LogError($"❌ Authentication failed: {ex}");
|
Debug.LogError($"Authentication failed: {ex}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -128,7 +131,7 @@ namespace GhostSystem
|
|||||||
await UniTask.WhenAll(CheckSupabaseHealthAsync(), CheckGoogleConnectionAsync());
|
await UniTask.WhenAll(CheckSupabaseHealthAsync(), CheckGoogleConnectionAsync());
|
||||||
}
|
}
|
||||||
|
|
||||||
private async UniTask CheckSupabaseHealthAsync()
|
private async UniTask CheckSupabaseHealthAsync() // Prüft, ob Supabase erreichbar ist.
|
||||||
{
|
{
|
||||||
using var www = UnityWebRequest.Get($"{subabaseUrl}/auth/v1/health");
|
using var www = UnityWebRequest.Get($"{subabaseUrl}/auth/v1/health");
|
||||||
www.SetRequestHeader("apikey", supabaseAnonKey);
|
www.SetRequestHeader("apikey", supabaseAnonKey);
|
||||||
@@ -137,16 +140,16 @@ namespace GhostSystem
|
|||||||
if (www.result == UnityWebRequest.Result.Success)
|
if (www.result == UnityWebRequest.Result.Success)
|
||||||
{
|
{
|
||||||
//textbox.text += $"\n\rSupabase health: {www.downloadHandler.text}";
|
//textbox.text += $"\n\rSupabase health: {www.downloadHandler.text}";
|
||||||
Debug.Log($"✅ Supabase health: {www.downloadHandler.text}");
|
Debug.Log($"Supabase health: {www.downloadHandler.text}");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
//textbox.text += $"\n\rSupabase health check failed: {www.error}";
|
//textbox.text += $"\n\rSupabase health check failed: {www.error}";
|
||||||
Debug.LogError($"❌ Supabase health check failed: {www.error}");
|
Debug.LogError($"Supabase health check failed: {www.error}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private async UniTask CheckGoogleConnectionAsync()
|
private async UniTask CheckGoogleConnectionAsync() // Testet, ob grundsätzlich eine Internetverbindung besteht.
|
||||||
{
|
{
|
||||||
using var www = UnityWebRequest.Get("https://www.google.com");
|
using var www = UnityWebRequest.Get("https://www.google.com");
|
||||||
await www.SendWebRequest();
|
await www.SendWebRequest();
|
||||||
@@ -154,12 +157,12 @@ namespace GhostSystem
|
|||||||
if (www.result == UnityWebRequest.Result.Success)
|
if (www.result == UnityWebRequest.Result.Success)
|
||||||
{
|
{
|
||||||
//textbox.text += "\n\rGoogle request succeeded.";
|
//textbox.text += "\n\rGoogle request succeeded.";
|
||||||
Debug.Log("✅ Google request succeeded.");
|
Debug.Log("Google request succeeded.");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
textbox.text += $"\n\rGoogle connection failed: {www.error}";
|
textbox.text += $"\n\rGoogle connection failed: {www.error}";
|
||||||
Debug.LogError($"❌ Google connection failed: {www.error}");
|
Debug.LogError($"Google connection failed: {www.error}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: 29dcdaa22183d134b98e466af7f041e8
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
@@ -1,5 +1,8 @@
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Eine Helfer-Component um das Problem zu umgehen, dass GameObjects unter bestimmten Bedingungnen nciht über das Unity Event System aktiviert oder deaktiviert werden könnnen.
|
||||||
|
// Dieses Skript kann einfach auf ein Objekt gelegt werden und die öffentliche Methode dann verlinkt werden.
|
||||||
|
|
||||||
public class ActiveToggle : MonoBehaviour
|
public class ActiveToggle : MonoBehaviour
|
||||||
{
|
{
|
||||||
public void ToggleActive(GameObject obj)
|
public void ToggleActive(GameObject obj)
|
||||||
|
|||||||
@@ -8,6 +8,9 @@ using UnityEngine;
|
|||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
// Dieses Script ermöglicht das Einlesen einer Log-Datei, wie sie von der VR-Anwendung im Offline-Modus erstellt wird.
|
||||||
|
// Der Inhalt der Datei wird als Batch in die Datenbank hochgeladen.
|
||||||
|
|
||||||
public class BatchUploader : MonoBehaviour
|
public class BatchUploader : MonoBehaviour
|
||||||
{
|
{
|
||||||
public TMP_InputField fileNameInput;
|
public TMP_InputField fileNameInput;
|
||||||
|
|||||||
@@ -3,14 +3,16 @@ using Unity.Cinemachine;
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.InputSystem;
|
using UnityEngine.InputSystem;
|
||||||
|
|
||||||
|
// Die Zoom-Funktion per Scrollrad musste erst händisch der Orbit-Kamera hinzugefügt werden. Dafür ist dieses Script zuständig.
|
||||||
|
|
||||||
public class CinemachinePositionComposerController : MonoBehaviour
|
public class CinemachinePositionComposerController : MonoBehaviour
|
||||||
{
|
{
|
||||||
[Header("Input Actions")]
|
[Header("Input Actions")]
|
||||||
public InputActionReference zoomAction;
|
public InputActionReference zoomAction; // Zuweisung einer Unity Input System Action.
|
||||||
|
|
||||||
public CinemachinePositionComposer positionComposer;
|
public CinemachinePositionComposer positionComposer; // Zuweisung eines Position Composers der manipuliert werden soll.
|
||||||
|
|
||||||
private bool zoomBlocked = false;
|
private bool zoomBlocked = false; // Blocker für Zoom (wie schon in OrbitCameraMouseControl).
|
||||||
|
|
||||||
private void OnEnable()
|
private void OnEnable()
|
||||||
{
|
{
|
||||||
@@ -22,20 +24,20 @@ public class CinemachinePositionComposerController : MonoBehaviour
|
|||||||
|
|
||||||
void Update()
|
void Update()
|
||||||
{
|
{
|
||||||
if (zoomAction != null && !zoomBlocked)
|
if (zoomAction != null && !zoomBlocked) // Wenn der Blocker nicht aktiv und die Action zugewiesen ist, wird in jedem Frame der Zustand des Scrollrads abgefragt
|
||||||
{
|
{ // und auf dieser Basis die CameraDistance im Position Composer verändert.
|
||||||
Vector2 zoomValue = zoomAction.action.ReadValue<Vector2>();
|
Vector2 zoomValue = zoomAction.action.ReadValue<Vector2>();
|
||||||
positionComposer.CameraDistance = positionComposer.CameraDistance - zoomValue.y * 0.25f;
|
positionComposer.CameraDistance = positionComposer.CameraDistance - zoomValue.y * 0.25f;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetBlocker(bool value)
|
public void SetBlocker(bool value) // mit dieser Funktion kann der Blocker durch andere Skripte gesetzt werden.
|
||||||
{
|
{
|
||||||
zoomBlocked = value;
|
zoomBlocked = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetLookahead(bool value)
|
public void SetLookahead(bool value) // Die Aktivierung und Deaktivierung des in Cinemachine möglichen Lookaheads wurde hier ebenfalls untergebracht.
|
||||||
{
|
{
|
||||||
positionComposer.Lookahead.Enabled = value;
|
positionComposer.Lookahead.Enabled = value;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,6 +4,8 @@ using System.Collections.Generic;
|
|||||||
using TMPro;
|
using TMPro;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Dieses Skript stellt die Funktionen für das Datums-Dropdown in der AAR-App bereit.
|
||||||
|
|
||||||
public class DateSelector : MonoBehaviour
|
public class DateSelector : MonoBehaviour
|
||||||
{
|
{
|
||||||
public int selectedYear;
|
public int selectedYear;
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.Events;
|
using UnityEngine.Events;
|
||||||
|
|
||||||
|
// Eine simple Helfer-Component um Unity events auszulösen, wenn ein GemeObject aktiviert oder deaktiviert wird.
|
||||||
|
|
||||||
public class EnableDisableActions : MonoBehaviour
|
public class EnableDisableActions : MonoBehaviour
|
||||||
{
|
{
|
||||||
[SerializeField] UnityEvent onEnable;
|
[SerializeField] UnityEvent onEnable;
|
||||||
|
|||||||
@@ -5,6 +5,8 @@ using UnityEngine.SceneManagement;
|
|||||||
using UnityEngine.UI;
|
using UnityEngine.UI;
|
||||||
using TMPro;
|
using TMPro;
|
||||||
|
|
||||||
|
// Diese Klasse ist dafür da, die aktuell vorhandenen Szenen der ANwendung rauszusuchen und das Szenen-Dropdown damit zu füllen.
|
||||||
|
|
||||||
public class FillDopdownWithScenes : MonoBehaviour
|
public class FillDopdownWithScenes : MonoBehaviour
|
||||||
{
|
{
|
||||||
public TMP_Dropdown dropdown;
|
public TMP_Dropdown dropdown;
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ using System.Collections.Generic;
|
|||||||
using TMPro;
|
using TMPro;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Diese Hilfsklasse wird verwendet, um das Dropdown-Menü für den Tag mit der kokkekten Anzahl an Tagen für den ausgewählten Monat zu füllen.
|
||||||
|
|
||||||
public class FillDropdownWithDays : MonoBehaviour
|
public class FillDropdownWithDays : MonoBehaviour
|
||||||
{
|
{
|
||||||
public TMP_Dropdown dropdown;
|
public TMP_Dropdown dropdown;
|
||||||
|
|||||||
@@ -7,6 +7,8 @@ using UnityEngine.UI;
|
|||||||
using Cysharp.Threading.Tasks;
|
using Cysharp.Threading.Tasks;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
// Skript der Basis-Szene, um den Szenenwechsel in der Version ohne Portale zu vollziehen.
|
||||||
|
|
||||||
public class FlushAndLoad : MonoBehaviour
|
public class FlushAndLoad : MonoBehaviour
|
||||||
{
|
{
|
||||||
public TMP_Text output;
|
public TMP_Text output;
|
||||||
@@ -20,8 +22,8 @@ public class FlushAndLoad : MonoBehaviour
|
|||||||
|
|
||||||
private void OnEnable()
|
private void OnEnable()
|
||||||
{
|
{
|
||||||
GhostRecorderBatch.OnUploadFinished += HandleUploadFinished;
|
GhostRecorderBatch.OnUploadFinished += HandleUploadFinished; // abonniert das Event, das ausgelöst wird, wenn der Upload in die Datenbank erfolgreich war.
|
||||||
RoomManager.OnSceneIdReady += HandleSceneIdReady;
|
RoomManager.OnSceneIdReady += HandleSceneIdReady; // abonniert das Event, das ausgelöst wird, wenn die neue Szene vollständig hinzugeladen wurde.
|
||||||
}
|
}
|
||||||
|
|
||||||
private void OnDisable()
|
private void OnDisable()
|
||||||
@@ -30,18 +32,12 @@ public class FlushAndLoad : MonoBehaviour
|
|||||||
RoomManager.OnSceneIdReady -= HandleSceneIdReady;
|
RoomManager.OnSceneIdReady -= HandleSceneIdReady;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
|
||||||
void Start()
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
// Update is called once per frame
|
// Update is called once per frame
|
||||||
void Update()
|
void Update()
|
||||||
{
|
{
|
||||||
if (OVRInput.GetDown(OVRInput.Button.SecondaryIndexTrigger))
|
if (OVRInput.GetDown(OVRInput.Button.SecondaryIndexTrigger)) // der rechte Trigger löst den Szenenwechsel aus.
|
||||||
{
|
{
|
||||||
if (sceneId == "End") Application.Quit();
|
if (sceneId == "End") Application.Quit(); // außer nach der letzten Szene. Dort wird die Anwendung beendet.
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
output.text = "Flush...";
|
output.text = "Flush...";
|
||||||
@@ -56,11 +52,11 @@ public class FlushAndLoad : MonoBehaviour
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void HandleUploadFinished()
|
private void HandleUploadFinished() // wenn der Upload in die Datenbank erfolgreich war, wird der Pass-Through-Layer wieder deaktiviert, um entweder die neue Szene zu zeigen
|
||||||
{
|
{
|
||||||
loadingScreen.SetActive(false);
|
loadingScreen.SetActive(false);
|
||||||
output.text = "";
|
output.text = "";
|
||||||
if (sceneId == "End")
|
if (sceneId == "End") // oder nach der letzten Szene einen Info-Text.
|
||||||
{
|
{
|
||||||
output.text = "Durchlauf beendet.";
|
output.text = "Durchlauf beendet.";
|
||||||
}
|
}
|
||||||
@@ -68,15 +64,15 @@ public class FlushAndLoad : MonoBehaviour
|
|||||||
|
|
||||||
private void HandleSceneIdReady(string id, List<GameObject> doors, List<RecieveHeat> targets)
|
private void HandleSceneIdReady(string id, List<GameObject> doors, List<RecieveHeat> targets)
|
||||||
{
|
{
|
||||||
sceneId = id;
|
sceneId = id; // wenn die neu hinzugeladene Szene bereit ist, wird die sceneID gesetzt.
|
||||||
if (id == "Room1")
|
if (id == "Room1")
|
||||||
{
|
{
|
||||||
loadingScreen.SetActive(false);
|
loadingScreen.SetActive(false); // Bei Room1 wird zusätzlich der Pass-Through-Layer/Loding Screen deaktiviert, da hier noch keine Daten hochgeladen werden
|
||||||
passthroughLayer.SetActive(false);
|
passthroughLayer.SetActive(false); // und somit das entsprechende Event nicht ausgelöst wird.
|
||||||
}
|
}
|
||||||
if (id == "End")
|
if (id == "End")
|
||||||
{
|
{
|
||||||
instruction.text = "Drücke den rechten Trigger, um die Anwendung zu beenden.";
|
instruction.text = "Drücke den rechten Trigger, um die Anwendung zu beenden."; // Die zweite Ausnahme bildet die letzte Szene. Hier erscheint nur eine Info-Tafel.
|
||||||
canvas.SetActive(true);
|
canvas.SetActive(true);
|
||||||
passthroughLayer.SetActive(true);
|
passthroughLayer.SetActive(true);
|
||||||
}
|
}
|
||||||
@@ -88,10 +84,10 @@ public class FlushAndLoad : MonoBehaviour
|
|||||||
canvas.SetActive(false);
|
canvas.SetActive(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
private async UniTaskVoid LoadScene()
|
private async UniTaskVoid LoadScene() // Die eigentliche Funktion zum Laden der Szene aktiviert erst den Pass-Through-Layer/Loading Screen um Motion Sickness durch stehendes
|
||||||
{
|
{ // Bild zu vermeiden. Dann wird der Flush-Befehl zum Upload der Recording-Daten in die Datenbank gegeben.
|
||||||
await Loadingscreen();
|
await Loadingscreen();
|
||||||
recorder.Flush();
|
recorder.Flush();
|
||||||
GetComponent<SceneLoader>().NewRoom();
|
GetComponent<SceneLoader>().NewRoom(); // Es wird der nächste Raum geladen. Der Pass-Through-Layer bleibt so lange aktiv, bis er durch die abonnierten Events deaktiviert
|
||||||
}
|
} // wird. So kann Motion-Sickness durch stockende Bilder beim Laden vermieden werden.
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,6 +5,8 @@ using System.Collections.Generic;
|
|||||||
using Unity.Netcode;
|
using Unity.Netcode;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Zur unterscheideung des localen Player-Rigs von adneren aus dem Multiplayer. Aktuell nicht in Benutzung.
|
||||||
|
|
||||||
public class LocalPlayerReference : NetworkBehaviour
|
public class LocalPlayerReference : NetworkBehaviour
|
||||||
{
|
{
|
||||||
public static LocalPlayerReference Instance { get; private set; }
|
public static LocalPlayerReference Instance { get; private set; }
|
||||||
|
|||||||
@@ -0,0 +1,8 @@
|
|||||||
|
fileFormatVersion: 2
|
||||||
|
guid: f0f419a0b003b0844b74f62b8a92de23
|
||||||
|
folderAsset: yes
|
||||||
|
DefaultImporter:
|
||||||
|
externalObjects: {}
|
||||||
|
userData:
|
||||||
|
assetBundleName:
|
||||||
|
assetBundleVariant:
|
||||||
+2
@@ -3,6 +3,8 @@ using System.Collections.Generic;
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.SceneManagement;
|
using UnityEngine.SceneManagement;
|
||||||
|
|
||||||
|
// Ehemaliges Skript für die Start-Szene. Nicht mehr in Verwendung
|
||||||
|
|
||||||
public class GameStarter : MonoBehaviour
|
public class GameStarter : MonoBehaviour
|
||||||
{
|
{
|
||||||
[SerializeField] int startScene = 1;
|
[SerializeField] int startScene = 1;
|
||||||
+2
@@ -2,6 +2,8 @@ using System.Globalization;
|
|||||||
using Unity.Netcode;
|
using Unity.Netcode;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Hilfs-Skript um bestimmte Objekte für den lokalen Spieler unsichtbar zu machen. Findet momentan keine Anwendung.
|
||||||
|
|
||||||
public class InvisibleForLocalPlayer : NetworkBehaviour
|
public class InvisibleForLocalPlayer : NetworkBehaviour
|
||||||
{
|
{
|
||||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||||
+2
@@ -1,6 +1,8 @@
|
|||||||
using Unity.Netcode;
|
using Unity.Netcode;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Script zum Spawnen der Spieler im Multiplayer. Aktuell nicht in Benutzung.
|
||||||
|
|
||||||
public class PlayerSpawner : NetworkBehaviour
|
public class PlayerSpawner : NetworkBehaviour
|
||||||
{
|
{
|
||||||
public override void OnNetworkSpawn()
|
public override void OnNetworkSpawn()
|
||||||
+2
@@ -3,6 +3,8 @@ using System.Collections.Generic;
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.XR;
|
using UnityEngine.XR;
|
||||||
|
|
||||||
|
// Script zur automatisierten Ausrichtung der Basis-Szene am Spielbereich. Wird in der aktuellen Version nicht verwendet.
|
||||||
|
|
||||||
public class SpawnAtLongestEdge : MonoBehaviour
|
public class SpawnAtLongestEdge : MonoBehaviour
|
||||||
{
|
{
|
||||||
|
|
||||||
@@ -1,6 +1,9 @@
|
|||||||
using Unity.Netcode;
|
using Unity.Netcode;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Dieses Skript ist notwendig, um zum einen Smooth-Movement per Stick-Bewegung zu ermöglichen und zum anderen, dass der Character-Controller bei der physikalischen
|
||||||
|
// Roomscale-Bewegung dem/der NutzerIn folgt.
|
||||||
|
|
||||||
[RequireComponent(typeof(CharacterController))]
|
[RequireComponent(typeof(CharacterController))]
|
||||||
public class OVRStickAndRoomscaleMovement : NetworkBehaviour
|
public class OVRStickAndRoomscaleMovement : NetworkBehaviour
|
||||||
{
|
{
|
||||||
@@ -12,13 +15,13 @@ public class OVRStickAndRoomscaleMovement : NetworkBehaviour
|
|||||||
private CharacterController characterController;
|
private CharacterController characterController;
|
||||||
private Vector3 velocity;
|
private Vector3 velocity;
|
||||||
|
|
||||||
public float minHeight = 1.0f; // Kleinster Collider
|
public float minHeight = 1.0f; // Minimal mögliche Körpergröße (oder Größe wenn geduckt)
|
||||||
public float maxHeight = 2.2f; // Größter Collider
|
public float maxHeight = 2.2f; // Maximal mögliche Körpergröße
|
||||||
public float skinWidth = 0.05f; // Charaktercontroller-Skin
|
public float skinWidth = 0.05f; // Durchmesser des Kapsel-Colliders für den Körper. Darf nicht zu groß sein, um sich z.B. über Tische beugen zu können, ohne von der ingame-
|
||||||
|
// Physik weggeschoben zu werden.
|
||||||
void Start()
|
void Start()
|
||||||
{
|
{
|
||||||
//if (!IsOwner) return;
|
//if (!IsOwner) return; Wäre nur bei Multiplayer wichtig.
|
||||||
|
|
||||||
characterController = GetComponent<CharacterController>();
|
characterController = GetComponent<CharacterController>();
|
||||||
|
|
||||||
@@ -28,9 +31,9 @@ public class OVRStickAndRoomscaleMovement : NetworkBehaviour
|
|||||||
|
|
||||||
void Update()
|
void Update()
|
||||||
{
|
{
|
||||||
//if (!IsOwner) return;
|
//if (!IsOwner) return; Wäre nur bei Multiplayer wichtig.
|
||||||
|
|
||||||
// 1. Real-World Position des Headsets bestimmen
|
// 1. Position des Kopfes in der realen Welt bestimmen.
|
||||||
Vector3 headLocalPos = rigRoot.InverseTransformPoint(cameraTransform.position);
|
Vector3 headLocalPos = rigRoot.InverseTransformPoint(cameraTransform.position);
|
||||||
|
|
||||||
// 2. Höhe anpassen (Stehen, Hocken)
|
// 2. Höhe anpassen (Stehen, Hocken)
|
||||||
|
|||||||
@@ -5,12 +5,12 @@ using Unity.Cinemachine;
|
|||||||
public class OrbitCameraMouseControl : MonoBehaviour
|
public class OrbitCameraMouseControl : MonoBehaviour
|
||||||
{
|
{
|
||||||
[Header("Input Actions")]
|
[Header("Input Actions")]
|
||||||
public InputActionReference aimAction; // CM Default / Aim
|
public InputActionReference aimAction; // erlaubt die Zuweisung einer Unity Input System Action. Der Name AimAction kommt von der Belegung auf der rechten Maustaste.
|
||||||
|
|
||||||
[Header("Cinemachine Components")]
|
[Header("Cinemachine Components")]
|
||||||
public CinemachineInputAxisController inputAxisController;
|
public CinemachineInputAxisController inputAxisController; // hier wird der InputAxisController der Cinemachine Camera verlinkt, der manipuliert werden soll.
|
||||||
|
|
||||||
private bool aimingBlocked = false;
|
private bool aimingBlocked = false; // wird verwendet, um die Bewegung der Kamera zu verhindern, während die Maus über einem Menüelement hovert.
|
||||||
|
|
||||||
private void OnEnable()
|
private void OnEnable()
|
||||||
{
|
{
|
||||||
@@ -30,13 +30,13 @@ public class OrbitCameraMouseControl : MonoBehaviour
|
|||||||
|
|
||||||
if (inputAxisController != null) // aimingBlocked wird durch hover States der Menü-Elemente gesetzt
|
if (inputAxisController != null) // aimingBlocked wird durch hover States der Menü-Elemente gesetzt
|
||||||
{
|
{
|
||||||
inputAxisController.Controllers[0].Enabled = isAiming;
|
inputAxisController.Controllers[0].Enabled = isAiming; // Die X und Y-Achse der der Orbit-Funktion werden freigeschaltet, solange die aimAction (hier RMT) gedrückt ist.
|
||||||
inputAxisController.Controllers[1].Enabled = isAiming;
|
inputAxisController.Controllers[1].Enabled = isAiming;
|
||||||
inputAxisController.Controllers[2].Enabled = !aimingBlocked;
|
inputAxisController.Controllers[2].Enabled = !aimingBlocked; // Die Scroll-Funktion ist freigeschaltet, solange die Maus nicht über einem Menüelement hovert.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetBlocker(bool value)
|
public void SetBlocker(bool value) // mit dieser Funktion kann der Blocker durch andere Skripte gesetzt werden.
|
||||||
{
|
{
|
||||||
aimingBlocked = value;
|
aimingBlocked = value;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
using GhostSystem;
|
using GhostSystem;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Dieses Script ist für die Färbung erfasster Objekte zuständig.
|
||||||
|
|
||||||
public class RecieveHeat : MonoBehaviour
|
public class RecieveHeat : MonoBehaviour
|
||||||
{
|
{
|
||||||
public Renderer myRenderer;
|
public Renderer myRenderer;
|
||||||
@@ -10,20 +12,20 @@ public class RecieveHeat : MonoBehaviour
|
|||||||
|
|
||||||
private async void OnEnable()
|
private async void OnEnable()
|
||||||
{
|
{
|
||||||
GhostReplayManager.OnRestartLoop += HandleRestartLoop;
|
GhostReplayManager.OnRestartLoop += HandleRestartLoop; // Das Event OnRestartLoop des GhostReplayManagers wird abonniert, um die Färbung der Objekte zurücksetzen zu
|
||||||
}
|
} // können, wenn das Replay neu startet.
|
||||||
|
|
||||||
private void OnDisable()
|
private void OnDisable()
|
||||||
{
|
{
|
||||||
GhostReplayManager.OnRestartLoop -= HandleRestartLoop;
|
GhostReplayManager.OnRestartLoop -= HandleRestartLoop;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void HandleRestartLoop()
|
private void HandleRestartLoop() // Stetzt den Heat-Wert und somit die Färbung bei einem Restart des Replays zurück.
|
||||||
{
|
{
|
||||||
SetHeat(0);
|
SetHeat(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void Start()
|
private void Start() // In der Start-Methode wird der Zugriff auf das Material hergestellt.
|
||||||
{
|
{
|
||||||
if (myRenderer == null)
|
if (myRenderer == null)
|
||||||
{
|
{
|
||||||
@@ -33,24 +35,24 @@ public class RecieveHeat : MonoBehaviour
|
|||||||
SetHeat(0);
|
SetHeat(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void SetHeat(float heat)
|
public void SetHeat(float heat) // Diese Funktion kann von anderen Skripten (z.B. dem Raycast-Skript EyeTrackingCollisionPoints) aufgerufen werden, um den Heat-Wert zu setzen.
|
||||||
{
|
{
|
||||||
if (heat > 1f) return;
|
if (heat > 1f) return; // Der Heat-Wert darf 1 nicht übersteigen, da das dem maximalen Rot-Wert von 255 entspricht.
|
||||||
heatLevel = heat;
|
heatLevel = heat;
|
||||||
float redAmount = CalcRedAmount(heatLevel);
|
float redAmount = CalcRedAmount(heatLevel); // der Rot-Wert wird für einen exponentiellen Anstieg innerhalb der Fixationsdauer noch einmal gemappt.
|
||||||
myMat.color = new Color(redAmount,0,0);
|
myMat.color = new Color(redAmount,0,0); // Das Material wird entsprechend stark rot gefärbt.
|
||||||
}
|
}
|
||||||
|
|
||||||
public void AddHeat(float heat)
|
public void AddHeat(float heat) // Diese funktion addiert einen übergebenen Wert zum aktuellen Heat-Wert. Kann ebenfalls durch andere Skripte aufgerufen werden.
|
||||||
{
|
{
|
||||||
heatLevel += heat;
|
heatLevel += heat;
|
||||||
if (heatLevel > 1f) return;
|
if (heatLevel > 1f) return; // Die Funktionsweise entspricht weitesgehend der von SetHeat.
|
||||||
float redAmount = CalcRedAmount(heatLevel);
|
float redAmount = CalcRedAmount(heatLevel);
|
||||||
Debug.Log(gameObject.ToString() + "Heat in: " + heatLevel + "Heat out: " + redAmount);
|
Debug.Log(gameObject.ToString() + "Heat in: " + heatLevel + "Heat out: " + redAmount); // Ein Debug-Log, um den zeitbasierten Anstieg der Färbung zu prüfen.
|
||||||
myMat.color = new Color(redAmount, 0, 0);
|
myMat.color = new Color(redAmount, 0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
private float CalcRedAmount(float xNormalized)
|
private float CalcRedAmount(float xNormalized) // Hier wird der lineare Anstieg in eine exponentielle Funktion überführt.
|
||||||
{
|
{
|
||||||
float y = Mathf.Pow(xNormalized, 0.5f);
|
float y = Mathf.Pow(xNormalized, 0.5f);
|
||||||
return Mathf.Clamp(y, 0f, 1f);
|
return Mathf.Clamp(y, 0f, 1f);
|
||||||
|
|||||||
@@ -4,11 +4,13 @@ using System.Collections.Generic;
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.SceneManagement;
|
using UnityEngine.SceneManagement;
|
||||||
|
|
||||||
|
// Dieses Skript enthält die Methode, die vom Scene-Dropdown in der Menüleiste der AAR-App bei Auswahl einer Szene ausgeführt wird.
|
||||||
|
|
||||||
public class ReplaySceneLoader : MonoBehaviour
|
public class ReplaySceneLoader : MonoBehaviour
|
||||||
{
|
{
|
||||||
public GhostReplayManager replayManager;
|
public GhostReplayManager replayManager;
|
||||||
private int currentScene;
|
private int currentScene;
|
||||||
public void LoadSceneAdditive(int sceneIndex)
|
public void LoadSceneAdditive(int sceneIndex) // Lädt die Szene, die im UI ausgewählt wurde.
|
||||||
{
|
{
|
||||||
sceneIndex += 1; // Um die Basis-Scene nicht zu laden
|
sceneIndex += 1; // Um die Basis-Scene nicht zu laden
|
||||||
if(SceneManager.loadedSceneCount > 1)
|
if(SceneManager.loadedSceneCount > 1)
|
||||||
|
|||||||
@@ -6,6 +6,9 @@ using System.Collections;
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
|
|
||||||
|
// Dieses Script liest die RoomPrefs eines Raums beim Start der Szene aus, aktiviert oder deaktiviert die entsprechenden Objekte und löst das Event aus, dass die Szene vollständig
|
||||||
|
// geladen wurde.
|
||||||
|
|
||||||
public class RoomManager : MonoBehaviour
|
public class RoomManager : MonoBehaviour
|
||||||
{
|
{
|
||||||
public RoomPrefs myRoom;
|
public RoomPrefs myRoom;
|
||||||
@@ -49,7 +52,7 @@ public class RoomManager : MonoBehaviour
|
|||||||
foreach (GameObject enemy in enemies) enemy.SetActive(true);
|
foreach (GameObject enemy in enemies) enemy.SetActive(true);
|
||||||
}
|
}
|
||||||
sceneId = myRoom.sceneId;
|
sceneId = myRoom.sceneId;
|
||||||
OnSceneIdReady?.Invoke(sceneId, doors, targets);
|
OnSceneIdReady?.Invoke(sceneId, doors, targets); // Mit dem Event werden auch einige Informationen wie die SceneID, die Liste der Türen und die Liste der Target-Objekte
|
||||||
|
// an Abonnenten übergeben.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -4,6 +4,8 @@ using System.Collections.Generic;
|
|||||||
using UnityEngine;
|
using UnityEngine;
|
||||||
using UnityEngine.SceneManagement;
|
using UnityEngine.SceneManagement;
|
||||||
|
|
||||||
|
// Dieses Skript ist für das Hinzuladen und Entladen der Szenen zuständig.
|
||||||
|
|
||||||
public class SceneLoader : MonoBehaviour
|
public class SceneLoader : MonoBehaviour
|
||||||
{
|
{
|
||||||
[SerializeField] private int baseSceneIndex;
|
[SerializeField] private int baseSceneIndex;
|
||||||
|
|||||||
@@ -3,6 +3,8 @@ using UnityEngine.UI;
|
|||||||
using TMPro;
|
using TMPro;
|
||||||
using GhostSystem;
|
using GhostSystem;
|
||||||
|
|
||||||
|
// Dieses Skript wurde nur zu Debug-Zwecken verwendet, um zu sehen, ob auch alle gewünschten Objekte getrackt wurden.
|
||||||
|
|
||||||
public class VRDebugger : MonoBehaviour
|
public class VRDebugger : MonoBehaviour
|
||||||
{
|
{
|
||||||
public TMP_Text trackedObjects;
|
public TMP_Text trackedObjects;
|
||||||
|
|||||||
@@ -12,28 +12,28 @@ EditorBuildSettings:
|
|||||||
path: Assets/Scenes/BasicScene.unity
|
path: Assets/Scenes/BasicScene.unity
|
||||||
guid: bc761d9a86b33554f85fd11bb1f87ba3
|
guid: bc761d9a86b33554f85fd11bb1f87ba3
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/SampleScene Copy.unity
|
path: Assets/_Scenes/Debug and Test Scenes for Multiplayer/SampleScene Copy.unity
|
||||||
guid: d1d4beef77e60314b84afec3230e2311
|
guid: d1d4beef77e60314b84afec3230e2311
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/TestScene.unity
|
path: Assets/_Scenes/Scenes not in use/TestScene.unity
|
||||||
guid: 95fce99b6a2e1fa448d27ff8d88c7bef
|
guid: 95fce99b6a2e1fa448d27ff8d88c7bef
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/TestSceneMeta.unity
|
path: Assets/_Scenes/BaseSceneMeta.unity
|
||||||
guid: 91bfb95032feb044c81a3964f5553fec
|
guid: 91bfb95032feb044c81a3964f5553fec
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: "Assets/Samples/Meta XR Interaction \u200BSDK/76.0.1/Example Scenes/ComprehensiveRigExample.unity"
|
path: "Assets/Samples/Meta XR Interaction \u200BSDK/76.0.1/Example Scenes/ComprehensiveRigExample.unity"
|
||||||
guid: 2efe93cb8972cae439bfba2dcd4165f0
|
guid: 2efe93cb8972cae439bfba2dcd4165f0
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/NoPortals.unity
|
path: Assets/_Scenes/Scenes not in use/NoPortals.unity
|
||||||
guid: 81d48c986e5269c4ba9aecee678c8204
|
guid: 81d48c986e5269c4ba9aecee678c8204
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/VRHomeSceneMeta Offline.unity
|
path: Assets/_Scenes/Debug and Test Scenes for Multiplayer/VRHomeSceneMeta Offline.unity
|
||||||
guid: b98b0de9fe670d2469cfbcd6e1d2d8f5
|
guid: b98b0de9fe670d2469cfbcd6e1d2d8f5
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/TrainingObserverMeta.unity
|
path: Assets/_Scenes/TrainingObserverMeta.unity
|
||||||
guid: 0572ea139ec37b84b88a8d21771f7f1a
|
guid: 0572ea139ec37b84b88a8d21771f7f1a
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/NetworkTest.unity
|
path: Assets/_Scenes/Debug and Test Scenes for Multiplayer/NetworkTest.unity
|
||||||
guid: b5976c62b73452e43a494b19eee50119
|
guid: b5976c62b73452e43a494b19eee50119
|
||||||
- enabled: 0
|
- enabled: 0
|
||||||
path: Assets/_Scenes/Scene.unity
|
path: Assets/_Scenes/Scene.unity
|
||||||
|
|||||||
Reference in New Issue
Block a user