diff --git a/README.md b/README.md index 7e00864..b7207ff 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,8 @@ [![Generic badge](https://img.shields.io/github/downloads/VRLabs/Spring-Constraint/total?label=Downloads)](https://github.com/VRLabs/Spring-Constraint/releases/latest) [![Generic badge](https://img.shields.io/badge/License-MIT-informational.svg)](https://github.com/VRLabs/Spring-Constraint/blob/main/LICENSE) -[![Generic badge](https://img.shields.io/badge/Unity-2019.4.31f1-lightblue.svg)](https://unity3d.com/unity/whats-new/2019.4.31) +[![Generic badge](https://img.shields.io/badge/Quest-Compatible-green?logo=Meta)](https://img.shields.io/badge/Quest-Compatible-green?logo=Meta) +[![Generic badge](https://img.shields.io/badge/Unity-2022.3.22f1-lightblue?logo=Unity)](https://unity.com/releases/editor/whats-new/2022.3.22) [![Generic badge](https://img.shields.io/badge/SDK-AvatarSDK3-lightblue.svg)](https://vrchat.com/home/download) [![Generic badge](https://img.shields.io/discord/706913824607043605?color=%237289da&label=DISCORD&logo=Discord&style=for-the-badge)](https://discord.vrlabs.dev/) @@ -16,7 +17,6 @@ A constraint system with spring behavior ### ⬇️ [Download Latest Version](https://github.com/VRLabs/Spring-Constraint/releases/latest) - ### 📦 [Add to VRChat Creator Companion](https://vrlabs.dev/packages?package=dev.vrlabs.spring-constraint) @@ -36,6 +36,9 @@ https://github.com/VRLabs/Spring-Constraint/assets/76777936/6a5056c7-9f47-4caf-b * Expand the prefab hierarchy and find ``Spring Target`` * Move ``Spring Target`` outside of ``Spring Constraint`` and place it anywhere in your avatars hierarchy as needed. +> [!NOTE] +> When building for Quest, you will have to remove unsupported components and shaders + ## How to use * Place your objects inside ``Spring Constraints`` -> ``Container``. @@ -48,6 +51,7 @@ https://github.com/VRLabs/Spring-Constraint/assets/76777936/6a5056c7-9f47-4caf-b ```c++ Constraints: 2 +Constraint Depth: 2 ``` ## Hierarchy layout @@ -82,4 +86,3 @@ Spring Constraint is available as-is under MIT. For more information see [LICENS [](https://twitter.com/vrlabsdev "VRLabs") - diff --git a/Spring Constraint.prefab b/Spring Constraint.prefab index 9e0f046..c8f7267 100644 --- a/Spring Constraint.prefab +++ b/Spring Constraint.prefab @@ -23,12 +23,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 394712243593065472} + 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: 49417782017751338} - m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &3308119095573113976 GameObject: @@ -39,7 +40,7 @@ GameObject: serializedVersion: 6 m_Component: - component: {fileID: 5220703081969942638} - - component: {fileID: 972230973390488208} + - component: {fileID: 7767280538986892689} m_Layer: 0 m_Name: Motion m_TagString: Untagged @@ -54,36 +55,138 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 3308119095573113976} + 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: 49417782017751338} - m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1818360608 &972230973390488208 -PositionConstraint: +--- !u!114 &7767280538986892689 +MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 3308119095573113976} m_Enabled: 1 - m_Weight: 1 - m_TranslationAtRest: {x: 0, y: 0, z: 0} - m_TranslationOffset: {x: 0, y: 0, z: 0} - m_AffectTranslationX: 1 - m_AffectTranslationY: 1 - m_AffectTranslationZ: 1 - m_IsContraintActive: 1 - m_IsLocked: 1 - m_Sources: - - sourceTransform: {fileID: 2115832650624258109} - weight: -1 - - sourceTransform: {fileID: 5091597306124984449} - weight: 1.1 - - sourceTransform: {fileID: 5220703081969942638} - weight: 4 + m_EditorHideFlags: 0 + m_Script: {fileID: 1116338486, guid: 58e2f01a24261a14cb82e6d3399e8b16, type: 3} + m_Name: + m_EditorClassIdentifier: + IsActive: 1 + GlobalWeight: 1 + TargetTransform: {fileID: 0} + SolveInLocalSpace: 0 + FreezeToWorld: 0 + RebakeOffsetsWhenUnfrozen: 0 + Locked: 1 + Sources: + source0: + SourceTransform: {fileID: 2115832650624258109} + Weight: -1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source1: + SourceTransform: {fileID: 5091597306124984449} + Weight: 1.1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source2: + SourceTransform: {fileID: 5220703081969942638} + Weight: 4 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source3: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source4: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source5: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source6: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source7: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source8: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source9: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source10: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source11: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source12: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source13: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source14: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source15: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + totalLength: 3 + overflowList: [] + cachedExecutionGroupIndex: 1 + PositionAtRest: {x: 0, y: 0, z: 0} + PositionOffset: {x: 0, y: 0, z: 0} + AffectsPositionX: 1 + AffectsPositionY: 1 + AffectsPositionZ: 1 --- !u!1 &4062263691010510916 GameObject: m_ObjectHideFlags: 0 @@ -109,12 +212,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 4062263691010510916} + serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 0.2, y: 0.2, z: 0.2} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 2115832650624258109} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!33 &6477893524005848734 MeshFilter: @@ -135,10 +239,12 @@ MeshRenderer: 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: @@ -163,6 +269,7 @@ MeshRenderer: m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} --- !u!1 &4514855280554341519 GameObject: m_ObjectHideFlags: 0 @@ -186,15 +293,16 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 4514855280554341519} + 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: - {fileID: 2115832650624258109} - {fileID: 5220703081969942638} - {fileID: 5091597306124984449} m_Father: {fileID: 0} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &9151448971410334137 GameObject: @@ -205,7 +313,7 @@ GameObject: serializedVersion: 6 m_Component: - component: {fileID: 2115832650624258109} - - component: {fileID: 1445573952281937352} + - component: {fileID: 2709570496416820472} m_Layer: 0 m_Name: Container m_TagString: Untagged @@ -220,32 +328,136 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 9151448971410334137} + 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: - {fileID: 4030395336521705668} m_Father: {fileID: 49417782017751338} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!1818360608 &1445573952281937352 -PositionConstraint: +--- !u!114 &2709570496416820472 +MonoBehaviour: m_ObjectHideFlags: 0 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 9151448971410334137} m_Enabled: 1 - m_Weight: 1 - m_TranslationAtRest: {x: 0, y: 0, z: 0} - m_TranslationOffset: {x: 0, y: 0, z: 0} - m_AffectTranslationX: 1 - m_AffectTranslationY: 1 - m_AffectTranslationZ: 1 - m_IsContraintActive: 1 - m_IsLocked: 1 - m_Sources: - - sourceTransform: {fileID: 5220703081969942638} - weight: 0.05 - - sourceTransform: {fileID: 2115832650624258109} - weight: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 1116338486, guid: 58e2f01a24261a14cb82e6d3399e8b16, type: 3} + m_Name: + m_EditorClassIdentifier: + IsActive: 1 + GlobalWeight: 1 + TargetTransform: {fileID: 0} + SolveInLocalSpace: 0 + FreezeToWorld: 0 + RebakeOffsetsWhenUnfrozen: 0 + Locked: 1 + Sources: + source0: + SourceTransform: {fileID: 5220703081969942638} + Weight: 0.05 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source1: + SourceTransform: {fileID: 2115832650624258109} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source2: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source3: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source4: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source5: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source6: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source7: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source8: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source9: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source10: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source11: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source12: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source13: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source14: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + source15: + SourceTransform: {fileID: 0} + Weight: 1 + ParentPositionOffset: {x: 0, y: 0, z: 0} + ParentRotationOffset: {x: 0, y: 0, z: 0} + _defaultsApplied: 1 + totalLength: 2 + overflowList: [] + cachedExecutionGroupIndex: 0 + PositionAtRest: {x: 0, y: 0, z: 0} + PositionOffset: {x: 0, y: 0, z: 0} + AffectsPositionX: 1 + AffectsPositionY: 1 + AffectsPositionZ: 1 diff --git a/package.json b/package.json index 217329d..1455960 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "displayName": "Spring Constraint", "version": "1.0.999", "license": "MIT", - "unity": "2019.4", + "unity": "2022.3", "description": "A constraint system with spring behavior", "author": { "name": "VRLabs", @@ -12,7 +12,8 @@ }, "siteUrl": "https://github.com/VRLabs/Spring-Constraint", "vpmDependencies": { - "dev.vrlabs.instancer": ">=1.0.2" + "dev.vrlabs.instancer": ">=1.0.2", + "com.vrchat.avatars": "^3.7.0" }, "legacyFolders": { "Assets\\VRLabs\\Spring Constraint": "64faad95e10bec74b817c5e4f21a9abe" @@ -26,5 +27,6 @@ "unityPackageDestinationFolderMetas": { "Assets/VRLabs": "652a1ba5b00554143bc9a76307dbc4e8", "Assets/VRLabs/Spring Constraint": "64faad95e10bec74b817c5e4f21a9abe" - } + }, + "questCompatibility": "full" } \ No newline at end of file