Skip to content

Commit

Permalink
✨ feat(towing): Add option to proviede steering targets
Browse files Browse the repository at this point in the history
  • Loading branch information
esnya committed Jun 5, 2022
1 parent 127e926 commit 256a2d3
Show file tree
Hide file tree
Showing 12 changed files with 258 additions and 58 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ BoxCollider:
m_IsTrigger: 1
m_Enabled: 1
serializedVersion: 2
m_Size: {x: 1, y: 2, z: 1}
m_Size: {x: 0.5, y: 2, z: 0.5}
m_Center: {x: 0, y: -0.4, z: 0}
--- !u!114 &8154255029462950913
MonoBehaviour:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,5 +118,5 @@ SphereCollider:
m_IsTrigger: 1
m_Enabled: 1
serializedVersion: 2
m_Radius: 0.5
m_Radius: 0.2
m_Center: {x: 0, y: 0, z: 0}
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ GameObject:
- component: {fileID: 1205091094057821825}
- component: {fileID: 8224791771255036249}
- component: {fileID: 4666553310548358406}
- component: {fileID: 9181522351205897097}
- component: {fileID: 637224382792288345}
m_Layer: 17
m_Name: TowingJoint
Expand Down Expand Up @@ -142,6 +143,24 @@ AudioSource:
m_PreInfinity: 2
m_PostInfinity: 2
m_RotationOrder: 4
--- !u!114 &9181522351205897097
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1306309843375642412}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: -617992517, guid: 661092b4961be7145bfbe56e1e62337b, type: 3}
m_Name:
m_EditorClassIdentifier:
Gain: 100
Far: 40
Near: 0
VolumetricRadius: 0
EnableSpatialization: 1
UseAudioSourceVolumeCurve: 0
--- !u!114 &637224382792288345
MonoBehaviour:
m_ObjectHideFlags: 0
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1001 &7287000028489566016
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 637224382792288345, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: serializedPublicVariablesBytesString
value: Ai8AAAAAATIAAABWAFIAQwAuAFUAZABvAG4ALgBDAG8AbQBtAG8AbgAuAFUAZABvAG4AVgBhAHIAaQBhAGIAbABlAFQAYQBiAGwAZQAsACAAVgBSAEMALgBVAGQAbwBuAC4AQwBvAG0AbQBvAG4AAAAAAAYBAAAAAAAAACcBBAAAAHQAeQBwAGUAAWgAAABTAHkAcwB0AGUAbQAuAEMAbwBsAGwAZQBjAHQAaQBvAG4AcwAuAEcAZQBuAGUAcgBpAGMALgBMAGkAcwB0AGAAMQBbAFsAVgBSAEMALgBVAGQAbwBuAC4AQwBvAG0AbQBvAG4ALgBJAG4AdABlAHIAZgBhAGMAZQBzAC4ASQBVAGQAbwBuAFYAYQByAGkAYQBiAGwAZQAsACAAVgBSAEMALgBVAGQAbwBuAC4AQwBvAG0AbQBvAG4AXQBdACwAIABtAHMAYwBvAHIAbABpAGIAAQEJAAAAVgBhAHIAaQBhAGIAbABlAHMALwEAAAABaAAAAFMAeQBzAHQAZQBtAC4AQwBvAGwAbABlAGMAdABpAG8AbgBzAC4ARwBlAG4AZQByAGkAYwAuAEwAaQBzAHQAYAAxAFsAWwBWAFIAQwAuAFUAZABvAG4ALgBDAG8AbQBtAG8AbgAuAEkAbgB0AGUAcgBmAGEAYwBlAHMALgBJAFUAZABvAG4AVgBhAHIAaQBhAGIAbABlACwAIABWAFIAQwAuAFUAZABvAG4ALgBDAG8AbQBtAG8AbgBdAF0ALAAgAG0AcwBjAG8AcgBsAGkAYgABAAAABg8AAAAAAAAAAi8CAAAAAUoAAABWAFIAQwAuAFUAZABvAG4ALgBDAG8AbQBtAG8AbgAuAFUAZABvAG4AVgBhAHIAaQ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QwBvAG0AbQBvAG4ADwAAAAYCAAAAAAAAACcBBAAAAHQAeQBwAGUAARcAAABTAHkAcwB0AGUAbQAuAFMAdAByAGkAbgBnACwAIABtAHMAYwBvAHIAbABpAGIAJwEKAAAAUwB5AG0AYgBvAGwATgBhAG0AZQABCAAAAGsAZQB5AHcAbwByAGQAcwAnAQQAAAB0AHkAcABlAAEZAAAAUwB5AHMAdABlAG0ALgBTAHQAcgBpAG4AZwBbAF0ALAAgAG0AcwBjAG8AcgBsAGkAYgABAQUAAABWAGEAbAB1AGUALwgAAAABGQAAAFMAeQBzAHQAZQBtAC4AUwB0AHIAaQBuAGcAWwBdACwAIABtAHMAYwBvAHIAbABpAGIAEAAAAAYBAAAAAAAAACgBBwAAAEQARQBGAEEAVQBMAFQABwUHBQIvCQAAAAFKAAAAVgBSAEMALgBVAGQAbwBuAC4AQwBvAG0AbQBvAG4ALgBVAGQAbwBuAFYAYQByAGkAYQBiAGwAZQBgADEAWwBbAFMAeQBzAHQAZQBtAC4AUwB0AHIAaQBuAGcALAAgAG0AcwBjAG8AcgBsAGkAYgBdAF0ALAAgAFYAUgBDAC4AVQBkAG8AbgAuAEMAbwBtAG0AbwBuABEAAAAGAgAAAAAAAAAnAQQAAAB0AHkAcABlAAEXAAAAUwB5AHMAdABlAG0ALgBTAHQAcgBpAG4AZwAsACAAbQBzAGMAbwByAGwAaQBiACcBCgAAAFMAeQBtAGIAbwBsAE4AYQBtAGUAAQcAAABrAGUAeQB3AG8AcgBkACcBBAAAAHQAeQBwAGUAARcAAABTAHkAcwB0AGUAbQAuAFMAdAByAGkAbgBnACwAIABtAHMAYwBvAHIAbABpAGIAJwEFAAAAVgBhAGwAdQBlAAEGAAAAVABPAFcAQgBBAFIABwUHBQcF
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_RootOrder
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalPosition.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1205091094057821825, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1306309843375642412, guid: 2b4cb2ba00a02be42910ad4ccfe55a96,
type: 3}
propertyPath: m_Name
value: TowingJoint_Towbar
objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: 2b4cb2ba00a02be42910ad4ccfe55a96, type: 3}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: attachedRigidbody
Data: steeringWheels
- Name: $v
Entry: 7
Data: 11|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Expand All @@ -196,25 +196,25 @@ MonoBehaviour:
Data: 13|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: UnityEngine.Rigidbody, UnityEngine.PhysicsModule
Data: UnityEngine.WheelCollider[], UnityEngine.VehiclesModule
- Name:
Entry: 8
Data:
- Name: declarationType
Entry: 3
Data: 2
Data: 1
- Name: syncMode
Entry: 3
Data: 0
- Name: symbolResolvedTypeName
Entry: 1
Data: UnityEngineRigidbody
Data: UnityEngineWheelColliderArray
- Name: symbolOriginalName
Entry: 1
Data: attachedRigidbody
Data: steeringWheels
- Name: symbolUniqueName
Entry: 1
Data: attachedRigidbody
Data: steeringWheels
- Name: symbolDefaultValue
Entry: 6
Data:
Expand All @@ -226,13 +226,7 @@ MonoBehaviour:
Data: 14|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 15|System.NonSerializedAttribute, mscorlib
- Name:
Entry: 8
Data:
Data: 0
- Name:
Entry: 13
Data:
Expand All @@ -253,19 +247,19 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: attachedWheelCollider
Data: attachedRigidbody
- Name: $v
Entry: 7
Data: 16|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 15|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: fieldSymbol
Entry: 7
Data: 17|UdonSharp.Compiler.SymbolDefinition, UdonSharp.Editor
Data: 16|UdonSharp.Compiler.SymbolDefinition, UdonSharp.Editor
- Name: internalType
Entry: 7
Data: 18|System.RuntimeType, mscorlib
Data: 17|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: UnityEngine.WheelCollider, UnityEngine.VehiclesModule
Data: UnityEngine.Rigidbody, UnityEngine.PhysicsModule
- Name:
Entry: 8
Data:
Expand All @@ -277,13 +271,13 @@ MonoBehaviour:
Data: 0
- Name: symbolResolvedTypeName
Entry: 1
Data: UnityEngineWheelCollider
Data: UnityEngineRigidbody
- Name: symbolOriginalName
Entry: 1
Data: attachedWheelCollider
Data: attachedRigidbody
- Name: symbolUniqueName
Entry: 1
Data: attachedWheelCollider
Data: attachedRigidbody
- Name: symbolDefaultValue
Entry: 6
Data:
Expand All @@ -292,13 +286,13 @@ MonoBehaviour:
Data:
- Name: fieldAttributes
Entry: 7
Data: 19|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 18|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 20|System.NonSerializedAttribute, mscorlib
Data: 19|System.NonSerializedAttribute, mscorlib
- Name:
Entry: 8
Data:
Expand All @@ -325,13 +319,13 @@ MonoBehaviour:
Data: keywords
- Name: $v
Entry: 7
Data: 21|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Data: 20|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
- Name: fieldSymbol
Entry: 7
Data: 22|UdonSharp.Compiler.SymbolDefinition, UdonSharp.Editor
Data: 21|UdonSharp.Compiler.SymbolDefinition, UdonSharp.Editor
- Name: internalType
Entry: 7
Data: 23|System.RuntimeType, mscorlib
Data: 22|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: System.String[], mscorlib
Expand Down Expand Up @@ -361,13 +355,13 @@ MonoBehaviour:
Data:
- Name: fieldAttributes
Entry: 7
Data: 24|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
Data: 23|System.Collections.Generic.List`1[[System.Attribute, mscorlib]], mscorlib
- Name:
Entry: 12
Data: 1
- Name:
Entry: 7
Data: 25|System.NonSerializedAttribute, mscorlib
Data: 24|System.NonSerializedAttribute, mscorlib
- Name:
Entry: 8
Data:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ public class USC_TowingAnchor : UdonSharpBehaviour
[Tooltip("Default: VRCObjectSync in parent or find from SaccFlightAndVehicles")]
public GameObject ownerDetector;
public string keyword = "DEFAULT";
public WheelCollider[] steeringWheels = { };
#endregion

#region NonSerialized Variables
[NonSerialized] public Rigidbody attachedRigidbody;
[NonSerialized] public WheelCollider attachedWheelCollider;
[NonSerialized] public string[] keywords;
#endregion

Expand All @@ -28,7 +28,11 @@ private void Start()
attachedRigidbody = transform.parent.GetComponentInParent<Rigidbody>();
if (!ownerDetector) ownerDetector = attachedRigidbody.gameObject;

attachedWheelCollider = GetComponentInParent<WheelCollider>();
if (steeringWheels == null || steeringWheels.Length == 0)
{
var wheelInParent = GetComponentInParent<WheelCollider>();
steeringWheels = wheelInParent ? new[] { wheelInParent } : new WheelCollider[0];
}

keywords = keyword.Split(',');
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1265,7 +1265,7 @@ MonoBehaviour:
Data:
- Name: $k
Entry: 1
Data: connectedWheelCollider
Data: connectedWheelColliders
- Name: $v
Entry: 7
Data: 74|UdonSharp.Compiler.FieldDefinition, UdonSharp.Editor
Expand All @@ -1277,7 +1277,7 @@ MonoBehaviour:
Data: 76|System.RuntimeType, mscorlib
- Name:
Entry: 1
Data: UnityEngine.WheelCollider, UnityEngine.VehiclesModule
Data: UnityEngine.WheelCollider[], UnityEngine.VehiclesModule
- Name:
Entry: 8
Data:
Expand All @@ -1289,13 +1289,13 @@ MonoBehaviour:
Data: 0
- Name: symbolResolvedTypeName
Entry: 1
Data: UnityEngineWheelCollider
Data: UnityEngineWheelColliderArray
- Name: symbolOriginalName
Entry: 1
Data: connectedWheelCollider
Data: connectedWheelColliders
- Name: symbolUniqueName
Entry: 1
Data: connectedWheelCollider
Data: connectedWheelColliders
- Name: symbolDefaultValue
Entry: 6
Data:
Expand Down
Loading

0 comments on commit 256a2d3

Please sign in to comment.