feat/add-throwable-items #9

Merged
Pierre1901 merged 6 commits from feat/add-throwable-items into Prototype 2026-04-06 21:50:28 +02:00
10 changed files with 877 additions and 784 deletions

View File

@@ -0,0 +1,72 @@
using UnityEngine;
public class BoxPickup : MonoBehaviour
{
public Transform PlayerTransform;
public Transform CameraTransform;
public Transform HandTransform;
public float ThrowForce = 10f;
public float PickupDistance = 5f;
private bool isHeld;
private Rigidbody m_rigidbody;
private PlayerInputController input;
void Start()
{
m_rigidbody = GetComponent<Rigidbody>();
input = PlayerTransform.GetComponent<PlayerInputController>();
}
void Update()
{
if (input.InteractPressed)
{
if (!isHeld)
TryPickup();
else
Drop();
}
if (input.ThrowPressed)
Throw();
}
private void TryPickup()
{
Collider[] hits = Physics.OverlapSphere(PlayerTransform.position, PickupDistance);
foreach (Collider hit in hits)
{
if (hit.transform == transform) {
Pickup();
return;
}
}
}
private void Pickup()
{
isHeld = true;
m_rigidbody.isKinematic = true;
transform.SetParent(HandTransform);
transform.localPosition = Vector3.zero;
transform.localRotation = Quaternion.identity;
}
private void Drop()
{
isHeld = false;
transform.SetParent(null);
m_rigidbody.isKinematic = false;
}
private void Throw()
{
if (!isHeld)
return;
Drop();
m_rigidbody.AddForce(PlayerTransform.forward * ThrowForce, ForceMode.Impulse);
}
}

View File

@@ -0,0 +1,2 @@
fileFormatVersion: 2
guid: a36af2e55a3732eb2abc110ae2365702

View File

@@ -2,18 +2,25 @@ using UnityEngine;
public class PlayerHeadController : MonoBehaviour
{
[Header("Head")]
public Transform Head;
public Transform CameraTransform;
public Transform BodyTransform;
public float ThrowForce;
public float PickupDistance;
public bool isHoldingHead;
private Rigidbody m_headRigidbody;
[Header("Grabbable")]
public Transform HandTransform; // in the future hand maybe grab items but for now its an empty object
BoxOfPandor marked this conversation as resolved Outdated

Juste une typo sur le "teh", sinon tous est bon

Juste une typo sur le "teh", sinon tous est bon
public float ItemThrowForce = 10f;
public float ItemPickupDistance = 5f;
private bool isHoldingItem;
private Rigidbody m_itemRigidbody;
private Collider m_itemCollider;
private Transform m_currentItem;
private Rigidbody m_headRigidbody;
private Vector3 m_headInitialLocalPos;
private Quaternion m_headInitialLocalRot;
@@ -31,7 +38,6 @@ public class PlayerHeadController : MonoBehaviour
Cursor.lockState = CursorLockMode.Locked;
Vector3 offset = new Vector3(0f, -0.5f, 0.5f);
m_headInitialLocalPos = BodyTransform.localPosition + offset;
m_headInitialLocalRot = BodyTransform.localRotation;
m_headRigidbody = Head.GetComponent<Rigidbody>();
@@ -42,14 +48,20 @@ public class PlayerHeadController : MonoBehaviour
void Update()
{
if (input.HeadInteractionPressed)
{
InteractHead();
}
if (input.ThrowPressed)
{
if (input.ThrowPressed && isHoldingHead)
ThrowHead();
if (input.InteractPressed)
{
if (!isHoldingItem)
TryPickupItem();
else
DropItem();
}
if (input.ThrowPressed && isHoldingItem)
ThrowItem();
}
private void InteractHead()
@@ -60,61 +72,84 @@ public class PlayerHeadController : MonoBehaviour
DropHead();
}
private void TryPickupHead()
{
if (isHoldingHead || isHoldingItem)
return;
if (Vector3.Distance(transform.position, Head.position) <= PickupDistance)
PickupHead();
}
private void PickupHead()
{
isHoldingHead = true;
if (m_headRigidbody != null)
Destroy(m_headRigidbody);
Head.SetParent(transform);
Head.localPosition = m_headInitialLocalPos;
Head.localRotation = m_headInitialLocalRot;
}
private void DropHead()
{
Debug.Log("DropHead");
animator.SetTrigger("Throw");
isHoldingHead = false;
Head.SetParent(null);
m_headRigidbody = Head.gameObject.AddComponent<Rigidbody>();
m_headRigidbody.mass = 1f;
m_headRigidbody.constraints =
RigidbodyConstraints.FreezeRotationX |
RigidbodyConstraints.FreezeRotationZ |
RigidbodyConstraints.FreezeRotationY;
}
private void ThrowHead()
{
Debug.Log("ThrowHead");
if (!isHoldingHead)
return;
DropHead();
m_headRigidbody.AddForce(CameraTransform.forward * ThrowForce, ForceMode.Impulse);
}
private void TryPickupHead()
private void TryPickupItem()
{
if (isHoldingHead)
if (isHoldingHead || isHoldingItem)
return;
int grabbableLayer = LayerMask.GetMask("Grabbable");
Collider[] hits = Physics.OverlapSphere(transform.position, ItemPickupDistance, grabbableLayer);
float distance = Vector3.Distance(transform.position, Head.position);
if (distance <= PickupDistance)
foreach (Collider hit in hits)
{
PickupHead();
m_currentItem = hit.transform;
m_itemRigidbody = hit.GetComponent<Rigidbody>();
m_itemCollider = hit.GetComponent<Collider>();
PickupItem();
return;
}
}
private void PickupHead()
private void PickupItem()
{
Debug.Log("PickupHead");
isHoldingHead = true;
isHoldingItem = true;
m_itemRigidbody.isKinematic = true;
m_itemCollider.enabled = false;
if (m_headRigidbody != null)
{
Destroy(m_headRigidbody);
}
Head.SetParent(transform);
Head.localPosition = m_headInitialLocalPos;
Head.localRotation = m_headInitialLocalRot;
m_currentItem.SetParent(HandTransform);
m_currentItem.localPosition = Vector3.zero;
m_currentItem.localRotation = Quaternion.identity;
}
}
private void DropItem()
{
isHoldingItem = false;
m_currentItem.SetParent(null);
m_itemRigidbody.isKinematic = false;
m_itemCollider.enabled = true;
m_currentItem = null;
}
private void ThrowItem()
{
DropItem();
m_itemRigidbody.AddForce(BodyTransform.forward * ItemThrowForce, ForceMode.Impulse);
}
}

View File

@@ -11,7 +11,9 @@ public class PlayerInputController : MonoBehaviour
private InputAction m_jumpAction;
private InputAction m_throwAction;
private InputAction m_shiftAction;
private InputAction m_interactAction;
private InputAction m_headInteractAction;
public Vector2 MoveAmount { get; private set; }
public Vector2 LookAmount { get; private set; }
@@ -19,7 +21,9 @@ public class PlayerInputController : MonoBehaviour
public bool JumpPressed { get; private set; }
public bool ShiftPressed { get; private set; }
public bool ThrowPressed { get; private set; }
public bool InteractPressed { get; private set; }
public bool HeadInteractionPressed { get; private set; }
private void Awake()
{
@@ -30,7 +34,9 @@ public class PlayerInputController : MonoBehaviour
m_jumpAction = map.FindAction("Jump");
m_shiftAction = map.FindAction("Shift");
m_throwAction = map.FindAction("Throw");
m_interactAction = map.FindAction("Interact");
m_headInteractAction = map.FindAction("HeadInteract");
}
private void OnEnable()
@@ -52,6 +58,7 @@ public class PlayerInputController : MonoBehaviour
ShiftPressed = false;
JumpPressed = false;
ThrowPressed = false;
InteractPressed = false;
HeadInteractionPressed = false;
return;
}
@@ -62,6 +69,7 @@ public class PlayerInputController : MonoBehaviour
ShiftPressed = m_shiftAction.IsPressed();
JumpPressed = m_jumpAction.WasPressedThisFrame();
ThrowPressed = m_throwAction.WasPressedThisFrame();
InteractPressed = m_interactAction.WasPressedThisFrame();
HeadInteractionPressed = m_headInteractAction.WasPressedThisFrame();
}

View File

@@ -0,0 +1,182 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &8295937476714018201
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 1945301683602458784}
- component: {fileID: 7204621315108719217}
- component: {fileID: 8544167331072815505}
- component: {fileID: 1366644702000549104}
- component: {fileID: 9065033722839287093}
- component: {fileID: 5078647870528450919}
- component: {fileID: 53541677567227536}
m_Layer: 0
m_Name: ThrowableCube
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &1945301683602458784
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8295937476714018201}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: -39.38, y: 6.56, z: -9.27}
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 &7204621315108719217
MeshFilter:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8295937476714018201}
m_Mesh: {fileID: 10202, guid: 0000000000000000e000000000000000, type: 0}
--- !u!23 &8544167331072815505
MeshRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8295937476714018201}
m_Enabled: 1
m_CastShadows: 1
m_ReceiveShadows: 1
m_DynamicOccludee: 1
m_StaticShadowCaster: 0
m_MotionVectors: 1
m_LightProbeUsage: 1
m_ReflectionProbeUsage: 1
m_RayTracingMode: 2
m_RayTraceProcedural: 0
m_RayTracingAccelStructBuildFlagsOverride: 0
m_RayTracingAccelStructBuildFlags: 1
m_SmallMeshCulling: 1
m_ForceMeshLod: -1
m_MeshLodSelectionBias: 0
m_RenderingLayerMask: 1
m_RendererPriority: 0
m_Materials:
- {fileID: 2100000, guid: 31321ba15b8f8eb4c954353edc038b1d, type: 2}
m_StaticBatchInfo:
firstSubMesh: 0
subMeshCount: 0
m_StaticBatchRoot: {fileID: 0}
m_ProbeAnchor: {fileID: 0}
m_LightProbeVolumeOverride: {fileID: 0}
m_ScaleInLightmap: 1
m_ReceiveGI: 1
m_PreserveUVs: 0
m_IgnoreNormalsForChartDetection: 0
m_ImportantGI: 0
m_StitchLightmapSeams: 1
m_SelectedEditorRenderState: 3
m_MinimumChartSize: 4
m_AutoUVMaxDistance: 0.5
m_AutoUVMaxAngle: 89
m_LightmapParameters: {fileID: 0}
m_GlobalIlluminationMeshLod: 0
m_SortingLayerID: 0
m_SortingLayer: 0
m_SortingOrder: 0
m_MaskInteraction: 0
m_AdditionalVertexStreams: {fileID: 0}
--- !u!65 &1366644702000549104
BoxCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8295937476714018201}
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: 3
m_Size: {x: 1, y: 1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
--- !u!54 &9065033722839287093
Rigidbody:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8295937476714018201}
serializedVersion: 5
m_Mass: 1
m_LinearDamping: 0
m_AngularDamping: 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: 1
m_IsKinematic: 0
m_Interpolate: 0
m_Constraints: 0
m_CollisionDetection: 0
--- !u!65 &5078647870528450919
BoxCollider:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8295937476714018201}
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: 3
m_Size: {x: 1, y: 1, z: 1}
m_Center: {x: 0, y: 0, z: 0}
--- !u!114 &53541677567227536
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8295937476714018201}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: a36af2e55a3732eb2abc110ae2365702, type: 3}
m_Name:
m_EditorClassIdentifier: '::'
PlayerTransform: {fileID: 0}
CameraTransform: {fileID: 0}
HandTransform: {fileID: 0}
ThrowForce: 10
PickupDistance: 2

View File

@@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: c786dcd5f720bb47dbf843bd97137452
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -1,5 +1,36 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &4437376557356260369
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 3832855070939641903}
m_Layer: 0
m_Name: HandlePoint
m_TagString: Untagged
m_Icon: {fileID: -5442936267250999957, guid: 0000000000000000d000000000000000, type: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &3832855070939641903
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4437376557356260369}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0.69, z: 0.527}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 7821156882341915560}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &8021212901078439068
GameObject:
m_ObjectHideFlags: 0
@@ -612,7 +643,7 @@ PrefabInstance:
objectReference: {fileID: 0}
- target: {fileID: -4216859302048453862, guid: 82a2914d8f86c62488456950c8330e38, type: 3}
propertyPath: m_LocalPosition.x
value: -30.76
value: -30.54
objectReference: {fileID: 0}
- target: {fileID: -4216859302048453862, guid: 82a2914d8f86c62488456950c8330e38, type: 3}
propertyPath: m_LocalPosition.y
@@ -856,6 +887,9 @@ PrefabInstance:
- targetCorrespondingSourceObject: {fileID: -4216859302048453862, guid: 82a2914d8f86c62488456950c8330e38, type: 3}
insertIndex: -1
addedObject: {fileID: 6975610370707183838}
- targetCorrespondingSourceObject: {fileID: -4216859302048453862, guid: 82a2914d8f86c62488456950c8330e38, type: 3}
insertIndex: -1
addedObject: {fileID: 3832855070939641903}
m_AddedComponents:
- targetCorrespondingSourceObject: {fileID: -927199367670048503, guid: 82a2914d8f86c62488456950c8330e38, type: 3}
insertIndex: -1

View File

@@ -475,24 +475,6 @@ Mesh:
- serializedVersion: 1
m_IndexStart: 0
m_IndexCount: 0
--- !u!1 &36927860 stripped
GameObject:
m_CorrespondingSourceObject: {fileID: 1446289441119343760, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
m_PrefabInstance: {fileID: 99539971}
m_PrefabAsset: {fileID: 0}
--- !u!114 &36927862
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 36927860}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 1d8f349ed7dc088a4a6e2690ee87094a, type: 3}
m_Name:
m_EditorClassIdentifier: Assembly-CSharp::PlayerMovement
InputActions: {fileID: 0}
--- !u!114 &43211589 stripped
MonoBehaviour:
m_CorrespondingSourceObject: {fileID: 6921400718617286756, guid: 2f9e8e4a19f939f43a84c1c7d0a0e185, type: 3}
@@ -865,73 +847,6 @@ Mesh:
- serializedVersion: 1
m_IndexStart: 0
m_IndexCount: 0
--- !u!1001 &99539971
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 4446703388580953019, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_TagString
value: Player
objectReference: {fileID: 0}
- target: {fileID: 6544026473454475707, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_Name
value: Player
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalPosition.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalPosition.y
value: 0.5
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalPosition.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.w
value: 0.7071068
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.y
value: 0.7071068
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 90
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents:
- targetCorrespondingSourceObject: {fileID: 4446703388580953019, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
insertIndex: -1
addedObject: {fileID: 762199654}
- targetCorrespondingSourceObject: {fileID: 1446289441119343760, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
insertIndex: -1
addedObject: {fileID: 36927862}
m_SourcePrefab: {fileID: 100100000, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
--- !u!43 &143500479
Mesh:
m_ObjectHideFlags: 0
@@ -1637,6 +1552,11 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: b93699191d7b58146b2c38540cbed40f, type: 3}
m_Name:
m_EditorClassIdentifier: Assembly-CSharp::PressurePlateTestBlock
--- !u!4 &432096317 stripped
Transform:
m_CorrespondingSourceObject: {fileID: 3832855070939641903, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
m_PrefabInstance: {fileID: 1004343558}
m_PrefabAsset: {fileID: 0}
--- !u!1 &433548408
GameObject:
m_ObjectHideFlags: 0
@@ -1719,6 +1639,7 @@ MonoBehaviour:
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
headController: {fileID: 0}
--- !u!135 &433548411
SphereCollider:
m_ObjectHideFlags: 0
@@ -36062,6 +35983,67 @@ PrefabInstance:
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: c85dce46687f06f439686130ef0a647a, type: 3}
--- !u!1001 &525042218
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.x
value: 6.591309
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.y
value: 2.5500002
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.z
value: -12.203602
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8295937476714018201, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_Name
value: ThrowableCube (2)
objectReference: {fileID: 0}
- target: {fileID: 8295937476714018201, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_Layer
value: 6
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
--- !u!1 &575823971
GameObject:
m_ObjectHideFlags: 0
@@ -36832,6 +36814,67 @@ Transform:
m_Children: []
m_Father: {fileID: 1994839082}
m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0}
--- !u!1001 &616194330
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.x
value: 7.143099
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.y
value: 0.5499998
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.z
value: -11.581879
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8295937476714018201, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_Name
value: ThrowableCube
objectReference: {fileID: 0}
- target: {fileID: 8295937476714018201, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_Layer
value: 6
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
--- !u!43 &696562523
Mesh:
m_ObjectHideFlags: 0
@@ -37010,38 +37053,6 @@ Mesh:
- serializedVersion: 1
m_IndexStart: 0
m_IndexCount: 0
--- !u!1 &762199651 stripped
GameObject:
m_CorrespondingSourceObject: {fileID: 4446703388580953019, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
m_PrefabInstance: {fileID: 99539971}
m_PrefabAsset: {fileID: 0}
--- !u!54 &762199654
Rigidbody:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 762199651}
serializedVersion: 5
m_Mass: 1
m_LinearDamping: 0
m_AngularDamping: 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: 0
m_Interpolate: 0
m_Constraints: 0
m_CollisionDetection: 0
--- !u!1 &818197916
GameObject:
m_ObjectHideFlags: 0
@@ -37576,6 +37587,75 @@ Mesh:
- serializedVersion: 1
m_IndexStart: 0
m_IndexCount: 0
--- !u!1001 &1004343558
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 4313489822343726709, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: HandTransform
value:
objectReference: {fileID: 432096317}
- target: {fileID: 6544026473454475707, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_Name
value: Player
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalScale.x
value: 3.5192
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalScale.z
value: 3.66552
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalPosition.x
value: 0.86821
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalPosition.y
value: 0.05000043
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalPosition.z
value: 2.1638
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.w
value: 0.8544166
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.x
value: -0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.y
value: 0.5195886
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalRotation.z
value: -0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 62.609
objectReference: {fileID: 0}
- target: {fileID: 7821156882341915560, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: d7417f9daec269d43bdfd5a35f2da89a, type: 3}
--- !u!1 &1021798997
GameObject:
m_ObjectHideFlags: 0
@@ -38659,6 +38739,7 @@ MonoBehaviour:
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
headController: {fileID: 0}
--- !u!135 &1271779616
SphereCollider:
m_ObjectHideFlags: 0
@@ -72855,6 +72936,7 @@ MonoBehaviour:
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
headController: {fileID: 0}
--- !u!135 &1434828804
SphereCollider:
m_ObjectHideFlags: 0
@@ -108193,6 +108275,67 @@ Transform:
m_Children: []
m_Father: {fileID: 1021798998}
m_LocalEulerAnglesHint: {x: 0, y: 90, z: 0}
--- !u!1001 &1679253409
PrefabInstance:
m_ObjectHideFlags: 0
serializedVersion: 2
m_Modification:
serializedVersion: 3
m_TransformParent: {fileID: 0}
m_Modifications:
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.x
value: 6.8145223
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.y
value: 1.5500001
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalPosition.z
value: -11.941306
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.w
value: 1
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalRotation.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.x
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.y
value: 0
objectReference: {fileID: 0}
- target: {fileID: 1945301683602458784, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_LocalEulerAnglesHint.z
value: 0
objectReference: {fileID: 0}
- target: {fileID: 8295937476714018201, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_Name
value: ThrowableCube (1)
objectReference: {fileID: 0}
- target: {fileID: 8295937476714018201, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
propertyPath: m_Layer
value: 6
objectReference: {fileID: 0}
m_RemovedComponents: []
m_RemovedGameObjects: []
m_AddedGameObjects: []
m_AddedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: c786dcd5f720bb47dbf843bd97137452, type: 3}
--- !u!43 &1713424934
Mesh:
m_ObjectHideFlags: 0
@@ -109723,6 +109866,7 @@ MonoBehaviour:
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
headController: {fileID: 0}
--- !u!135 &2017727401
SphereCollider:
m_ObjectHideFlags: 0
@@ -144409,9 +144553,12 @@ SceneRoots:
m_Roots:
- {fileID: 1913408286}
- {fileID: 1225232293}
- {fileID: 99539971}
- {fileID: 638812852754935428}
- {fileID: 2009765958}
- {fileID: 2145812611}
- {fileID: 153565765}
- {fileID: 581107447}
- {fileID: 616194330}
- {fileID: 1679253409}
- {fileID: 525042218}
- {fileID: 1004343558}

File diff suppressed because it is too large Load Diff

View File

@@ -13,7 +13,7 @@ TagManager:
- Ground
- Water
- UI
-
- Grabbable
-
-
-