diff --git a/Assets/Icons/remove.png b/Assets/Icons/remove.png new file mode 100644 index 0000000000000000000000000000000000000000..47344fb7a5f5404ac503e6406478f6d45dc3b368 Binary files /dev/null and b/Assets/Icons/remove.png differ diff --git a/Assets/Icons/remove.png.meta b/Assets/Icons/remove.png.meta new file mode 100644 index 0000000000000000000000000000000000000000..a09435d35377c6e3439e773a6ea9b788616370d9 --- /dev/null +++ b/Assets/Icons/remove.png.meta @@ -0,0 +1,140 @@ +fileFormatVersion: 2 +guid: 1f7e5f686df183d4ca1c96949b4e83c1 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 12 + mipmaps: + mipMapMode: 0 + enableMipMap: 0 + sRGBTexture: 1 + linearTexture: 0 + fadeOut: 0 + borderMipMap: 0 + mipMapsPreserveCoverage: 0 + alphaTestReferenceValue: 0.5 + mipMapFadeDistanceStart: 1 + mipMapFadeDistanceEnd: 3 + bumpmap: + convertToNormalMap: 0 + externalNormalMap: 0 + heightScale: 0.25 + normalMapFilter: 0 + flipGreenChannel: 0 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMipmapLimit: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 0 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 100 + spriteBorder: {x: 0, y: 0, z: 0, w: 0} + spriteGenerateFallbackPhysicsShape: 1 + alphaUsage: 1 + alphaIsTransparency: 1 + spriteTessellationDetail: -1 + textureType: 8 + textureShape: 1 + singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 + maxTextureSizeSet: 0 + compressionQualitySet: 0 + textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 0 + swizzle: 50462976 + cookieLightType: 0 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + ignorePlatformSupport: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + nameFileIdTable: {} + mipmapLimitGroupName: + pSDRemoveMatte: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Material 1.mat b/Assets/Material 1.mat index 536c372f35bcc033afdc8e0575d90816561fe805..1e020ed7745a4474fae15276a66c7d69185a150a 100644 --- a/Assets/Material 1.mat +++ b/Assets/Material 1.mat @@ -15,7 +15,7 @@ Material: m_InvalidKeywords: [] m_LightmapFlags: 4 m_EnableInstancingVariants: 0 - m_DoubleSidedGI: 0 + m_DoubleSidedGI: 1 m_CustomRenderQueue: -1 stringTagMap: RenderType: Opaque @@ -89,7 +89,7 @@ Material: - _BumpScale: 1 - _ClearCoatMask: 0 - _ClearCoatSmoothness: 0 - - _Cull: 2 + - _Cull: 0 - _Cutoff: 0.5 - _DetailAlbedoMapScale: 1 - _DetailNormalMapScale: 1 diff --git a/Assets/Prefabs/BlockSelect.prefab b/Assets/Prefabs/BlockSelect.prefab index cd12e9e8e4924444a615500b21ac11b499a8d35b..f66899392de5da2af1b5b9c6aa4fe24d6ece7787 100644 --- a/Assets/Prefabs/BlockSelect.prefab +++ b/Assets/Prefabs/BlockSelect.prefab @@ -14,8 +14,8 @@ GameObject: - component: {fileID: 1779685088826987312} - component: {fileID: 3268846158774871891} - component: {fileID: -4358216392600172306} - - component: {fileID: 7216982225745790517} - component: {fileID: -5980889118735951575} + - component: {fileID: -2647738392038745357} m_Layer: 0 m_Name: BlockSelect m_TagString: surface @@ -140,7 +140,20 @@ MonoBehaviour: RotateAnchorPrefab: {fileID: 2874721107243629612, guid: 12accfaeb3e281a48acb41e0100ee76d, type: 3} inputTransform: {fileID: 0} activateRotationEvent: {fileID: 4987378303488695193, guid: c348712bda248c246b8c49b3db54643f, type: 3} ---- !u!114 &7216982225745790517 +--- !u!114 &-5980889118735951575 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8126816444565180231} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2f2c9d2fbf2ef104992bb5e55dae6b42, type: 3} + m_Name: + m_EditorClassIdentifier: + selectPointsController: {fileID: 0} +--- !u!114 &-2647738392038745357 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -164,7 +177,7 @@ MonoBehaviour: m_FocusMode: 1 m_CustomReticle: {fileID: 0} m_AllowGazeInteraction: 0 - m_AllowGazeSelect: 0 + m_AllowGazeSelect: 1 m_OverrideGazeTimeToSelect: 0 m_GazeTimeToSelect: 0.5 m_OverrideTimeToAutoDeselectGaze: 0 @@ -190,7 +203,19 @@ MonoBehaviour: m_Calls: [] m_SelectEntered: m_PersistentCalls: - m_Calls: [] + m_Calls: + - m_Target: {fileID: -5980889118735951575} + m_TargetAssemblyTypeName: BlockSelect, Assembly-CSharp + m_MethodName: DeleteSelection + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 m_SelectExited: m_PersistentCalls: m_Calls: [] @@ -242,16 +267,3 @@ MonoBehaviour: m_OnDeactivate: m_PersistentCalls: m_Calls: [] ---- !u!114 &-5980889118735951575 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 8126816444565180231} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 2f2c9d2fbf2ef104992bb5e55dae6b42, type: 3} - m_Name: - m_EditorClassIdentifier: - selectPointsController: {fileID: 0} diff --git a/Assets/Prefabs/FittedQuad.prefab b/Assets/Prefabs/FittedQuad.prefab new file mode 100644 index 0000000000000000000000000000000000000000..7ffb451134a947390441ebb30d540eec656c3cb7 --- /dev/null +++ b/Assets/Prefabs/FittedQuad.prefab @@ -0,0 +1,327 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &2123888734268900958 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7415406206536596469} + - component: {fileID: 6085268248900285533} + - component: {fileID: 1362285220292941322} + - component: {fileID: 7157457943888117503} + - component: {fileID: 2186370549273694175} + - component: {fileID: -2410014600031643114} + - component: {fileID: 7780733699600987831} + - component: {fileID: -4630001669494647888} + m_Layer: 0 + m_Name: FittedQuad + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7415406206536596469 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + 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!33 &6085268248900285533 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &1362285220292941322 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + 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_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: f7d23c7a57a992c4282494782cba5215, 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!64 &7157457943888117503 +MeshCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + 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: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!54 &2186370549273694175 +Rigidbody: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + serializedVersion: 4 + m_Mass: 1 + m_Drag: 0 + m_AngularDrag: 0.05 + m_CenterOfMass: {x: 0, y: 0, z: 0} + m_InertiaTensor: {x: 1, y: 1, z: 1} + m_InertiaRotation: {x: 0, y: 0, z: 0, w: 1} + m_IncludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ExcludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ImplicitCom: 1 + m_ImplicitTensor: 1 + m_UseGravity: 0 + m_IsKinematic: 1 + m_Interpolate: 0 + m_Constraints: 0 + m_CollisionDetection: 0 +--- !u!114 &-2410014600031643114 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0ad34abafad169848a38072baa96cdb2, type: 3} + m_Name: + m_EditorClassIdentifier: + m_InteractionManager: {fileID: 0} + m_Colliders: [] + m_InteractionLayerMask: + serializedVersion: 2 + m_Bits: 4294967295 + m_InteractionLayers: + m_Bits: 1 + m_DistanceCalculationMode: 1 + m_SelectMode: 0 + m_FocusMode: 1 + m_CustomReticle: {fileID: 0} + m_AllowGazeInteraction: 1 + m_AllowGazeSelect: 1 + m_OverrideGazeTimeToSelect: 0 + m_GazeTimeToSelect: 0.5 + m_OverrideTimeToAutoDeselectGaze: 0 + m_TimeToAutoDeselectGaze: 3 + m_AllowGazeAssistance: 0 + m_FirstHoverEntered: + m_PersistentCalls: + m_Calls: [] + m_LastHoverExited: + m_PersistentCalls: + m_Calls: [] + m_HoverEntered: + m_PersistentCalls: + m_Calls: [] + m_HoverExited: + m_PersistentCalls: + m_Calls: [] + m_FirstSelectEntered: + m_PersistentCalls: + m_Calls: [] + m_LastSelectExited: + m_PersistentCalls: + m_Calls: [] + m_SelectEntered: + m_PersistentCalls: + m_Calls: [] + m_SelectExited: + m_PersistentCalls: + m_Calls: [] + m_FirstFocusEntered: + m_PersistentCalls: + m_Calls: [] + m_LastFocusExited: + m_PersistentCalls: + m_Calls: [] + m_FocusEntered: + m_PersistentCalls: + m_Calls: [] + m_FocusExited: + m_PersistentCalls: + m_Calls: [] + m_Activated: + m_PersistentCalls: + m_Calls: [] + m_Deactivated: + m_PersistentCalls: + m_Calls: [] + m_StartingHoverFilters: [] + m_StartingSelectFilters: [] + m_StartingInteractionStrengthFilters: [] + m_OnFirstHoverEntered: + m_PersistentCalls: + m_Calls: [] + m_OnLastHoverExited: + m_PersistentCalls: + m_Calls: [] + m_OnHoverEntered: + m_PersistentCalls: + m_Calls: [] + m_OnHoverExited: + m_PersistentCalls: + m_Calls: [] + m_OnSelectEntered: + m_PersistentCalls: + m_Calls: [] + m_OnSelectExited: + m_PersistentCalls: + m_Calls: [] + m_OnSelectCanceled: + m_PersistentCalls: + m_Calls: [] + m_OnActivate: + m_PersistentCalls: + m_Calls: [] + m_OnDeactivate: + m_PersistentCalls: + m_Calls: [] + m_AttachTransform: {fileID: 0} + m_SecondaryAttachTransform: {fileID: 0} + m_UseDynamicAttach: 0 + m_MatchAttachPosition: 1 + m_MatchAttachRotation: 1 + m_SnapToColliderVolume: 1 + m_ReinitializeDynamicAttachEverySingleGrab: 1 + m_AttachEaseInTime: 0.15 + m_MovementType: 2 + m_VelocityDamping: 1 + m_VelocityScale: 1 + m_AngularVelocityDamping: 1 + m_AngularVelocityScale: 1 + m_TrackPosition: 1 + m_SmoothPosition: 0 + m_SmoothPositionAmount: 8 + m_TightenPosition: 0.1 + m_TrackRotation: 0 + m_SmoothRotation: 0 + m_SmoothRotationAmount: 8 + m_TightenRotation: 0.1 + m_TrackScale: 0 + m_SmoothScale: 0 + m_SmoothScaleAmount: 8 + m_TightenScale: 0.1 + m_ThrowOnDetach: 0 + m_ThrowSmoothingDuration: 0.25 + m_ThrowSmoothingCurve: + serializedVersion: 2 + m_Curve: + - serializedVersion: 3 + time: 1 + value: 1 + inSlope: 0 + outSlope: 0 + tangentMode: 0 + weightedMode: 0 + inWeight: 0 + outWeight: 0 + m_PreInfinity: 2 + m_PostInfinity: 2 + m_RotationOrder: 4 + m_ThrowVelocityScale: 1.5 + m_ThrowAngularVelocityScale: 1 + m_ForceGravityOnDetach: 0 + m_RetainTransformParent: 1 + m_AttachPointCompatibilityMode: 0 + m_StartingSingleGrabTransformers: [] + m_StartingMultipleGrabTransformers: [] + m_AddDefaultGrabTransformers: 0 +--- !u!114 &7780733699600987831 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d0a1302d0d134fa8a2a5b3bf4aec3c20, type: 3} + m_Name: + m_EditorClassIdentifier: + m_PermittedDisplacementAxes: 3 + m_ConstrainedAxisDisplacementMode: 0 + m_TwoHandedRotationMode: 1 + m_AllowOneHandedScaling: 1 + m_AllowTwoHandedScaling: 0 + m_OneHandedScaleSpeed: 0.5 + m_ThresholdMoveRatioForScale: 0.05 + m_ClampScaling: 1 + m_MinimumScaleRatio: 0.25 + m_MaximumScaleRatio: 2 + m_ScaleMultiplier: 0.25 +--- !u!114 &-4630001669494647888 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2123888734268900958} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 20838c10ccf6e2746824ba579c0e1e09, type: 3} + m_Name: + m_EditorClassIdentifier: + vertexPointPrefab: {fileID: 8138111287210361984, guid: 5d21b49507ba4104f983122e372d6595, type: 3} diff --git a/Assets/Prefabs/FittedQuad.prefab.meta b/Assets/Prefabs/FittedQuad.prefab.meta new file mode 100644 index 0000000000000000000000000000000000000000..4e8647a208c7518f06cffcd444f80d5b1014b4e4 --- /dev/null +++ b/Assets/Prefabs/FittedQuad.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: acca7dbb0ace2e64c84057ecdceb3e15 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/VertexPoint.prefab b/Assets/Prefabs/VertexPoint.prefab index ac93c220155e8a8923439dd81a859c4d25826f36..2780af8518e2d75d4971cd9762b167847b5dadd8 100644 --- a/Assets/Prefabs/VertexPoint.prefab +++ b/Assets/Prefabs/VertexPoint.prefab @@ -15,7 +15,7 @@ GameObject: - component: {fileID: 492798701434058740} - component: {fileID: 4136171038367357647} - component: {fileID: 1183694293685742046} - - component: {fileID: -2749897353397705518} + - component: {fileID: 5808971997871397969} m_Layer: 0 m_Name: VertexPoint m_TagString: Untagged @@ -33,7 +33,7 @@ Transform: serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 1.016, z: 3.35} - m_LocalScale: {x: 0.02, y: 0.02, z: 0.02} + m_LocalScale: {x: 0.03, y: 0.03, z: 0.03} m_ConstrainProportionsScale: 1 m_Children: [] m_Father: {fileID: 0} @@ -255,15 +255,15 @@ MonoBehaviour: m_SmoothPosition: 0 m_SmoothPositionAmount: 8 m_TightenPosition: 0.1 - m_TrackRotation: 1 + m_TrackRotation: 0 m_SmoothRotation: 0 m_SmoothRotationAmount: 8 m_TightenRotation: 0.1 - m_TrackScale: 1 + m_TrackScale: 0 m_SmoothScale: 0 m_SmoothScaleAmount: 8 m_TightenScale: 0.1 - m_ThrowOnDetach: 1 + m_ThrowOnDetach: 0 m_ThrowSmoothingDuration: 0.25 m_ThrowSmoothingCurve: serializedVersion: 2 @@ -300,18 +300,18 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: d0a1302d0d134fa8a2a5b3bf4aec3c20, type: 3} m_Name: m_EditorClassIdentifier: - m_PermittedDisplacementAxes: -1 - m_ConstrainedAxisDisplacementMode: 1 + m_PermittedDisplacementAxes: 3 + m_ConstrainedAxisDisplacementMode: 0 m_TwoHandedRotationMode: 1 - m_AllowOneHandedScaling: 1 + m_AllowOneHandedScaling: 0 m_AllowTwoHandedScaling: 0 m_OneHandedScaleSpeed: 0.5 m_ThresholdMoveRatioForScale: 0.05 - m_ClampScaling: 1 + m_ClampScaling: 0 m_MinimumScaleRatio: 0.25 m_MaximumScaleRatio: 2 m_ScaleMultiplier: 0.25 ---- !u!114 &-2749897353397705518 +--- !u!114 &5808971997871397969 MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} @@ -320,7 +320,6 @@ MonoBehaviour: m_GameObject: {fileID: 8138111287210361984} m_Enabled: 1 m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 98b85445213936746822c3b05e91cac9, type: 3} + m_Script: {fileID: 11500000, guid: 7b4454cab98497f4b851b9f82db76cc5, type: 3} m_Name: m_EditorClassIdentifier: - parentBlockDeform: {fileID: 0} diff --git a/Assets/Samples/XR Interaction Toolkit/2.4.3/Starter Assets/XRI Default Input Actions.inputactions b/Assets/Samples/XR Interaction Toolkit/2.4.3/Starter Assets/XRI Default Input Actions.inputactions index 8efdc9bd3b7711e46ac3678bfa3fd52fa4b2b678..0b9655246e174680855a1cfeea5e6d8a3d445341 100644 --- a/Assets/Samples/XR Interaction Toolkit/2.4.3/Starter Assets/XRI Default Input Actions.inputactions +++ b/Assets/Samples/XR Interaction Toolkit/2.4.3/Starter Assets/XRI Default Input Actions.inputactions @@ -703,7 +703,7 @@ "initialStateCheck": true }, { - "name": "save", + "name": "Fit plane", "type": "Button", "id": "0031af44-5ced-4637-b320-dd79ef962b71", "expectedControlType": "Button", @@ -881,7 +881,18 @@ "interactions": "", "processors": "", "groups": "", - "action": "save", + "action": "Fit plane", + "isComposite": false, + "isPartOfComposite": false + }, + { + "name": "", + "id": "bde33330-5b67-481b-874a-35bf06a2a347", + "path": "<XRController>{LeftHand}/{PrimaryButton}", + "interactions": "", + "processors": "", + "groups": "Generic XR Controller", + "action": "Fit plane", "isComposite": false, "isPartOfComposite": false }, diff --git a/Assets/Scenes/SampleScene.unity b/Assets/Scenes/SampleScene.unity index 1a459deebf13d9e73d3d6ef22bf44cf6ebbe94a9..b9b3e57f8941732ce0b7d54936f79d4218fa636d 100644 --- a/Assets/Scenes/SampleScene.unity +++ b/Assets/Scenes/SampleScene.unity @@ -1940,6 +1940,7 @@ MonoBehaviour: - {fileID: 21300000, guid: 4782d855ca5a1534fb4e4c26dde1613d, type: 3} - {fileID: 21300000, guid: 0e952cbc137866843ab0f0aaac310dba, type: 3} - {fileID: 21300000, guid: 17e123028362b864f8cffc152bb19615, type: 3} + - {fileID: 21300000, guid: 1f7e5f686df183d4ca1c96949b4e83c1, type: 3} --- !u!1 &143237140 GameObject: m_ObjectHideFlags: 0 @@ -3900,6 +3901,12 @@ PrefabInstance: - targetCorrespondingSourceObject: {fileID: 1035790433963668018, guid: 085ce58b196caa446a8545c9dd388793, type: 3} insertIndex: -1 addedObject: {fileID: 1146522988} + - targetCorrespondingSourceObject: {fileID: 1035790433963668018, guid: 085ce58b196caa446a8545c9dd388793, type: 3} + insertIndex: -1 + addedObject: {fileID: 1855450724} + - targetCorrespondingSourceObject: {fileID: 1035790433963668018, guid: 085ce58b196caa446a8545c9dd388793, type: 3} + insertIndex: -1 + addedObject: {fileID: 1338359539} - targetCorrespondingSourceObject: {fileID: 1035790433963668018, guid: 085ce58b196caa446a8545c9dd388793, type: 3} insertIndex: -1 addedObject: {fileID: 301465756} @@ -5766,6 +5773,8 @@ MonoBehaviour: pointClouds: - {fileID: 1565662007} selectPointsEventAction: {fileID: -1827717145013635445, guid: c348712bda248c246b8c49b3db54643f, type: 3} + spawnPrefab: {fileID: 2123888734268900958, guid: acca7dbb0ace2e64c84057ecdceb3e15, type: 3} + maxNumberOfPoints: 300 --- !u!1001 &427008753 PrefabInstance: m_ObjectHideFlags: 0 @@ -16115,6 +16124,212 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1326031627} m_CullTransparentMesh: 1 +--- !u!1001 &1338359538 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + serializedVersion: 3 + m_TransformParent: {fileID: 449044966} + m_Modifications: + - target: {fileID: 169305219790147484, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Enabled + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.x + value: 220 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431699, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Name + value: Export List Item Button (2) + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_RootOrder + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.y + value: 60 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259952709508, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_IsActive + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 3199508834110206841, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_text + value: Clear Selection + objectReference: {fileID: 0} + - target: {fileID: 3199508834110206841, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_fontSize + value: 16 + objectReference: {fileID: 0} + - target: {fileID: 3199508834110206841, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_enableAutoSizing + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5443163050158697355, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Enabled + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.x + value: 130.732 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.size + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_Mode + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_Target + value: + objectReference: {fileID: 426651924} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_CallState + value: 2 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_MethodName + value: ClearSelection + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_TargetAssemblyTypeName + value: SelectPointsController, Assembly-CSharp + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_Arguments.m_ObjectArgumentAssemblyTypeName + value: UnityEngine.Object, UnityEngine + objectReference: {fileID: 0} + - target: {fileID: 8488948026688725845, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Enabled + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 8781133472592516893, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_PokeFillMaxSizeX + value: 235 + objectReference: {fileID: 0} + - target: {fileID: 8781133472592516893, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_PokeFillMaxSizeY + value: 60 + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_RemovedGameObjects: [] + m_AddedGameObjects: [] + m_AddedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} +--- !u!224 &1338359539 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + m_PrefabInstance: {fileID: 1338359538} + m_PrefabAsset: {fileID: 0} --- !u!1 &1341980719 GameObject: m_ObjectHideFlags: 0 @@ -21802,6 +22017,212 @@ PrefabInstance: addedObject: {fileID: 1385002796} m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 65eb6b98091a5734ba9d9ca871cef69a, type: 3} +--- !u!1001 &1855450723 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + serializedVersion: 3 + m_TransformParent: {fileID: 449044966} + m_Modifications: + - target: {fileID: 169305219790147484, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Enabled + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.x + value: 220 + objectReference: {fileID: 0} + - target: {fileID: 1248386867110803025, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431699, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Name + value: Export List Item Button (1) + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Pivot.x + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Pivot.y + value: 0.5 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_RootOrder + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.y + value: 60 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2397425259952709508, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_IsActive + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 3199508834110206841, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_text + value: Export Mesh + objectReference: {fileID: 0} + - target: {fileID: 3199508834110206841, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_fontSize + value: 16 + objectReference: {fileID: 0} + - target: {fileID: 3199508834110206841, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_enableAutoSizing + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 5443163050158697355, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Enabled + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMax.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchorMin.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_SizeDelta.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.x + value: 130.732 + objectReference: {fileID: 0} + - target: {fileID: 6150670977401591343, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_AnchoredPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.size + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_Mode + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_Target + value: + objectReference: {fileID: 426651922} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_CallState + value: 2 + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_MethodName + value: LoadProgram + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_TargetAssemblyTypeName + value: ProgramController, Assembly-CSharp + objectReference: {fileID: 0} + - target: {fileID: 7753147258609537286, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_OnClick.m_PersistentCalls.m_Calls.Array.data[0].m_Arguments.m_ObjectArgumentAssemblyTypeName + value: UnityEngine.Object, UnityEngine + objectReference: {fileID: 0} + - target: {fileID: 8488948026688725845, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_Enabled + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 8781133472592516893, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_PokeFillMaxSizeX + value: 235 + objectReference: {fileID: 0} + - target: {fileID: 8781133472592516893, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + propertyPath: m_PokeFillMaxSizeY + value: 60 + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_RemovedGameObjects: [] + m_AddedGameObjects: [] + m_AddedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} +--- !u!224 &1855450724 stripped +RectTransform: + m_CorrespondingSourceObject: {fileID: 2397425259038431700, guid: fa5ef3b56cfeb4f4ba855cdf2610a578, type: 3} + m_PrefabInstance: {fileID: 1855450723} + m_PrefabAsset: {fileID: 0} --- !u!4 &1859349198 stripped Transform: m_CorrespondingSourceObject: {fileID: 7785151267686525226, guid: 048249d9a15aa3c459399751e860bde7, type: 3} diff --git a/Assets/Scrips/Components/Block/BlockRotate.cs b/Assets/Scrips/Components/Block/BlockRotate.cs index 35455b581d9bb54def233e8b9b11d30903d1025b..6853fb4fc4b025a39826252cd5197c4e736e11c1 100644 --- a/Assets/Scrips/Components/Block/BlockRotate.cs +++ b/Assets/Scrips/Components/Block/BlockRotate.cs @@ -36,8 +36,6 @@ public class BlockRotate : MonoBehaviour _rotateAnchor.transform.position = inputTransform.position + inputTransform.forward * 0.5f; } } - - if (mode == EditState.EditType.Deform) _rotateAnchor.SetActive(false); } public void HandleRotateAnchor() @@ -86,18 +84,18 @@ public class BlockRotate : MonoBehaviour } } - private void FixedUpdate() - { - EditState.EditType mode = EditState.Instance.ActiveEditState; - _rotateAnchor.SetActive(mode == EditState.EditType.Rotate); - } - // Start is called before the first frame update void Start() { _rotateAnchor = Instantiate(RotateAnchorPrefab, this.transform.position, Quaternion.identity); _rotateAnchor.GetComponent<RotateAnchor>().Initialize(this); _rotateAnchor.SetActive(false); + EditState.Instance.RegisterListener(EditStateHandler); } + private void EditStateHandler() + { + EditState.EditType mode = EditState.Instance.ActiveEditState; + _rotateAnchor.SetActive(mode == EditState.EditType.Rotate); + } } diff --git a/Assets/Scrips/Components/Quad.meta b/Assets/Scrips/Components/Quad.meta new file mode 100644 index 0000000000000000000000000000000000000000..a8a133ed50a8d1d8cc449526b2019683caea053d --- /dev/null +++ b/Assets/Scrips/Components/Quad.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 08edbe1de8e72754a823b9681e1bc68e +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scrips/Components/Quad/FittedQuad.cs b/Assets/Scrips/Components/Quad/FittedQuad.cs new file mode 100644 index 0000000000000000000000000000000000000000..42c9fb5afc0132a8ebf3fb4e178a34fbf66f5387 --- /dev/null +++ b/Assets/Scrips/Components/Quad/FittedQuad.cs @@ -0,0 +1,73 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.XR.Interaction.Toolkit; + +public class FittedQuad : MonoBehaviour +{ + public GameObject vertexPointPrefab; + private Mesh _mesh; + private readonly GameObject[] _vertexAnchors = new GameObject[4]; + + private void Awake() + { + _mesh = this.GetComponent<MeshFilter>().mesh; + } + + private void Start() + { + InitAnchors(); + EditState.Instance.RegisterListener(EditStateHandler); + } + + private void EditStateHandler() + { + EditState.EditType mode = EditState.Instance.ActiveEditState; + foreach (GameObject anchor in _vertexAnchors) + { + anchor.SetActive(mode == EditState.EditType.Deform); + } + + this.GetComponent<XRGrabInteractable>().enabled = mode == EditState.EditType.Deform; + } + + private void InitAnchors() + { + Vector3[] vertices = _mesh.vertices; + for (int i = 0; i < vertices.Length; i++) + { + Vector3 vertex = vertices[i]; + GameObject anchor = Instantiate(vertexPointPrefab, this.transform.position, Quaternion.identity); + anchor.transform.parent = this.transform; + anchor.transform.localPosition = vertex; + anchor.transform.LookAt(anchor.transform.position + this.transform.forward); + _vertexAnchors[i] = anchor; + anchor.GetComponent<VertexPoint>().SetParentQuad(this); + } + } + + public void UpdateVertices() + { + Vector3[] vertices = _mesh.vertices; + for (int i = 0; i < vertices.Length; i++) + { + vertices[i] = _vertexAnchors[i].transform.localPosition; + } + + _mesh.vertices = vertices; + _mesh.RecalculateBounds(); + MeshCollider collider = GetComponent<MeshCollider>(); + collider.sharedMesh = _mesh; + } + + public void SetAnchors(Vector3[] positions) + { + for (int i = 0; i < positions.Length; i++) + { + _vertexAnchors[i].transform.localPosition = positions[i]; + } + + UpdateVertices(); + } +} diff --git a/Assets/Scrips/Components/Quad/FittedQuad.cs.meta b/Assets/Scrips/Components/Quad/FittedQuad.cs.meta new file mode 100644 index 0000000000000000000000000000000000000000..2f0dc105a92730c140b7d612ea94da06aa9bf85e --- /dev/null +++ b/Assets/Scrips/Components/Quad/FittedQuad.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 20838c10ccf6e2746824ba579c0e1e09 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scrips/Components/Quad/VertexPoint.cs b/Assets/Scrips/Components/Quad/VertexPoint.cs new file mode 100644 index 0000000000000000000000000000000000000000..74b0bf1d432b3bad25c40b2db89e890d17a91a98 --- /dev/null +++ b/Assets/Scrips/Components/Quad/VertexPoint.cs @@ -0,0 +1,40 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.XR.Interaction.Toolkit; + +public class VertexPoint : MonoBehaviour +{ + private FittedQuad _parentQuad; + private XRGrabInteractable grabInteractable; + private bool _isSelected = false; + + public void SetParentQuad(FittedQuad quad) + { + this._parentQuad = quad; + } + + private void Awake() + { + grabInteractable = GetComponent<XRGrabInteractable>(); + grabInteractable.selectExited.AddListener(HandleSelectExit); + grabInteractable.selectEntered.AddListener(HandleSelectEntered); + } + + private void HandleSelectEntered(SelectEnterEventArgs arg0) + { + _isSelected = true; + } + + private void HandleSelectExit(SelectExitEventArgs arg0) + { + _isSelected = false; + _parentQuad.UpdateVertices(); + } + + private void FixedUpdate() + { + if (_isSelected) _parentQuad.UpdateVertices(); + } +} diff --git a/Assets/Scrips/Components/Quad/VertexPoint.cs.meta b/Assets/Scrips/Components/Quad/VertexPoint.cs.meta new file mode 100644 index 0000000000000000000000000000000000000000..658e57c2236af9ba2981995d3041129c4c84a8aa --- /dev/null +++ b/Assets/Scrips/Components/Quad/VertexPoint.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7b4454cab98497f4b851b9f82db76cc5 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scrips/Components/Selection/BlockSelect.cs b/Assets/Scrips/Components/Selection/BlockSelect.cs index de4de7c906abaa37763cf876d27e49758c8d4ab0..18330a627625d74d3af74856b16880daecdb5fff 100644 --- a/Assets/Scrips/Components/Selection/BlockSelect.cs +++ b/Assets/Scrips/Components/Selection/BlockSelect.cs @@ -1,23 +1,29 @@ +using System; using System.Collections; using System.Collections.Generic; using UnityEngine; +using UnityEngine.XR.Interaction.Toolkit; public class BlockSelect : MonoBehaviour { public SelectPointsController selectPointsController; - // Start is called before the first frame update - void Start() - { + private XRSimpleInteractable _xrSimpleInteractable; + private void Awake() + { + _xrSimpleInteractable = this.GetComponent<XRSimpleInteractable>(); } - // Update is called once per frame - void Update() + public void DeleteSelection() { - + if (EditState.Instance.ActiveEditState == EditState.EditType.Delete) + { + selectPointsController.RemoveSelection(this.gameObject); + } } + private void OnDestroy() { selectPointsController.RemoveSelection(this.gameObject); diff --git a/Assets/Scrips/Contexts/EditState.cs b/Assets/Scrips/Contexts/EditState.cs index 0b30b9cf93fe0fdce1b5357245e52ee6b5c63f70..05caf7cbdfab4ada3f31e1fcb35bd41d6b34d5e3 100644 --- a/Assets/Scrips/Contexts/EditState.cs +++ b/Assets/Scrips/Contexts/EditState.cs @@ -16,11 +16,12 @@ public class EditState : MonoBehaviour { Deform = 0, Rotate = 1, - Select = 2 + Select = 2, + Delete = 3 } public EditType ActiveEditState { get; private set; } - private EditType[] _stateWheel = { EditType.Deform, EditType.Rotate, EditType.Select }; + private EditType[] _stateWheel = { EditType.Deform, EditType.Rotate, EditType.Select, EditType.Delete }; private int _stateIndex = 0; private void SwitchState(InputAction.CallbackContext context) diff --git a/Assets/Scrips/Controllers/MainMenuController.cs b/Assets/Scrips/Controllers/MainMenuController.cs index 942729cee297db6a63783f433b51fb531454ca4d..9224b110422d13bfbfe700a4905fbdd6cbb7fa09 100644 --- a/Assets/Scrips/Controllers/MainMenuController.cs +++ b/Assets/Scrips/Controllers/MainMenuController.cs @@ -35,18 +35,6 @@ public class MainMenuController : MonoBehaviour } } - // Start is called before the first frame update - void Start() - { - - } - - // Update is called once per frame - void Update() - { - - } - private void FixedUpdate() { if (!_menuActive) return; diff --git a/Assets/Scrips/Controllers/ProgramController.cs b/Assets/Scrips/Controllers/ProgramController.cs index bab8b503f3c5c604f86b6db5b06780e9cc28e7be..90e800e50295ce6914c95493363f92cfa42ea513 100644 --- a/Assets/Scrips/Controllers/ProgramController.cs +++ b/Assets/Scrips/Controllers/ProgramController.cs @@ -10,6 +10,7 @@ using UnityEngine.InputSystem; public class ProgramController : MonoBehaviour { private SpawnBlockEvent spawnBlockEvent; + private SelectPointsController selectPointsController; public Transform UserTransform; // public InputActionReference saveEventAction; @@ -19,6 +20,7 @@ public class ProgramController : MonoBehaviour private InputLoader _inputLoad; private readonly List<GameObject> _spawnedBlocks = new(); + private readonly List<GameObject> _spawnedQuads = new(); private string _savePath; private SurrogateSelector _surrogateSelector; @@ -27,6 +29,7 @@ public class ProgramController : MonoBehaviour private void Awake() { spawnBlockEvent = this.GetComponent<SpawnBlockEvent>(); + selectPointsController = this.GetComponent<SelectPointsController>(); this._savePath = Application.persistentDataPath + "/program.save"; // _inputSave = new(saveEventAction, SaveProgram); @@ -44,6 +47,11 @@ public class ProgramController : MonoBehaviour _spawnedBlocks.Add(block); } + public void RegisterQuad(GameObject quad) + { + _spawnedQuads.Add(quad); + } + private Save CreateSave() { Save save = new(); @@ -73,6 +81,21 @@ public class ProgramController : MonoBehaviour save.BlockAnchors.Add(anchorsData); } + foreach (GameObject quad in _spawnedQuads) + { + Vector3[] quadVertices = quad.GetComponent<MeshFilter>().mesh.vertices; + Vector3[] quadData = new Vector3[2 + quadVertices.Length]; + quadData[0] = quad.transform.position; + quadData[1] = -quad.transform.forward; + + for (int i = 0; i < quadVertices.Length; i++) + { + quadData[i + 2] = quadVertices[i]; + } + + save.Quads.Add(quadData); + } + return save; } @@ -98,6 +121,15 @@ public class ProgramController : MonoBehaviour _spawnedBlocks.Clear(); } + if (_spawnedQuads.Count > 0) + { + foreach (GameObject quad in _spawnedQuads) + { + Destroy(quad); + } + _spawnedQuads.Clear(); + } + FileStream fs = File.Open(this._savePath, FileMode.Open); Save save = (Save)_binaryFormatter.Deserialize(fs); @@ -106,6 +138,8 @@ public class ProgramController : MonoBehaviour UserTransform.position = save.UserTransform[0]; UserTransform.eulerAngles = save.UserTransform[1]; spawnBlockEvent.LoadBlocks(save.Blocks, save.BlockAnchors); + + } } diff --git a/Assets/Scrips/Controllers/SelectPointsController.cs b/Assets/Scrips/Controllers/SelectPointsController.cs index 49d587664b5711602912e2ab6d239c046d9f1f85..2ad5cec1718832b00bb1200c395d00b6e5625ca1 100644 --- a/Assets/Scrips/Controllers/SelectPointsController.cs +++ b/Assets/Scrips/Controllers/SelectPointsController.cs @@ -6,7 +6,6 @@ using UnityEngine.InputSystem; using MathNet.Numerics.LinearAlgebra.Factorization; using MathNet.Numerics.LinearAlgebra; using Unity.Mathematics; -using Unity.VisualScripting; public class SelectPointsController : MonoBehaviour { @@ -15,52 +14,31 @@ public class SelectPointsController : MonoBehaviour public InputActionReference selectPointsEventAction; private InputLoader _inputSelectPoints; + public GameObject spawnPrefab; + public int maxNumberOfPoints = 3000; + private List<GameObject> _blockSelections; private List<Vector3> _debugPoints; private List<Vector3> _recalculatedPoints; + private ProgramController _programController; + private void Awake() { _inputSelectPoints = new(selectPointsEventAction, SelectPointsHandler); _blockSelections = new(); _debugPoints = new(); + _programController = this.GetComponent<ProgramController>(); } private void SelectPointsHandler(InputAction.CallbackContext context) { - // double epsilon = 1E-6; List<Vector3> selectedPoints = new(); Transform cloudTransform = pointClouds[0].transform; - // Mesh pointCloudMesh = pointClouds[0].GetComponent<MeshFilter>().mesh; - // Vector3[] cloudVertices = pointCloudMesh.vertices; - // Vector3[] cloudNormals = pointCloudMesh.normals; - // Vector3 cloudNormal = cloudNormals[0]; - // List<Vector3> normalsPerFace = new() - // { - // cloudNormals[0] * pointCloudMesh.vertices[0].magnitude - // }; for (int i = 0; i < _recalculatedPoints.Count; i++) { - // Vector3 pt = cloudVertices[i]; - // if (Vector3.Distance(cloudNormals[i], cloudNormal) < epsilon) - // { - // normalsPerFace.Add(cloudNormals[i] * pt.magnitude); - // } - // else - // { - // Vector3 normalAverage = normalsPerFace[0]; - // if (normalsPerFace.Count > 1) - // { - // for (int j = 1; j < normalsPerFace.Count; j++) - // { - // normalAverage += normalsPerFace[j]; - // } - - // normalAverage /= normalsPerFace.Count; - // } - foreach (GameObject blockSelection in _blockSelections) { MeshCollider collider = blockSelection.GetComponent<MeshCollider>(); @@ -70,79 +48,40 @@ public class SelectPointsController : MonoBehaviour selectedPoints.Add(ptGlobal); } } - - // cloudNormal = cloudNormals[i]; - // normalsPerFace.Clear(); - // normalsPerFace.Add(cloudNormals[i] * pt.magnitude); - // } - } CalculatePlane(selectedPoints); - // CalculatePlaneByAvg(selectedPoints); - Debug.Log("selection"); - } - - private void CalculatePlaneByAvg(List<Vector3> points) - { - int bucketSize = (int)math.floor(points.Count / 3); - Vector3 avg1 = points[0]; - Vector3 avg2 = points[bucketSize]; - Vector3 avg3 = points[2 * bucketSize]; - - for (int i = 1; i < bucketSize; i++) - { - avg1 += points[i]; - avg2 += points[i + bucketSize]; - avg3 += points[i + 2 * bucketSize]; - } - - avg1 /= bucketSize; - avg2 /= bucketSize; - avg3 /= bucketSize; - - Plane plane = new(avg1, avg2, avg3); - Debug.Log(plane); - - _debugPoints.Clear(); - for (int i = 0; i < 200; i++) - { - Vector3 randomPoint = new(UnityEngine.Random.Range(-8f, 8f), UnityEngine.Random.Range(-8f, 8f), UnityEngine.Random.Range(-8f, 8f)); - _debugPoints.Add(ProjectPointOntoPlane(plane, randomPoint)); - } - } - - private void testSvd() - { - Matrix<float> G = Matrix<float>.Build.Dense(4, 4); - Vector<float> point = Vector<float>.Build.Dense(new float[] { 2.3f, 3.35f, 6.1f, 1 }); - G.SetRow(0, point); - point = Vector<float>.Build.Dense(new float[] { 4.3f, 3.4f, 2.9f, 1 }); - G.SetRow(1, point); - point = Vector<float>.Build.Dense(new float[] { 8.3f, 3.45f, 3.12f, 1 }); - G.SetRow(2, point); - point = Vector<float>.Build.Dense(new float[] { 2.3f, 3.3f, 4.05f, 1 }); - G.SetRow(3, point); - - Svd<float> svd = G.Svd(true); - Matrix<float> vt = svd.VT; - Vector<float> planeEq = vt.Row(3); - Debug.Log(planeEq); } private void CalculatePlane(List<Vector3> points) { - // testSvd(); - if (points.Count < 3) { Debug.Log("not enough points to calculate plane"); return; } + if (points.Count > maxNumberOfPoints) + { + double dropChance = maxNumberOfPoints / (double)points.Count; + System.Random rnd = new(); + List<Vector3> newPoints = new(); + foreach (Vector3 v in points) + { + if (rnd.NextDouble() < dropChance) + { + newPoints.Add(v); + } + + if (newPoints.Count >= maxNumberOfPoints) break; + } + points = newPoints; + } + Matrix<float> G = Matrix<float>.Build.Dense(points.Count, 4); for (int i = 0; i < points.Count; i++) { - Vector3 pt = points[i].normalized; + // Vector3 pt = points[i].normalized; + Vector3 pt = points[i]; Vector<float> point = Vector<float>.Build.Dense(new float[] { pt.x, pt.y, pt.z, 1 }); G.SetRow(i, point); } @@ -167,6 +106,33 @@ public class SelectPointsController : MonoBehaviour Vector3 randomPoint = new(UnityEngine.Random.Range(-8f, 8f), UnityEngine.Random.Range(-8f, 8f), UnityEngine.Random.Range(-8f, 8f)); _debugPoints.Add(ProjectPointOntoPlane(plane, randomPoint)); } + + Vector<float> colAvg = G.ColumnSums(); + colAvg /= G.RowCount; + Vector3 pointAvg = new(colAvg[0], colAvg[1], colAvg[2]); + SpawnPlane(ProjectPointOntoPlane(plane, pointAvg), planeNormal); + } + + public GameObject SpawnPlane(Vector3 pos, Vector3 normal) + { + GameObject spawnedObject = Instantiate(spawnPrefab, pos, Quaternion.identity); + spawnedObject.transform.parent = this.transform; + spawnedObject.transform.LookAt(spawnedObject.transform.position - normal); + + _programController.RegisterQuad(spawnedObject); + return spawnedObject; + } + + public void LoadPlanes(List<Vector3[]> planes) + { + foreach (Vector3[] data in planes) + { + GameObject spawnedObject = SpawnPlane(data[0], data[1]); + Vector3[] vertexData = new Vector3[data.Length - 2]; + Array.Copy(data, 2, vertexData, 0, data.Length - 2); + + spawnedObject.GetComponent<FittedQuad>().SetAnchors(vertexData); + } } private Vector3 ProjectPointOntoPlane(Plane plane, Vector3 point) @@ -193,16 +159,35 @@ public class SelectPointsController : MonoBehaviour public void ClearSelection() { + foreach (GameObject selection in _blockSelections) + { + Destroy(selection); + } _blockSelections.Clear(); } public void RemoveSelection(GameObject selection) { _blockSelections.Remove(selection); + Destroy(selection); } // Start is called before the first frame update void Start() + { + CalculateRealPoints(); + EditState.Instance.RegisterListener(EditChangeHandler); + } + + private void EditChangeHandler() + { + // if (EditState.Instance.ActiveEditState != EditState.EditType.Select) + // { + // ClearSelection(); + // } + } + + private void CalculateRealPoints() { _recalculatedPoints = new(); @@ -216,7 +201,7 @@ public class SelectPointsController : MonoBehaviour { cloudNormals[0] * pointCloudMesh.vertices[0].magnitude }; - for (int i = 1; i < pointCloudMesh.vertices.Length; i++) + for (int i = 1; i < cloudVertices.Length; i++) { Vector3 pt = cloudVertices[i]; float distance = Vector3.Distance(cloudNormals[i], cloudNormal); @@ -246,10 +231,4 @@ public class SelectPointsController : MonoBehaviour } } - - // Update is called once per frame - void Update() - { - - } } diff --git a/Assets/Scrips/Utils/Save.cs b/Assets/Scrips/Utils/Save.cs index 2809367944cabd380a699640336a6011ac319c36..f91762c13ad7e620fa9aebcfd59e7bdf468ff5e8 100644 --- a/Assets/Scrips/Utils/Save.cs +++ b/Assets/Scrips/Utils/Save.cs @@ -5,7 +5,12 @@ using UnityEngine; [System.Serializable] public class Save { + // [position, rotation] public Vector3[] UserTransform = new Vector3[2]; + // [position, rotation, vertices...] public List<Vector3[]> Blocks = new(); + // [local position] public List<Vector3[]> BlockAnchors = new(); + // [position, normal, vertices...] + public List<Vector3[]> Quads = new(); } diff --git a/Assets/Settings/Project Configuration/SampleScene.scenetemplate b/Assets/Settings/Project Configuration/SampleScene.scenetemplate index c5491cd07adb4ddcef46cfe801e31a894d4659ee..707e8a0ee61db684ba701fc6b107cfa04bdc41cc 100644 --- a/Assets/Settings/Project Configuration/SampleScene.scenetemplate +++ b/Assets/Settings/Project Configuration/SampleScene.scenetemplate @@ -138,10 +138,12 @@ MonoBehaviour: instantiationMode: 0 - dependency: {fileID: 8300000, guid: d14b106713a74b448bcab90869f1706e, type: 3} instantiationMode: 1 - - dependency: {fileID: 2800000, guid: 976e28fd05dde91429107e5f857f3c89, type: 3} + - dependency: {fileID: 2123888734268900958, guid: acca7dbb0ace2e64c84057ecdceb3e15, type: 3} instantiationMode: 0 - dependency: {fileID: 6275872155353212687, guid: 8b983c20181b75e489cd0b88a44c68f8, type: 3} instantiationMode: 0 + - dependency: {fileID: 2800000, guid: 976e28fd05dde91429107e5f857f3c89, type: 3} + instantiationMode: 0 - dependency: {fileID: 7313654230448209575, guid: 895f6f3c2d334633b5800312285058d2, type: 3} instantiationMode: 0 - dependency: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} @@ -288,6 +290,8 @@ MonoBehaviour: instantiationMode: 0 - dependency: {fileID: 4125421792874400280, guid: 27024f5809f4a4347b9cd7f26a1bdf93, type: 3} instantiationMode: 0 + - dependency: {fileID: 2100000, guid: c07dd69158c788946aa2d944960f264d, type: 2} + instantiationMode: 0 - dependency: {fileID: 2800000, guid: a89d91b09ecb0164ab9d892915bfa299, type: 3} instantiationMode: 0 - dependency: {fileID: 2179057468902719980, guid: f47ad6ac315a3ea428b59e2cac6f2a2e, type: 3} @@ -316,6 +320,8 @@ MonoBehaviour: instantiationMode: 0 - dependency: {fileID: 2800000, guid: 65d31ca9600c4654e886aa7bab36e94b, type: 3} instantiationMode: 0 + - dependency: {fileID: 8138111287210361984, guid: 5d21b49507ba4104f983122e372d6595, type: 3} + instantiationMode: 0 - dependency: {fileID: 2100000, guid: f5cd77343d6ca1949b1d2d7511848832, type: 2} instantiationMode: 0 - dependency: {fileID: 2100000, guid: 456e2158124c0aa40bf9eceb850dfdb4, type: 2} @@ -326,10 +332,12 @@ MonoBehaviour: instantiationMode: 0 - dependency: {fileID: 2100000, guid: 08d0ccc4a501e6645be0c3ee36d0cd20, type: 2} instantiationMode: 0 - - dependency: {fileID: 2800000, guid: 9d65b1540bd55dc4ab02643e09524306, type: 3} + - dependency: {fileID: 2800000, guid: 1f7e5f686df183d4ca1c96949b4e83c1, type: 3} instantiationMode: 0 - dependency: {fileID: 8134302614855669005, guid: c4a645c929982ea41a52b5037ee7d94d, type: 3} instantiationMode: 0 + - dependency: {fileID: 2800000, guid: 9d65b1540bd55dc4ab02643e09524306, type: 3} + instantiationMode: 0 - dependency: {fileID: 2800000, guid: de0113b98aad70a419960e61a7d8d6ef, type: 3} instantiationMode: 0 - dependency: {fileID: 2800000, guid: 89c4d70ec8a71624f9f1ea880312974b, type: 3} diff --git a/Assets/VRTemplateAssets/Prefabs/UI/List Item Button.prefab b/Assets/VRTemplateAssets/Prefabs/UI/List Item Button.prefab index 8bd1f69fea114fb4a729c2f13ff98afd21e7eefb..8b27e6c512b8214b7a19aa91239cf6d14e1dd944 100644 --- a/Assets/VRTemplateAssets/Prefabs/UI/List Item Button.prefab +++ b/Assets/VRTemplateAssets/Prefabs/UI/List Item Button.prefab @@ -31,7 +31,6 @@ RectTransform: m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 5251477148904607974} - m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -69,8 +68,7 @@ MonoBehaviour: m_text: Text Button m_isRightToLeft: 0 m_fontAsset: {fileID: 11400000, guid: fbb7c6a04be6d8341934b839f24b42e1, type: 2} - m_sharedMaterial: {fileID: 4687939059374929122, guid: fbb7c6a04be6d8341934b839f24b42e1, - type: 2} + m_sharedMaterial: {fileID: 4687939059374929122, guid: fbb7c6a04be6d8341934b839f24b42e1, type: 2} m_fontSharedMaterials: [] m_fontMaterial: {fileID: 0} m_fontMaterials: [] @@ -168,7 +166,6 @@ RectTransform: m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 5251477148904607974} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5} @@ -258,7 +255,6 @@ RectTransform: - {fileID: 2397425259952709509} - {fileID: 1248386867110803025} m_Father: {fileID: 0} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 1} m_AnchorMax: {x: 0, y: 1} @@ -304,7 +300,6 @@ RectTransform: m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 2397425259038431700} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0.5} m_AnchorMax: {x: 0.3333, y: 0.5} @@ -342,8 +337,7 @@ MonoBehaviour: m_text: Button m_isRightToLeft: 0 m_fontAsset: {fileID: 11400000, guid: f675742eaf9c20a4f909d78ee7a14fed, type: 2} - m_sharedMaterial: {fileID: 4687939059374929122, guid: f675742eaf9c20a4f909d78ee7a14fed, - type: 2} + m_sharedMaterial: {fileID: 4687939059374929122, guid: f675742eaf9c20a4f909d78ee7a14fed, type: 2} m_fontSharedMaterials: [] m_fontMaterial: {fileID: 0} m_fontMaterials: [] @@ -446,7 +440,6 @@ RectTransform: - {fileID: 6239908032003856518} - {fileID: 5251477148904607974} m_Father: {fileID: 2397425259038431700} - m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0.333, y: 0.5} m_AnchorMax: {x: 1, y: 0.5} @@ -482,10 +475,10 @@ MonoBehaviour: m_SelectOnRight: {fileID: 0} m_Transition: 1 m_Colors: - m_NormalColor: {r: 0.18039216, g: 0.18039216, b: 0.18039216, a: 1} - m_HighlightedColor: {r: 0.13333334, g: 0.13333334, b: 0.13333334, a: 1} - m_PressedColor: {r: 0.38431373, g: 0.38431373, b: 0.38431373, a: 1} - m_SelectedColor: {r: 0.1254902, g: 0.5882353, b: 0.9529412, a: 1} + m_NormalColor: {r: 0.13330276, g: 0.09607513, b: 0.16037738, a: 1} + m_HighlightedColor: {r: 0.101517335, g: 0.06167676, b: 0.13207549, a: 1} + m_PressedColor: {r: 0.4995645, g: 0.33641866, b: 0.5283019, a: 1} + m_SelectedColor: {r: 0.595938, g: 0.368325, b: 0.8396226, a: 1} m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} m_ColorMultiplier: 1 m_FadeDuration: 0.1 @@ -623,8 +616,7 @@ MonoBehaviour: m_MethodName: PlayOneShot m_Mode: 2 m_Arguments: - m_ObjectArgument: {fileID: 8300000, guid: b319a2e4ff8f5d840b82d8635b645d22, - type: 3} + m_ObjectArgument: {fileID: 8300000, guid: b319a2e4ff8f5d840b82d8635b645d22, type: 3} m_ObjectArgumentAssemblyTypeName: UnityEngine.AudioClip, UnityEngine m_IntArgument: 0 m_FloatArgument: 0 @@ -640,8 +632,7 @@ MonoBehaviour: m_MethodName: PlayOneShot m_Mode: 2 m_Arguments: - m_ObjectArgument: {fileID: 8300000, guid: d14b106713a74b448bcab90869f1706e, - type: 3} + m_ObjectArgument: {fileID: 8300000, guid: d14b106713a74b448bcab90869f1706e, type: 3} m_ObjectArgumentAssemblyTypeName: UnityEngine.AudioClip, UnityEngine m_IntArgument: 0 m_FloatArgument: 0 @@ -725,7 +716,6 @@ RectTransform: - {fileID: 3052109201295664413} - {fileID: 4505963342823614472} m_Father: {fileID: 1248386867110803025} - m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -814,7 +804,6 @@ RectTransform: m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1248386867110803025} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} diff --git a/Assets/VRTemplateAssets/Prefabs/UI/Spatial Panel Scroll.prefab b/Assets/VRTemplateAssets/Prefabs/UI/Spatial Panel Scroll.prefab index 27091131e3ac7fa2a83feb3206c950e07faffa8d..f8726970383c531764a2e85e3f0d0e7bac16bd4d 100644 --- a/Assets/VRTemplateAssets/Prefabs/UI/Spatial Panel Scroll.prefab +++ b/Assets/VRTemplateAssets/Prefabs/UI/Spatial Panel Scroll.prefab @@ -112,7 +112,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 0, g: 0.6, b: 1, a: 1} + m_Color: {r: 0.589921, g: 0, b: 1, a: 1} m_RaycastTarget: 0 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 @@ -678,7 +678,7 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: m_Material: {fileID: 0} - m_Color: {r: 0, g: 0, b: 0, a: 0.9019608} + m_Color: {r: 0.038697746, g: 0.017132428, b: 0.066037714, a: 0.9019608} m_RaycastTarget: 1 m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 @@ -911,8 +911,8 @@ MonoBehaviour: m_TargetGraphic: {fileID: 6065537971879471885} m_HandleRect: {fileID: 6233600418098557749} m_Direction: 0 - m_Value: 1 - m_Size: 0.99999994 + m_Value: 0 + m_Size: 1 m_NumberOfSteps: 0 m_OnValueChanged: m_PersistentCalls: @@ -1007,7 +1007,7 @@ MonoBehaviour: m_FallbackScreenDPI: 96 m_DefaultSpriteDPI: 96 m_DynamicPixelsPerUnit: 1 - m_PresetInfoIsWorld: 1 + m_PresetInfoIsWorld: 0 --- !u!114 &3181781652842806179 MonoBehaviour: m_ObjectHideFlags: 0