From 80c478b00f090a64ccd63d3252ac02ffa1f7f5a2 Mon Sep 17 00:00:00 2001 From: Neil Kollack Date: Thu, 14 Apr 2022 21:14:44 -0500 Subject: feat: level complete --- Assets/Scripts/Actors/Actor.cs | 10 +++++----- Assets/Scripts/Actors/Player.cs | 26 ++++++++++++++++++++++---- 2 files changed, 27 insertions(+), 9 deletions(-) (limited to 'Assets/Scripts/Actors') diff --git a/Assets/Scripts/Actors/Actor.cs b/Assets/Scripts/Actors/Actor.cs index bcee7a3..2e98974 100644 --- a/Assets/Scripts/Actors/Actor.cs +++ b/Assets/Scripts/Actors/Actor.cs @@ -14,7 +14,6 @@ namespace MontanaJohns.Actors { [SerializeField] protected float gravityScale = 1.5f; [SerializeField] protected Stats baseStats = Stats.DefaultBaseStats(); - [SerializeField] protected LayerMask groundLayer; [SerializeField] protected Transform groundCheckPoint; protected Rigidbody2D _rigidBody; @@ -26,8 +25,8 @@ namespace MontanaJohns.Actors protected Active activeItem; protected bool isGrappling; protected Vector2? grapplePoint = null; + protected LayerMask groundLayers; Collection items; - bool isFalling; public int health; protected int jumpCount; @@ -39,6 +38,7 @@ namespace MontanaJohns.Actors _transform = GetComponent(); _renderer = GetComponent(); _animator = GetComponent(); + groundLayers = LayerMask.GetMask("Grapple", "Ground"); } protected virtual void Start() @@ -55,7 +55,7 @@ namespace MontanaJohns.Actors protected virtual void FixedUpdate() { - if (!_animator.GetBool("airborn") && !Physics2D.OverlapCircle(groundCheckPoint.position, 0.2f, groundLayer)) + if (!_animator.GetBool("airborn") && !Physics2D.OverlapCircle(groundCheckPoint.position, 0.2f, groundLayers)) { _animator.SetTrigger("fall"); StartCoroutine(Falling()); @@ -66,7 +66,7 @@ namespace MontanaJohns.Actors { var target = new Vector2(input * stats.speedMultiplier * 10, _rigidBody.velocity.y); _rigidBody.velocity = Vector2.SmoothDamp(_rigidBody.velocity, target, ref acceleration, .05f); - _animator.SetBool("moving", Mathf.Abs(_rigidBody.velocity.x) > 0.001); + _animator.SetBool("moving", Mathf.Abs(_rigidBody.velocity.x) > 1); if (_rigidBody.velocity.x < -0.001) _renderer.flipX = true; @@ -127,7 +127,7 @@ namespace MontanaJohns.Actors { _animator.SetBool("airborn", true); - while (_rigidBody.velocity.y > 0 || !Physics2D.OverlapCircle(groundCheckPoint.position, 0.2f, groundLayer)) + while (_rigidBody.velocity.y > 0 || !Physics2D.OverlapCircle(groundCheckPoint.position, 0.2f, groundLayers)) { yield return new WaitForFixedUpdate(); } diff --git a/Assets/Scripts/Actors/Player.cs b/Assets/Scripts/Actors/Player.cs index 3192338..3537aa7 100644 --- a/Assets/Scripts/Actors/Player.cs +++ b/Assets/Scripts/Actors/Player.cs @@ -10,10 +10,11 @@ namespace MontanaJohns.Actors { public Transform ActorTransform => _transform; public Camera MainCamera => _camera; + public Vector3 spawnPoint; - Camera _camera; - PlayerInput playerInput; - InputAction use, move, jump; + private Camera _camera; + private PlayerInput playerInput; + private InputAction use, move, jump; protected override void Awake() { @@ -34,7 +35,8 @@ namespace MontanaJohns.Actors base.Start(); GameObject loadedItem = (GameObject)Instantiate(Resources.Load("ActiveItems/Whip")); activeItem = loadedItem.GetComponent(); - stats = baseStats + activeItem.stats; + ResetStats(); + spawnPoint = transform.position; } protected void Update() @@ -48,6 +50,22 @@ namespace MontanaJohns.Actors { base.Move(move.ReadValue().x); } + DeathCheck(); + } + + protected void DeathCheck() + { + if(health <= 0) + { + ResetStats(); + health = stats.maxHealth; + transform.position = spawnPoint; + } + } + + protected void ResetStats() + { + stats = baseStats + activeItem.stats; } } } \ No newline at end of file -- cgit v1.2.3-70-g09d2 From 929254005c7dc7437208715a6ae04b69292fe4f7 Mon Sep 17 00:00:00 2001 From: Neil Kollack Date: Thu, 14 Apr 2022 22:27:32 -0500 Subject: feat: player complete + player animation --- Assets/Animations/MontanaJohns/Airborn.anim | 68 +++ Assets/Animations/MontanaJohns/Airborn.anim.meta | 8 + Assets/Animations/MontanaJohns/Idle.anim | 74 +++ Assets/Animations/MontanaJohns/Idle.anim.meta | 8 + Assets/Animations/MontanaJohns/Jump.anim | 77 +++ Assets/Animations/MontanaJohns/Jump.anim.meta | 8 + .../MontanaJohns/MontanaJohns.controller | 435 ++++++++++++++- .../MontanaJohns/MontanaJohns.controller.meta | 2 +- Assets/Animations/MontanaJohns/Player.controller | 72 --- .../Animations/MontanaJohns/Player.controller.meta | 8 - Assets/Animations/MontanaJohns/run.anim | 48 +- Assets/Animations/Prototype.meta | 8 - Assets/Animations/Prototype/Player.controller | 616 --------------------- Assets/Prefabs/Player.prefab | 8 +- Assets/Scenes/Jungle.unity | 16 - Assets/Scripts/Actors/Actor.cs | 16 +- .../Player/MontanaJohns/MontanaJohnsFinal.png | Bin 0 -> 7835 bytes .../Player/MontanaJohns/MontanaJohnsFinal.png.meta | 474 ++++++++++++++++ .../MontanaJohns/MontanaJohnsLandingPreRun.png | Bin 8337 -> 0 bytes .../MontanaJohnsLandingPreRun.png.meta | 540 ------------------ Assets/Sprites/Player/PrototypeHero.meta | 8 - 21 files changed, 1170 insertions(+), 1324 deletions(-) create mode 100644 Assets/Animations/MontanaJohns/Airborn.anim create mode 100644 Assets/Animations/MontanaJohns/Airborn.anim.meta create mode 100644 Assets/Animations/MontanaJohns/Idle.anim create mode 100644 Assets/Animations/MontanaJohns/Idle.anim.meta create mode 100644 Assets/Animations/MontanaJohns/Jump.anim create mode 100644 Assets/Animations/MontanaJohns/Jump.anim.meta delete mode 100644 Assets/Animations/MontanaJohns/Player.controller delete mode 100644 Assets/Animations/MontanaJohns/Player.controller.meta delete mode 100644 Assets/Animations/Prototype.meta delete mode 100644 Assets/Animations/Prototype/Player.controller create mode 100644 Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png create mode 100644 Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png.meta delete mode 100644 Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png delete mode 100644 Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png.meta delete mode 100644 Assets/Sprites/Player/PrototypeHero.meta (limited to 'Assets/Scripts/Actors') diff --git a/Assets/Animations/MontanaJohns/Airborn.anim b/Assets/Animations/MontanaJohns/Airborn.anim new file mode 100644 index 0000000..02d569c --- /dev/null +++ b/Assets/Animations/MontanaJohns/Airborn.anim @@ -0,0 +1,68 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Airborn + serializedVersion: 6 + m_Legacy: 0 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_EulerCurves: [] + m_PositionCurves: [] + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: + - curve: + - time: 0 + value: {fileID: -289598290, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + attribute: m_Sprite + path: + classID: 212 + script: {fileID: 0} + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_ClipBindingConstant: + genericBindings: + - serializedVersion: 2 + path: 0 + attribute: 0 + script: {fileID: 0} + typeID: 212 + customType: 23 + isPPtrCurve: 1 + pptrCurveMapping: + - {fileID: -289598290, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + m_AnimationClipSettings: + serializedVersion: 2 + m_AdditiveReferencePoseClip: {fileID: 0} + m_AdditiveReferencePoseTime: 0 + m_StartTime: 0 + m_StopTime: 0.016666668 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_HasAdditiveReferencePose: 0 + m_LoopTime: 1 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: [] + m_EulerEditorCurves: [] + m_HasGenericRootTransform: 0 + m_HasMotionFloatCurves: 0 + m_Events: [] diff --git a/Assets/Animations/MontanaJohns/Airborn.anim.meta b/Assets/Animations/MontanaJohns/Airborn.anim.meta new file mode 100644 index 0000000..4f40170 --- /dev/null +++ b/Assets/Animations/MontanaJohns/Airborn.anim.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 46e98d769584f344882c4c187cfc105c +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 7400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Animations/MontanaJohns/Idle.anim b/Assets/Animations/MontanaJohns/Idle.anim new file mode 100644 index 0000000..5859ef4 --- /dev/null +++ b/Assets/Animations/MontanaJohns/Idle.anim @@ -0,0 +1,74 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Idle + serializedVersion: 6 + m_Legacy: 0 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_EulerCurves: [] + m_PositionCurves: [] + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: + - curve: + - time: 0 + value: {fileID: -1786744883, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.1 + value: {fileID: 191790088, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.2 + value: {fileID: -476690385, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + attribute: m_Sprite + path: + classID: 212 + script: {fileID: 0} + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_ClipBindingConstant: + genericBindings: + - serializedVersion: 2 + path: 0 + attribute: 0 + script: {fileID: 0} + typeID: 212 + customType: 23 + isPPtrCurve: 1 + pptrCurveMapping: + - {fileID: -1786744883, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: 191790088, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: -476690385, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + m_AnimationClipSettings: + serializedVersion: 2 + m_AdditiveReferencePoseClip: {fileID: 0} + m_AdditiveReferencePoseTime: 0 + m_StartTime: 0 + m_StopTime: 0.21666667 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_HasAdditiveReferencePose: 0 + m_LoopTime: 1 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: [] + m_EulerEditorCurves: [] + m_HasGenericRootTransform: 0 + m_HasMotionFloatCurves: 0 + m_Events: [] diff --git a/Assets/Animations/MontanaJohns/Idle.anim.meta b/Assets/Animations/MontanaJohns/Idle.anim.meta new file mode 100644 index 0000000..6ef16f8 --- /dev/null +++ b/Assets/Animations/MontanaJohns/Idle.anim.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: fb582967ec1b71c4daf7ff9f5e0d0ecb +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 7400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Animations/MontanaJohns/Jump.anim b/Assets/Animations/MontanaJohns/Jump.anim new file mode 100644 index 0000000..e074b1c --- /dev/null +++ b/Assets/Animations/MontanaJohns/Jump.anim @@ -0,0 +1,77 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!74 &7400000 +AnimationClip: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Jump + serializedVersion: 6 + m_Legacy: 0 + m_Compressed: 0 + m_UseHighQualityCurve: 1 + m_RotationCurves: [] + m_CompressedRotationCurves: [] + m_EulerCurves: [] + m_PositionCurves: [] + m_ScaleCurves: [] + m_FloatCurves: [] + m_PPtrCurves: + - curve: + - time: 0 + value: {fileID: -1743127331, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.1 + value: {fileID: 517512235, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.2 + value: {fileID: -116468388, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.3 + value: {fileID: -2140250000, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + attribute: m_Sprite + path: + classID: 212 + script: {fileID: 0} + m_SampleRate: 60 + m_WrapMode: 0 + m_Bounds: + m_Center: {x: 0, y: 0, z: 0} + m_Extent: {x: 0, y: 0, z: 0} + m_ClipBindingConstant: + genericBindings: + - serializedVersion: 2 + path: 0 + attribute: 0 + script: {fileID: 0} + typeID: 212 + customType: 23 + isPPtrCurve: 1 + pptrCurveMapping: + - {fileID: -1743127331, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: 517512235, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: -116468388, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: -2140250000, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + m_AnimationClipSettings: + serializedVersion: 2 + m_AdditiveReferencePoseClip: {fileID: 0} + m_AdditiveReferencePoseTime: 0 + m_StartTime: 0 + m_StopTime: 0.3166667 + m_OrientationOffsetY: 0 + m_Level: 0 + m_CycleOffset: 0 + m_HasAdditiveReferencePose: 0 + m_LoopTime: 1 + m_LoopBlend: 0 + m_LoopBlendOrientation: 0 + m_LoopBlendPositionY: 0 + m_LoopBlendPositionXZ: 0 + m_KeepOriginalOrientation: 0 + m_KeepOriginalPositionY: 1 + m_KeepOriginalPositionXZ: 0 + m_HeightFromFeet: 0 + m_Mirror: 0 + m_EditorCurves: [] + m_EulerEditorCurves: [] + m_HasGenericRootTransform: 0 + m_HasMotionFloatCurves: 0 + m_Events: [] diff --git a/Assets/Animations/MontanaJohns/Jump.anim.meta b/Assets/Animations/MontanaJohns/Jump.anim.meta new file mode 100644 index 0000000..003a39c --- /dev/null +++ b/Assets/Animations/MontanaJohns/Jump.anim.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 64708686cdd8704479e6c0721dae28dc +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 7400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Animations/MontanaJohns/MontanaJohns.controller b/Assets/Animations/MontanaJohns/MontanaJohns.controller index cfb8eec..46d4d12 100644 --- a/Assets/Animations/MontanaJohns/MontanaJohns.controller +++ b/Assets/Animations/MontanaJohns/MontanaJohns.controller @@ -1,16 +1,106 @@ %YAML 1.1 %TAG !u! tag:unity3d.com,2011: ---- !u!1102 &-4381722352777846568 +--- !u!1101 &-8626510112679481558 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: [] + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 4014801967865307794} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0 + m_TransitionOffset: 0 + m_ExitTime: 1 + m_HasExitTime: 1 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1101 &-6878608224570280004 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 1 + m_ConditionEvent: fall + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 4014801967865307794} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0 + m_TransitionOffset: 0 + m_ExitTime: 1 + m_HasExitTime: 0 + m_HasFixedDuration: 0 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1109 &-5356925075260466985 +AnimatorTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 1 + m_ConditionEvent: moving + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 6109551287401904689} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 1 +--- !u!1101 &-4025803860441014948 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 1 + m_ConditionEvent: jump + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: -3360105894821777026} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0 + m_TransitionOffset: 0 + m_ExitTime: 0 + m_HasExitTime: 0 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1102 &-3360105894821777026 AnimatorState: serializedVersion: 6 m_ObjectHideFlags: 1 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_Name: Run + m_Name: Jump m_Speed: 1 m_CycleOffset: 0 - m_Transitions: [] + m_Transitions: + - {fileID: -8626510112679481558} m_StateMachineBehaviours: [] m_Position: {x: 50, y: 50, z: 0} m_IKOnFeet: 0 @@ -20,12 +110,102 @@ AnimatorState: m_MirrorParameterActive: 0 m_CycleOffsetParameterActive: 0 m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: 16f0d19faa73a274788329f7368084f1, type: 2} + m_Motion: {fileID: 7400000, guid: 64708686cdd8704479e6c0721dae28dc, type: 2} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: +--- !u!1102 &-3109416563068774462 +AnimatorState: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Land + m_Speed: 1 + m_CycleOffset: 0 + m_Transitions: + - {fileID: 2651979714303655906} + - {fileID: -1449902651349316248} + m_StateMachineBehaviours: [] + m_Position: {x: 50, y: 50, z: 0} + m_IKOnFeet: 0 + m_WriteDefaultValues: 1 + m_Mirror: 0 + m_SpeedParameterActive: 0 + m_MirrorParameterActive: 0 + m_CycleOffsetParameterActive: 0 + m_TimeParameterActive: 0 + m_Motion: {fileID: 0} m_Tag: m_SpeedParameter: m_MirrorParameter: m_CycleOffsetParameter: m_TimeParameter: +--- !u!1101 &-1449902651349316248 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 2 + m_ConditionEvent: airborn + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 0} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 1 + serializedVersion: 3 + m_TransitionDuration: 0 + m_TransitionOffset: 0 + m_ExitTime: 0 + m_HasExitTime: 0 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1107 &-87433385847552929 +AnimatorStateMachine: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Base Layer + m_ChildStates: + - serializedVersion: 1 + m_State: {fileID: 9132405649074356357} + m_Position: {x: 250, y: -10, z: 0} + - serializedVersion: 1 + m_State: {fileID: -3360105894821777026} + m_Position: {x: 450, y: 210, z: 0} + - serializedVersion: 1 + m_State: {fileID: 4014801967865307794} + m_Position: {x: 300, y: 320, z: 0} + - serializedVersion: 1 + m_State: {fileID: -3109416563068774462} + m_Position: {x: 200, y: 210, z: 0} + - serializedVersion: 1 + m_State: {fileID: 6109551287401904689} + m_Position: {x: 750, y: -10, z: 0} + m_ChildStateMachines: [] + m_AnyStateTransitions: + - {fileID: -6878608224570280004} + - {fileID: -4025803860441014948} + m_EntryTransitions: + - {fileID: -5356925075260466985} + m_StateMachineTransitions: {} + m_StateMachineBehaviours: [] + m_AnyStatePosition: {x: 610, y: 320, z: 0} + m_EntryPosition: {x: 270, y: 110, z: 0} + m_ExitPosition: {x: 60, y: 70, z: 0} + m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} + m_DefaultState: {fileID: 9132405649074356357} --- !u!91 &9100000 AnimatorController: m_ObjectHideFlags: 0 @@ -34,11 +214,35 @@ AnimatorController: m_PrefabAsset: {fileID: 0} m_Name: MontanaJohns serializedVersion: 5 - m_AnimatorParameters: [] + m_AnimatorParameters: + - m_Name: moving + m_Type: 4 + m_DefaultFloat: 0 + m_DefaultInt: 0 + m_DefaultBool: 0 + m_Controller: {fileID: 9100000} + - m_Name: jump + m_Type: 9 + m_DefaultFloat: 0 + m_DefaultInt: 0 + m_DefaultBool: 0 + m_Controller: {fileID: 9100000} + - m_Name: fall + m_Type: 9 + m_DefaultFloat: 0 + m_DefaultInt: 0 + m_DefaultBool: 0 + m_Controller: {fileID: 9100000} + - m_Name: airborn + m_Type: 4 + m_DefaultFloat: 0 + m_DefaultInt: 0 + m_DefaultBool: 0 + m_Controller: {fileID: 9100000} m_AnimatorLayers: - serializedVersion: 5 m_Name: Base Layer - m_StateMachine: {fileID: 830988249226544064} + m_StateMachine: {fileID: -87433385847552929} m_Mask: {fileID: 0} m_Motions: [] m_Behaviours: [] @@ -48,25 +252,212 @@ AnimatorController: m_IKPass: 0 m_SyncedLayerAffectsTiming: 0 m_Controller: {fileID: 9100000} ---- !u!1107 &830988249226544064 -AnimatorStateMachine: +--- !u!1101 &1200084873163517128 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 2 + m_ConditionEvent: moving + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 9132405649074356357} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0 + m_TransitionOffset: 0 + m_ExitTime: 0 + m_HasExitTime: 0 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1109 &1807663489023768798 +AnimatorTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 1 + m_ConditionEvent: jump + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: -3360105894821777026} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 1 +--- !u!1101 &2585772133770462678 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 2 + m_ConditionEvent: airborn + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: -3109416563068774462} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0 + m_TransitionOffset: 0 + m_ExitTime: 0 + m_HasExitTime: 1 + m_HasFixedDuration: 0 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1101 &2651979714303655906 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: [] + m_DstStateMachine: {fileID: -87433385847552929} + m_DstState: {fileID: 0} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0.25 + m_TransitionOffset: 0 + m_ExitTime: 0 + m_HasExitTime: 1 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1109 &3809652522530214263 +AnimatorTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: [] + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 9132405649074356357} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 1 +--- !u!1102 &4014801967865307794 +AnimatorState: serializedVersion: 6 m_ObjectHideFlags: 1 m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_Name: Base Layer - m_ChildStates: - - serializedVersion: 1 - m_State: {fileID: -4381722352777846568} - m_Position: {x: 380, y: 120, z: 0} - m_ChildStateMachines: [] - m_AnyStateTransitions: [] - m_EntryTransitions: [] - m_StateMachineTransitions: {} + m_Name: Airborn + m_Speed: 1 + m_CycleOffset: 0 + m_Transitions: + - {fileID: 2585772133770462678} m_StateMachineBehaviours: [] - m_AnyStatePosition: {x: 50, y: 20, z: 0} - m_EntryPosition: {x: 50, y: 120, z: 0} - m_ExitPosition: {x: 800, y: 120, z: 0} - m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} - m_DefaultState: {fileID: -4381722352777846568} + m_Position: {x: 50, y: 50, z: 0} + m_IKOnFeet: 0 + m_WriteDefaultValues: 1 + m_Mirror: 0 + m_SpeedParameterActive: 0 + m_MirrorParameterActive: 0 + m_CycleOffsetParameterActive: 0 + m_TimeParameterActive: 0 + m_Motion: {fileID: 7400000, guid: 46e98d769584f344882c4c187cfc105c, type: 2} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: +--- !u!1102 &6109551287401904689 +AnimatorState: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Run + m_Speed: 1 + m_CycleOffset: 0 + m_Transitions: + - {fileID: 1200084873163517128} + m_StateMachineBehaviours: [] + m_Position: {x: 50, y: 50, z: 0} + m_IKOnFeet: 0 + m_WriteDefaultValues: 1 + m_Mirror: 0 + m_SpeedParameterActive: 0 + m_MirrorParameterActive: 0 + m_CycleOffsetParameterActive: 0 + m_TimeParameterActive: 0 + m_Motion: {fileID: 7400000, guid: 16f0d19faa73a274788329f7368084f1, type: 2} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: +--- !u!1101 &6162055090529009712 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 1 + m_ConditionEvent: moving + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 6109551287401904689} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0 + m_TransitionOffset: 0 + m_ExitTime: 0 + m_HasExitTime: 0 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 +--- !u!1102 &9132405649074356357 +AnimatorState: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Idle + m_Speed: 0.25 + m_CycleOffset: 0 + m_Transitions: + - {fileID: 6162055090529009712} + m_StateMachineBehaviours: [] + m_Position: {x: 50, y: 50, z: 0} + m_IKOnFeet: 0 + m_WriteDefaultValues: 1 + m_Mirror: 0 + m_SpeedParameterActive: 0 + m_MirrorParameterActive: 0 + m_CycleOffsetParameterActive: 0 + m_TimeParameterActive: 0 + m_Motion: {fileID: 7400000, guid: fb582967ec1b71c4daf7ff9f5e0d0ecb, type: 2} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: diff --git a/Assets/Animations/MontanaJohns/MontanaJohns.controller.meta b/Assets/Animations/MontanaJohns/MontanaJohns.controller.meta index d38ee98..5554e17 100644 --- a/Assets/Animations/MontanaJohns/MontanaJohns.controller.meta +++ b/Assets/Animations/MontanaJohns/MontanaJohns.controller.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 5b3446f9fca03924ea2739d6e2d1f00e +guid: 263157a89cfad80489c5baefc615a3a7 NativeFormatImporter: externalObjects: {} mainObjectFileID: 9100000 diff --git a/Assets/Animations/MontanaJohns/Player.controller b/Assets/Animations/MontanaJohns/Player.controller deleted file mode 100644 index 4d4a73d..0000000 --- a/Assets/Animations/MontanaJohns/Player.controller +++ /dev/null @@ -1,72 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!1107 &-989215695225172247 -AnimatorStateMachine: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Base Layer - m_ChildStates: - - serializedVersion: 1 - m_State: {fileID: -45171433127652272} - m_Position: {x: 330, y: 110, z: 0} - m_ChildStateMachines: [] - m_AnyStateTransitions: [] - m_EntryTransitions: [] - m_StateMachineTransitions: {} - m_StateMachineBehaviours: [] - m_AnyStatePosition: {x: 50, y: 20, z: 0} - m_EntryPosition: {x: 50, y: 120, z: 0} - m_ExitPosition: {x: 800, y: 120, z: 0} - m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} - m_DefaultState: {fileID: -45171433127652272} ---- !u!1102 &-45171433127652272 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: run - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: [] - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: 16f0d19faa73a274788329f7368084f1, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: ---- !u!91 &9100000 -AnimatorController: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Player - serializedVersion: 5 - m_AnimatorParameters: [] - m_AnimatorLayers: - - serializedVersion: 5 - m_Name: Base Layer - m_StateMachine: {fileID: -989215695225172247} - m_Mask: {fileID: 0} - m_Motions: [] - m_Behaviours: [] - m_BlendingMode: 0 - m_SyncedLayerIndex: -1 - m_DefaultWeight: 0 - m_IKPass: 0 - m_SyncedLayerAffectsTiming: 0 - m_Controller: {fileID: 9100000} diff --git a/Assets/Animations/MontanaJohns/Player.controller.meta b/Assets/Animations/MontanaJohns/Player.controller.meta deleted file mode 100644 index ff283bc..0000000 --- a/Assets/Animations/MontanaJohns/Player.controller.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 8ece3251730e7134f9bbe0852b7c6612 -NativeFormatImporter: - externalObjects: {} - mainObjectFileID: 9100000 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/Animations/MontanaJohns/run.anim b/Assets/Animations/MontanaJohns/run.anim index fdce640..965b35e 100644 --- a/Assets/Animations/MontanaJohns/run.anim +++ b/Assets/Animations/MontanaJohns/run.anim @@ -6,7 +6,7 @@ AnimationClip: m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} - m_Name: run + m_Name: Run serializedVersion: 6 m_Legacy: 0 m_Compressed: 0 @@ -20,21 +20,21 @@ AnimationClip: m_PPtrCurves: - curve: - time: 0 - value: {fileID: 1256470140, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - time: 0.083333336 - value: {fileID: -1042349849, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - time: 0.16666667 - value: {fileID: 216792634, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - time: 0.25 - value: {fileID: 1044303231, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - time: 0.33333334 - value: {fileID: 299380834, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - time: 0.41666666 - value: {fileID: -1460522098, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} + value: {fileID: 873809126, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.1 + value: {fileID: -346341652, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.2 + value: {fileID: -2035052553, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.3 + value: {fileID: -762021199, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.4 + value: {fileID: 584818143, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} - time: 0.5 - value: {fileID: -1969183652, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - time: 0.5833333 - value: {fileID: -919123645, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} + value: {fileID: 1138914620, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.6 + value: {fileID: 1394569422, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - time: 0.7 + value: {fileID: 640910275, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} attribute: m_Sprite path: classID: 212 @@ -54,20 +54,20 @@ AnimationClip: customType: 23 isPPtrCurve: 1 pptrCurveMapping: - - {fileID: 1256470140, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - {fileID: -1042349849, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - {fileID: 216792634, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - {fileID: 1044303231, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - {fileID: 299380834, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - {fileID: -1460522098, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - {fileID: -1969183652, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} - - {fileID: -919123645, guid: 8b08bada3c2ac5e4cb65721a772f0f99, type: 3} + - {fileID: 873809126, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: -346341652, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: -2035052553, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: -762021199, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: 584818143, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: 1138914620, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: 1394569422, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} + - {fileID: 640910275, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} m_AnimationClipSettings: serializedVersion: 2 m_AdditiveReferencePoseClip: {fileID: 0} m_AdditiveReferencePoseTime: 0 m_StartTime: 0 - m_StopTime: 0.59999996 + m_StopTime: 0.71666664 m_OrientationOffsetY: 0 m_Level: 0 m_CycleOffset: 0 diff --git a/Assets/Animations/Prototype.meta b/Assets/Animations/Prototype.meta deleted file mode 100644 index 7be3619..0000000 --- a/Assets/Animations/Prototype.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 512e0933132944d4ba2180e0b31b6420 -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/Animations/Prototype/Player.controller b/Assets/Animations/Prototype/Player.controller deleted file mode 100644 index 8f5c56a..0000000 --- a/Assets/Animations/Prototype/Player.controller +++ /dev/null @@ -1,616 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!1101 &-8626510112679481558 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: [] - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 4014801967865307794} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 1 - m_HasExitTime: 1 - m_HasFixedDuration: 1 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &-8388212156864459442 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 2 - m_ConditionEvent: moving - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 3614093525302314329} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 1 - m_HasExitTime: 0 - m_HasFixedDuration: 0 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &-6878608224570280004 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 1 - m_ConditionEvent: fall - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 4014801967865307794} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 1 - m_HasExitTime: 0 - m_HasFixedDuration: 0 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &-6106642904432627373 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 1 - m_ConditionEvent: moving - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 6109551287401904689} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 0 - m_HasExitTime: 0 - m_HasFixedDuration: 1 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &-4025803860441014948 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 1 - m_ConditionEvent: jump - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: -3360105894821777026} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 0 - m_HasExitTime: 0 - m_HasFixedDuration: 1 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1102 &-3360105894821777026 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Jump - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: - - {fileID: -8626510112679481558} - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: cef6f9b8ec0beab4b88e6f4dd77f5923, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: ---- !u!1102 &-3109416563068774462 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Land - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: - - {fileID: 2651979714303655906} - - {fileID: -1449902651349316248} - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: 65275c0dd7f6a2d4f8469c70f1ed05b5, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: ---- !u!1101 &-1631153991909036912 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: [] - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 9132405649074356357} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 0 - m_HasExitTime: 1 - m_HasFixedDuration: 1 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &-1449902651349316248 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 2 - m_ConditionEvent: airborn - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 0} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 1 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 0 - m_HasExitTime: 0 - m_HasFixedDuration: 1 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1102 &-1407507127539071288 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: StartRun - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: - - {fileID: 7942601611081728091} - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: 32eb327e78f972148b3dc1af82d87c72, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: ---- !u!1107 &-87433385847552929 -AnimatorStateMachine: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Base Layer - m_ChildStates: - - serializedVersion: 1 - m_State: {fileID: 9132405649074356357} - m_Position: {x: 250, y: -10, z: 0} - - serializedVersion: 1 - m_State: {fileID: -3360105894821777026} - m_Position: {x: 450, y: 210, z: 0} - - serializedVersion: 1 - m_State: {fileID: 4014801967865307794} - m_Position: {x: 300, y: 320, z: 0} - - serializedVersion: 1 - m_State: {fileID: -3109416563068774462} - m_Position: {x: 200, y: 210, z: 0} - - serializedVersion: 1 - m_State: {fileID: -1407507127539071288} - m_Position: {x: 510, y: 50, z: 0} - - serializedVersion: 1 - m_State: {fileID: 3614093525302314329} - m_Position: {x: 510, y: -70, z: 0} - - serializedVersion: 1 - m_State: {fileID: 6109551287401904689} - m_Position: {x: 750, y: -10, z: 0} - m_ChildStateMachines: [] - m_AnyStateTransitions: - - {fileID: -6878608224570280004} - - {fileID: -4025803860441014948} - m_EntryTransitions: - - {fileID: 9028498521707221212} - m_StateMachineTransitions: {} - m_StateMachineBehaviours: [] - m_AnyStatePosition: {x: 610, y: 320, z: 0} - m_EntryPosition: {x: 270, y: 110, z: 0} - m_ExitPosition: {x: 60, y: 70, z: 0} - m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} - m_DefaultState: {fileID: 9132405649074356357} ---- !u!91 &9100000 -AnimatorController: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Player - serializedVersion: 5 - m_AnimatorParameters: - - m_Name: moving - m_Type: 4 - m_DefaultFloat: 0 - m_DefaultInt: 0 - m_DefaultBool: 0 - m_Controller: {fileID: 9100000} - - m_Name: jump - m_Type: 9 - m_DefaultFloat: 0 - m_DefaultInt: 0 - m_DefaultBool: 0 - m_Controller: {fileID: 9100000} - - m_Name: fall - m_Type: 9 - m_DefaultFloat: 0 - m_DefaultInt: 0 - m_DefaultBool: 0 - m_Controller: {fileID: 9100000} - - m_Name: airborn - m_Type: 4 - m_DefaultFloat: 0 - m_DefaultInt: 0 - m_DefaultBool: 0 - m_Controller: {fileID: 9100000} - m_AnimatorLayers: - - serializedVersion: 5 - m_Name: Base Layer - m_StateMachine: {fileID: -87433385847552929} - m_Mask: {fileID: 0} - m_Motions: [] - m_Behaviours: [] - m_BlendingMode: 0 - m_SyncedLayerIndex: -1 - m_DefaultWeight: 0 - m_IKPass: 0 - m_SyncedLayerAffectsTiming: 0 - m_Controller: {fileID: 9100000} ---- !u!1109 &1807663489023768798 -AnimatorTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 1 - m_ConditionEvent: jump - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: -3360105894821777026} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 1 ---- !u!1101 &2585772133770462678 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 2 - m_ConditionEvent: airborn - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: -3109416563068774462} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 0 - m_HasExitTime: 1 - m_HasFixedDuration: 0 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &2651979714303655906 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: [] - m_DstStateMachine: {fileID: -87433385847552929} - m_DstState: {fileID: 0} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0.25 - m_TransitionOffset: 0 - m_ExitTime: 0 - m_HasExitTime: 1 - m_HasFixedDuration: 1 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1102 &3614093525302314329 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: StopRun - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: - - {fileID: 6564945159879590472} - - {fileID: -6106642904432627373} - - {fileID: -1631153991909036912} - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: ac2725b05a471b44bbb31f28642b7f55, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: ---- !u!1109 &3809652522530214263 -AnimatorTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: [] - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 9132405649074356357} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 1 ---- !u!1102 &4014801967865307794 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Airborn - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: - - {fileID: 2585772133770462678} - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: 60cb5e95c1030634981e0557bbe42c7e, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: ---- !u!1102 &6109551287401904689 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Run - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: - - {fileID: -8388212156864459442} - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: f099fe9331aa86a42a63a91dcf31793e, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: ---- !u!1101 &6564945159879590472 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: [] - m_DstStateMachine: {fileID: -87433385847552929} - m_DstState: {fileID: 0} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 1 - m_HasExitTime: 1 - m_HasFixedDuration: 0 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &7942601611081728091 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: [] - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: 6109551287401904689} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 1 - m_HasExitTime: 1 - m_HasFixedDuration: 0 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1101 &8602053559700435507 -AnimatorStateTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 1 - m_ConditionEvent: moving - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: -1407507127539071288} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 3 - m_TransitionDuration: 0 - m_TransitionOffset: 0 - m_ExitTime: 0 - m_HasExitTime: 0 - m_HasFixedDuration: 1 - m_InterruptionSource: 0 - m_OrderedInterruption: 1 - m_CanTransitionToSelf: 1 ---- !u!1109 &9028498521707221212 -AnimatorTransition: - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: - m_Conditions: - - m_ConditionMode: 1 - m_ConditionEvent: moving - m_EventTreshold: 0 - m_DstStateMachine: {fileID: 0} - m_DstState: {fileID: -1407507127539071288} - m_Solo: 0 - m_Mute: 0 - m_IsExit: 0 - serializedVersion: 1 ---- !u!1102 &9132405649074356357 -AnimatorState: - serializedVersion: 6 - m_ObjectHideFlags: 1 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_Name: Idle - m_Speed: 1 - m_CycleOffset: 0 - m_Transitions: - - {fileID: 8602053559700435507} - m_StateMachineBehaviours: [] - m_Position: {x: 50, y: 50, z: 0} - m_IKOnFeet: 0 - m_WriteDefaultValues: 1 - m_Mirror: 0 - m_SpeedParameterActive: 0 - m_MirrorParameterActive: 0 - m_CycleOffsetParameterActive: 0 - m_TimeParameterActive: 0 - m_Motion: {fileID: 7400000, guid: 0de769b93d38c4b43bd8728eb4733b49, type: 2} - m_Tag: - m_SpeedParameter: - m_MirrorParameter: - m_CycleOffsetParameter: - m_TimeParameter: diff --git a/Assets/Prefabs/Player.prefab b/Assets/Prefabs/Player.prefab index 3bae704..01949b8 100644 --- a/Assets/Prefabs/Player.prefab +++ b/Assets/Prefabs/Player.prefab @@ -144,7 +144,7 @@ SpriteRenderer: m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 - m_Sprite: {fileID: 2055064200, guid: 72a632f763991754fb9722d38264d272, type: 3} + m_Sprite: {fileID: -1786744883, guid: 25bc31e9802a57c4db6f9eb7de7103c2, type: 3} m_Color: {r: 1, g: 1, b: 1, a: 1} m_FlipX: 0 m_FlipY: 0 @@ -165,7 +165,7 @@ Animator: m_GameObject: {fileID: 2776418409999972310} m_Enabled: 1 m_Avatar: {fileID: 0} - m_Controller: {fileID: 9100000, guid: 363aef300fba71f40ab5aa64ba12659f, type: 2} + m_Controller: {fileID: 9100000, guid: 263157a89cfad80489c5baefc615a3a7, type: 2} m_CullingMode: 0 m_UpdateMode: 0 m_ApplyRootMotion: 0 @@ -259,7 +259,7 @@ PolygonCollider2D: m_SpriteTilingProperty: border: {x: 0, y: 0, z: 0, w: 0} pivot: {x: 0.5, y: 0.5} - oldSize: {x: 1.2666667, y: 3} + oldSize: {x: 1.125, y: 2.75} newSize: {x: 1.0625, y: 2.625} adaptiveTilingThreshold: 0.5 drawMode: 0 @@ -324,6 +324,8 @@ MonoBehaviour: jumpForce: 0 damage: 0 health: 0 + jumpCount: 0 + spawnPoint: {x: 0, y: 0, z: 0} --- !u!114 &6691474245549666832 MonoBehaviour: m_ObjectHideFlags: 0 diff --git a/Assets/Scenes/Jungle.unity b/Assets/Scenes/Jungle.unity index a49259b..a948155 100644 --- a/Assets/Scenes/Jungle.unity +++ b/Assets/Scenes/Jungle.unity @@ -324970,14 +324970,6 @@ PrefabInstance: m_Modification: m_TransformParent: {fileID: 142095922} m_Modifications: - - target: {fileID: 2776418409611166768, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} - propertyPath: m_Layer - value: 8 - objectReference: {fileID: 0} - - target: {fileID: 2776418409812533936, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} - propertyPath: m_Layer - value: 8 - objectReference: {fileID: 0} - target: {fileID: 2776418409999972307, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} propertyPath: m_RootOrder value: 4 @@ -325026,13 +325018,5 @@ PrefabInstance: propertyPath: m_Name value: Player objectReference: {fileID: 0} - - target: {fileID: 2776418409999972310, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} - propertyPath: m_Layer - value: 8 - objectReference: {fileID: 0} - - target: {fileID: 2776418409999972310, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} - propertyPath: m_TagString - value: Player - objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} diff --git a/Assets/Scripts/Actors/Actor.cs b/Assets/Scripts/Actors/Actor.cs index 2e98974..55aed29 100644 --- a/Assets/Scripts/Actors/Actor.cs +++ b/Assets/Scripts/Actors/Actor.cs @@ -21,14 +21,14 @@ namespace MontanaJohns.Actors protected Animator _animator; protected Transform _transform; - public Stats stats; + protected Stats stats; protected Active activeItem; protected bool isGrappling; protected Vector2? grapplePoint = null; protected LayerMask groundLayers; Collection items; - public int health; + protected int health; protected int jumpCount; protected Vector2 acceleration; @@ -81,8 +81,13 @@ namespace MontanaJohns.Actors public virtual void Jump() { - if (jumpCount++ <= stats.maxJumps) + if(Physics2D.OverlapCircle(groundCheckPoint.position, 0.2f, groundLayers)) { + jumpCount = stats.maxJumps; + } + if (jumpCount > 0) + { + jumpCount--; _rigidBody.AddForce(Vector2.up * stats.jumpForce); _animator.SetTrigger("jump"); _animator.SetBool("airborn", true); @@ -127,12 +132,11 @@ namespace MontanaJohns.Actors { _animator.SetBool("airborn", true); - while (_rigidBody.velocity.y > 0 || !Physics2D.OverlapCircle(groundCheckPoint.position, 0.2f, groundLayers)) + while (!Physics2D.OverlapCircle(groundCheckPoint.position, 0.2f, groundLayers)) { - yield return new WaitForFixedUpdate(); + yield return new WaitForEndOfFrame(); } - jumpCount = 0; _animator.SetBool("airborn", false); yield break; diff --git a/Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png b/Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png new file mode 100644 index 0000000..fffc353 Binary files /dev/null and b/Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png differ diff --git a/Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png.meta b/Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png.meta new file mode 100644 index 0000000..e518a16 --- /dev/null +++ b/Assets/Sprites/Player/MontanaJohns/MontanaJohnsFinal.png.meta @@ -0,0 +1,474 @@ +fileFormatVersion: 2 +guid: 25bc31e9802a57c4db6f9eb7de7103c2 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + 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 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 2 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 16 + 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 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 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 + 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 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: + - serializedVersion: 2 + name: MontanaJohnsFinal_0 + rect: + serializedVersion: 2 + x: 40 + y: 160 + width: 18 + height: 44 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 51f3d86bcc2b0524db0b1e0397a5da20 + internalID: -1786744883 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_1 + rect: + serializedVersion: 2 + x: 152 + y: 160 + width: 18 + height: 44 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: cad92211f3de00d4cb3d69a075681d89 + internalID: 191790088 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_2 + rect: + serializedVersion: 2 + x: 248 + y: 160 + width: 18 + height: 43 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 61b412e83062a704da7a92e2b6a32c05 + internalID: -476690385 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_3 + rect: + serializedVersion: 2 + x: 33 + y: 80 + width: 39 + height: 44 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 058d23ea97d601645b3a225a60cc30b3 + internalID: 873809126 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_4 + rect: + serializedVersion: 2 + x: 132 + y: 80 + width: 40 + height: 43 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: de8362dee9081e741abc6a19e6eb17ca + internalID: -346341652 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_5 + rect: + serializedVersion: 2 + x: 234 + y: 80 + width: 36 + height: 41 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: f6e173756e87c0341a51efb27505496d + internalID: -2035052553 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_6 + rect: + serializedVersion: 2 + x: 338 + y: 80 + width: 30 + height: 40 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: af9c8511c50fc5f418e361c0a9f95731 + internalID: -762021199 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_7 + rect: + serializedVersion: 2 + x: 432 + y: 80 + width: 39 + height: 44 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 2d22573ab4c3c3740bec18d66e42f42c + internalID: 584818143 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_8 + rect: + serializedVersion: 2 + x: 530 + y: 80 + width: 40 + height: 43 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 4165b158c1097af48b207e75cb7fae2d + internalID: 1138914620 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_9 + rect: + serializedVersion: 2 + x: 634 + y: 80 + width: 35 + height: 41 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 28150ebb1a6396f4baf46621a0c69753 + internalID: 1394569422 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_10 + rect: + serializedVersion: 2 + x: 739 + y: 80 + width: 32 + height: 40 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 9f994a444abfc514c9823a3fe1f24f59 + internalID: 640910275 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_11 + rect: + serializedVersion: 2 + x: 337 + y: 0 + width: 25 + height: 46 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: ac9ad5537494db247b55b03a32d7d794 + internalID: -1743127331 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_12 + rect: + serializedVersion: 2 + x: 438 + y: 2 + width: 25 + height: 43 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 4cfa33e7634c9c84eb7dd72df3845a08 + internalID: 517512235 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_13 + rect: + serializedVersion: 2 + x: 537 + y: 5 + width: 26 + height: 40 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: a42ff6ae8cdefac40a7a669d6e6973fe + internalID: -116468388 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_14 + rect: + serializedVersion: 2 + x: 634 + y: 5 + width: 29 + height: 40 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: 3a23e74bd5633f149af36471fcbc1d76 + internalID: -2140250000 + vertices: [] + indices: + edges: [] + weights: [] + - serializedVersion: 2 + name: MontanaJohnsFinal_15 + rect: + serializedVersion: 2 + x: 733 + y: 0 + width: 31 + height: 45 + alignment: 0 + pivot: {x: 0, y: 0} + border: {x: 0, y: 0, z: 0, w: 0} + outline: [] + physicsShape: [] + tessellationDetail: 0 + bones: [] + spriteID: f013cbce44389e34d9560b730286ad46 + internalID: -289598290 + vertices: [] + indices: + edges: [] + weights: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + nameFileIdTable: + MontanaJohnsFinal_7: 584818143 + MontanaJohnsFinal_8: 1138914620 + MontanaJohnsFinal_5: -2035052553 + MontanaJohnsFinal_14: -2140250000 + MontanaJohnsFinal_6: -762021199 + MontanaJohnsFinal_13: -116468388 + MontanaJohnsFinal_11: -1743127331 + MontanaJohnsFinal_0: -1786744883 + MontanaJohnsFinal_1: 191790088 + MontanaJohnsFinal_4: -346341652 + MontanaJohnsFinal_3: 873809126 + MontanaJohnsFinal_10: 640910275 + MontanaJohnsFinal_12: 517512235 + MontanaJohnsFinal_2: -476690385 + MontanaJohnsFinal_9: 1394569422 + MontanaJohnsFinal_15: -289598290 + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png b/Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png deleted file mode 100644 index 053e559..0000000 Binary files a/Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png and /dev/null differ diff --git a/Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png.meta b/Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png.meta deleted file mode 100644 index 612054a..0000000 --- a/Assets/Sprites/Player/MontanaJohns/MontanaJohnsLandingPreRun.png.meta +++ /dev/null @@ -1,540 +0,0 @@ -fileFormatVersion: 2 -guid: 8b08bada3c2ac5e4cb65721a772f0f99 -TextureImporter: - internalIDToNameTable: [] - externalObjects: {} - serializedVersion: 11 - 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 - isReadable: 0 - streamingMipmaps: 0 - streamingMipmapsPriority: 0 - vTOnly: 0 - ignoreMasterTextureLimit: 0 - grayScaleToAlpha: 0 - generateCubemap: 6 - cubemapConvolution: 0 - seamlessCubemap: 0 - textureFormat: 1 - maxTextureSize: 2048 - textureSettings: - serializedVersion: 2 - filterMode: 0 - aniso: 1 - mipBias: 0 - wrapU: 1 - wrapV: 1 - wrapW: 1 - nPOTScale: 0 - lightmap: 0 - compressionQuality: 50 - spriteMode: 2 - spriteExtrude: 1 - spriteMeshType: 1 - alignment: 0 - spritePivot: {x: 0.5, y: 0.5} - spritePixelsToUnits: 16 - 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 - platformSettings: - - serializedVersion: 3 - buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 - resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 1 - compressionQuality: 50 - crunchedCompression: 0 - allowsAlphaSplitting: 0 - overridden: 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 - 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 - androidETC2FallbackOverride: 0 - forceMaximumCompressionQuality_BC6H_BC7: 0 - spriteSheet: - serializedVersion: 2 - sprites: - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_0 - rect: - serializedVersion: 2 - x: 0 - y: 161 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 7bd20026429302b4f937a2692191c495 - internalID: 1409862686 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_1 - rect: - serializedVersion: 2 - x: 600 - y: 161 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: effcf0774b53f794caaba2f4a25fefde - internalID: -161029916 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_2 - rect: - serializedVersion: 2 - x: 700 - y: 161 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: cea18626120fc1f4292393ab1b9db7bc - internalID: 1526622238 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_3 - rect: - serializedVersion: 2 - x: 0 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 01583759aca17564d9fc8d4ff7739e5d - internalID: 1256470140 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_4 - rect: - serializedVersion: 2 - x: 100 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 0cd0bfa24ca666a4fbd0b6bf86e08006 - internalID: -1042349849 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_5 - rect: - serializedVersion: 2 - x: 200 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 41cb4bb666edbed458752a2d9c9efca5 - internalID: 216792634 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_6 - rect: - serializedVersion: 2 - x: 300 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: e699e612a35ab064497869f077043622 - internalID: 1044303231 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_7 - rect: - serializedVersion: 2 - x: 400 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 8a46b9feb095f004487e87775afda903 - internalID: 299380834 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_8 - rect: - serializedVersion: 2 - x: 500 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 4f3f1c6c143762440a0c10e53c172020 - internalID: -1460522098 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_9 - rect: - serializedVersion: 2 - x: 600 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: f30d885d1fdb7474db05bb3b764f1ba8 - internalID: -1969183652 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_10 - rect: - serializedVersion: 2 - x: 700 - y: 81 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 1d51541ab5f6f8940b0f3e8056ffe79d - internalID: -919123645 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_11 - rect: - serializedVersion: 2 - x: 0 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 43f865f05c5f5384a9daaeb32a715139 - internalID: 508543913 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_12 - rect: - serializedVersion: 2 - x: 100 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: ecaf43ea5c36c6044948c16c538bd36e - internalID: -1075184750 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_13 - rect: - serializedVersion: 2 - x: 200 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 6d2c31700201c1440a2cf85c982a7f4d - internalID: -1586354681 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_14 - rect: - serializedVersion: 2 - x: 300 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 31016fa388aa3e749aa728060781af95 - internalID: 195716706 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_15 - rect: - serializedVersion: 2 - x: 400 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 40fcb2fd58e40114795f3f152086fa19 - internalID: -1728902432 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_16 - rect: - serializedVersion: 2 - x: 500 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: b1f2520e2a7ca7e419983e0c1794028c - internalID: 470777305 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_17 - rect: - serializedVersion: 2 - x: 600 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: de95cc37b62efea4791b4ccdaf19ebfd - internalID: 37177715 - vertices: [] - indices: - edges: [] - weights: [] - - serializedVersion: 2 - name: MontanaJohnsLandingPreRun_18 - rect: - serializedVersion: 2 - x: 700 - y: 1 - width: 100 - height: 79 - alignment: 0 - pivot: {x: 0, y: 0} - border: {x: 0, y: 0, z: 0, w: 0} - outline: [] - physicsShape: [] - tessellationDetail: 0 - bones: [] - spriteID: 5385afbc0fa433b40a09e33920d01f38 - internalID: -1727536245 - vertices: [] - indices: - edges: [] - weights: [] - outline: [] - physicsShape: [] - bones: [] - spriteID: 5e97eb03825dee720800000000000000 - internalID: 0 - vertices: [] - indices: - edges: [] - weights: [] - secondaryTextures: [] - nameFileIdTable: - MontanaJohnsLandingPreRun_8: -1460522098 - MontanaJohnsLandingPreRun_14: 195716706 - MontanaJohnsLandingPreRun_3: 1256470140 - MontanaJohnsLandingPreRun_5: 216792634 - MontanaJohnsLandingPreRun_16: 470777305 - MontanaJohnsLandingPreRun_11: 508543913 - MontanaJohnsLandingPreRun_0: 1409862686 - MontanaJohnsLandingPreRun_1: -161029916 - MontanaJohnsLandingPreRun_10: -919123645 - MontanaJohnsLandingPreRun_15: -1728902432 - MontanaJohnsLandingPreRun_7: 299380834 - MontanaJohnsLandingPreRun_4: -1042349849 - MontanaJohnsLandingPreRun_12: -1075184750 - MontanaJohnsLandingPreRun_2: 1526622238 - MontanaJohnsLandingPreRun_13: -1586354681 - MontanaJohnsLandingPreRun_18: -1727536245 - MontanaJohnsLandingPreRun_6: 1044303231 - MontanaJohnsLandingPreRun_9: -1969183652 - MontanaJohnsLandingPreRun_17: 37177715 - spritePackingTag: - pSDRemoveMatte: 0 - pSDShowRemoveMatteOption: 0 - userData: - assetBundleName: - assetBundleVariant: diff --git a/Assets/Sprites/Player/PrototypeHero.meta b/Assets/Sprites/Player/PrototypeHero.meta deleted file mode 100644 index c9f17a9..0000000 --- a/Assets/Sprites/Player/PrototypeHero.meta +++ /dev/null @@ -1,8 +0,0 @@ -fileFormatVersion: 2 -guid: 01ce197cf3d0b9c409dd3c8d49cd01cc -folderAsset: yes -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: -- cgit v1.2.3-70-g09d2 From 58d16dec85dbbb83c7ba503e735585f922bf67b9 Mon Sep 17 00:00:00 2001 From: Neil Kollack Date: Fri, 15 Apr 2022 00:32:41 -0500 Subject: feat: escape sequence --- Assets/Materials/Boulder.physicMaterial | 14 ++ Assets/Materials/Boulder.physicMaterial.meta | 8 + Assets/Prefabs/BoobyTrapSpawnPoint.prefab | 33 ++++ Assets/Prefabs/BoobyTrapSpawnPoint.prefab.meta | 7 + Assets/Prefabs/Boulder.prefab | 157 +++++++++++++++++ Assets/Prefabs/Boulder.prefab.meta | 7 + Assets/Prefabs/Treasure.prefab | 118 +++++++++++++ Assets/Prefabs/Treasure.prefab.meta | 7 + Assets/Scenes/Jungle.unity | 234 ++++++++++--------------- Assets/Scripts/Actors/Player.cs | 1 + Assets/Scripts/BoobyTrap.cs | 15 +- Assets/Scripts/Boulder.cs | 45 +++++ Assets/Scripts/Boulder.cs.meta | 11 ++ Assets/Scripts/LevelController.cs | 17 ++ Assets/Scripts/LevelController.cs.meta | 11 ++ Assets/Sprites/boulder.png | Bin 0 -> 2851 bytes Assets/Sprites/boulder.png.meta | 122 +++++++++++++ 17 files changed, 659 insertions(+), 148 deletions(-) create mode 100644 Assets/Materials/Boulder.physicMaterial create mode 100644 Assets/Materials/Boulder.physicMaterial.meta create mode 100644 Assets/Prefabs/BoobyTrapSpawnPoint.prefab create mode 100644 Assets/Prefabs/BoobyTrapSpawnPoint.prefab.meta create mode 100644 Assets/Prefabs/Boulder.prefab create mode 100644 Assets/Prefabs/Boulder.prefab.meta create mode 100644 Assets/Prefabs/Treasure.prefab create mode 100644 Assets/Prefabs/Treasure.prefab.meta create mode 100644 Assets/Scripts/Boulder.cs create mode 100644 Assets/Scripts/Boulder.cs.meta create mode 100644 Assets/Scripts/LevelController.cs create mode 100644 Assets/Scripts/LevelController.cs.meta create mode 100644 Assets/Sprites/boulder.png create mode 100644 Assets/Sprites/boulder.png.meta (limited to 'Assets/Scripts/Actors') diff --git a/Assets/Materials/Boulder.physicMaterial b/Assets/Materials/Boulder.physicMaterial new file mode 100644 index 0000000..25597b1 --- /dev/null +++ b/Assets/Materials/Boulder.physicMaterial @@ -0,0 +1,14 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!134 &13400000 +PhysicMaterial: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Boulder + dynamicFriction: 0.6 + staticFriction: 0.6 + bounciness: 0 + frictionCombine: 0 + bounceCombine: 0 diff --git a/Assets/Materials/Boulder.physicMaterial.meta b/Assets/Materials/Boulder.physicMaterial.meta new file mode 100644 index 0000000..dcfc1af --- /dev/null +++ b/Assets/Materials/Boulder.physicMaterial.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 714252d45e70fcb4ba37a7705319c2a7 +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 13400000 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/BoobyTrapSpawnPoint.prefab b/Assets/Prefabs/BoobyTrapSpawnPoint.prefab new file mode 100644 index 0000000..3dfb57e --- /dev/null +++ b/Assets/Prefabs/BoobyTrapSpawnPoint.prefab @@ -0,0 +1,33 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &4457831989902087284 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 4457831989902087285} + m_Layer: 0 + m_Name: BoobyTrapSpawnPoint + m_TagString: Untagged + m_Icon: {fileID: 3936346786652291628, guid: 0000000000000000d000000000000000, type: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &4457831989902087285 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4457831989902087284} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 478, y: 40.75, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} diff --git a/Assets/Prefabs/BoobyTrapSpawnPoint.prefab.meta b/Assets/Prefabs/BoobyTrapSpawnPoint.prefab.meta new file mode 100644 index 0000000..c29bdb0 --- /dev/null +++ b/Assets/Prefabs/BoobyTrapSpawnPoint.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 809b04c0b3e6e5b44b57498f12c5210a +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/Boulder.prefab b/Assets/Prefabs/Boulder.prefab new file mode 100644 index 0000000..f291057 --- /dev/null +++ b/Assets/Prefabs/Boulder.prefab @@ -0,0 +1,157 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &7977680014098188665 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7977680014098188645} + - component: {fileID: 7977680014098188644} + - component: {fileID: 7977680014098188667} + - component: {fileID: 7977680014098188666} + - component: {fileID: 7977680014098188646} + - component: {fileID: 7071841513841830746} + m_Layer: 10 + m_Name: Boulder + m_TagString: Enemy + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7977680014098188645 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7977680014098188665} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: -78.79, y: -4.2054057, z: -0.10407122} + m_LocalScale: {x: 10, y: 10, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!212 &7977680014098188644 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7977680014098188665} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 0 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + 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: 0 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: 21300000, guid: 648d147b41e0c5740bd0d01c60f6e07f, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 1, y: 1} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 +--- !u!58 &7977680014098188667 +CircleCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7977680014098188665} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: 0, y: 0} + serializedVersion: 2 + m_Radius: 0.5 +--- !u!50 &7977680014098188666 +Rigidbody2D: + serializedVersion: 4 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7977680014098188665} + m_BodyType: 0 + m_Simulated: 1 + m_UseFullKinematicContacts: 0 + m_UseAutoMass: 0 + m_Mass: 1 + m_LinearDrag: 0 + m_AngularDrag: 0.05 + m_GravityScale: 5 + m_Material: {fileID: 0} + m_Interpolate: 0 + m_SleepingMode: 1 + m_CollisionDetection: 0 + m_Constraints: 0 +--- !u!114 &7977680014098188646 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7977680014098188665} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 760b14f92dafdd34381066ba181a1f93, type: 3} + m_Name: + m_EditorClassIdentifier: + speed: 22 + maxSpeed: 10 +--- !u!58 &7071841513841830746 +CircleCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7977680014098188665} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 1 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: 0, y: 0} + serializedVersion: 2 + m_Radius: 0.55 diff --git a/Assets/Prefabs/Boulder.prefab.meta b/Assets/Prefabs/Boulder.prefab.meta new file mode 100644 index 0000000..0231156 --- /dev/null +++ b/Assets/Prefabs/Boulder.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: df7113e464c04124d85510ce7a86023f +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/Treasure.prefab b/Assets/Prefabs/Treasure.prefab new file mode 100644 index 0000000..a75de04 --- /dev/null +++ b/Assets/Prefabs/Treasure.prefab @@ -0,0 +1,118 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &4788021209095683739 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 4788021209095683717} + - component: {fileID: 4788021209095683716} + - component: {fileID: 4788021209095683719} + - component: {fileID: 4788021209095683718} + m_Layer: 0 + m_Name: Treasure + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &4788021209095683717 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4788021209095683739} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 511, y: 34.75, z: 1} + m_LocalScale: {x: 3, y: 3, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!212 &4788021209095683716 +SpriteRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4788021209095683739} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 0 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} + 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: 0 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_Sprite: {fileID: -492098402, guid: 54c37f1eaf80b5644aa7b2ab490d9045, type: 3} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_FlipX: 0 + m_FlipY: 0 + m_DrawMode: 0 + m_Size: {x: 0.5, y: 0.71875} + m_AdaptiveModeThreshold: 0.5 + m_SpriteTileMode: 0 + m_WasSpriteAssigned: 1 + m_MaskInteraction: 0 + m_SpriteSortPoint: 0 +--- !u!70 &4788021209095683719 +CapsuleCollider2D: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4788021209095683739} + m_Enabled: 1 + m_Density: 1 + m_Material: {fileID: 0} + m_IsTrigger: 1 + m_UsedByEffector: 0 + m_UsedByComposite: 0 + m_Offset: {x: 0, y: 0} + m_Size: {x: 0.5, y: 0.71875} + m_Direction: 0 +--- !u!114 &4788021209095683718 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 4788021209095683739} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 042e1a970c0394244831fbd869ab4c75, type: 3} + m_Name: + m_EditorClassIdentifier: + boobyTrap: {fileID: 7977680014098188665, guid: df7113e464c04124d85510ce7a86023f, type: 3} + spawnPoint: {fileID: 4457831989902087284, guid: 809b04c0b3e6e5b44b57498f12c5210a, type: 3} diff --git a/Assets/Prefabs/Treasure.prefab.meta b/Assets/Prefabs/Treasure.prefab.meta new file mode 100644 index 0000000..90e9036 --- /dev/null +++ b/Assets/Prefabs/Treasure.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: f7f57f82eafa6be46b71b71e9117b9bf +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scenes/Jungle.unity b/Assets/Scenes/Jungle.unity index a948155..5f3f615 100644 --- a/Assets/Scenes/Jungle.unity +++ b/Assets/Scenes/Jungle.unity @@ -3038,37 +3038,6 @@ Transform: m_CorrespondingSourceObject: {fileID: 2894666046278553864, guid: 8f6c22559c50b594496aaea2c749a6a4, type: 3} m_PrefabInstance: {fileID: 413676159} m_PrefabAsset: {fileID: 0} ---- !u!1 &432252850 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 432252851} - m_Layer: 0 - m_Name: BoobyTrapSpawnPoint - m_TagString: Untagged - m_Icon: {fileID: 3936346786652291628, guid: 0000000000000000d000000000000000, type: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &432252851 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 432252850} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 478, y: 61, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_ConstrainProportionsScale: 0 - m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 7 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1001 &433709214 PrefabInstance: m_ObjectHideFlags: 0 @@ -3399,6 +3368,7 @@ GameObject: - component: {fileID: 519420032} - component: {fileID: 519420031} - component: {fileID: 519420029} + - component: {fileID: 519420033} m_Layer: 0 m_Name: Main Camera m_TagString: MainCamera @@ -3472,6 +3442,19 @@ Transform: m_Father: {fileID: 0} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &519420033 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 519420028} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 37b6adf04336a564cb72facb6e18b968, type: 3} + m_Name: + m_EditorClassIdentifier: + treasure: {fileID: 4788021209095683739, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} --- !u!1 &544966461 GameObject: m_ObjectHideFlags: 0 @@ -10990,120 +10973,6 @@ Transform: m_CorrespondingSourceObject: {fileID: 5267721061292888517, guid: 47596d04057f55146bb75d8cea49ccdb, type: 3} m_PrefabInstance: {fileID: 808576702} m_PrefabAsset: {fileID: 0} ---- !u!1 &813538383 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 813538385} - - component: {fileID: 813538384} - - component: {fileID: 813538387} - - component: {fileID: 813538386} - m_Layer: 0 - m_Name: Treasure - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!212 &813538384 -SpriteRenderer: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 813538383} - m_Enabled: 1 - m_CastShadows: 0 - m_ReceiveShadows: 0 - m_DynamicOccludee: 1 - m_StaticShadowCaster: 0 - m_MotionVectors: 1 - m_LightProbeUsage: 1 - m_ReflectionProbeUsage: 1 - m_RayTracingMode: 0 - m_RayTraceProcedural: 0 - m_RenderingLayerMask: 1 - m_RendererPriority: 0 - m_Materials: - - {fileID: 10754, guid: 0000000000000000f000000000000000, type: 0} - 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: 0 - m_MinimumChartSize: 4 - m_AutoUVMaxDistance: 0.5 - m_AutoUVMaxAngle: 89 - m_LightmapParameters: {fileID: 0} - m_SortingLayerID: 0 - m_SortingLayer: 0 - m_SortingOrder: 0 - m_Sprite: {fileID: -492098402, guid: 54c37f1eaf80b5644aa7b2ab490d9045, type: 3} - m_Color: {r: 1, g: 1, b: 1, a: 1} - m_FlipX: 0 - m_FlipY: 0 - m_DrawMode: 0 - m_Size: {x: 0.5, y: 0.71875} - m_AdaptiveModeThreshold: 0.5 - m_SpriteTileMode: 0 - m_WasSpriteAssigned: 1 - m_MaskInteraction: 0 - m_SpriteSortPoint: 0 ---- !u!4 &813538385 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 813538383} - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 511, y: 34.75, z: 1} - m_LocalScale: {x: 3, y: 3, z: 1} - m_ConstrainProportionsScale: 0 - m_Children: [] - m_Father: {fileID: 0} - m_RootOrder: 6 - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!114 &813538386 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 813538383} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 042e1a970c0394244831fbd869ab4c75, type: 3} - m_Name: - m_EditorClassIdentifier: ---- !u!70 &813538387 -CapsuleCollider2D: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 813538383} - m_Enabled: 1 - m_Density: 1 - m_Material: {fileID: 0} - m_IsTrigger: 1 - m_UsedByEffector: 0 - m_UsedByComposite: 0 - m_Offset: {x: 0, y: 0} - m_Size: {x: 0.5, y: 0.71875} - m_Direction: 0 --- !u!1001 &814781393 PrefabInstance: m_ObjectHideFlags: 0 @@ -324923,7 +324792,7 @@ PrefabInstance: objectReference: {fileID: 0} - target: {fileID: 3218036852510780957, guid: 5634fecaf16a6234cbecd102e2675311, type: 3} propertyPath: m_LocalPosition.y - value: -73.5 + value: -86.75 objectReference: {fileID: 0} - target: {fileID: 3218036852510780957, guid: 5634fecaf16a6234cbecd102e2675311, type: 3} propertyPath: m_LocalPosition.z @@ -324957,12 +324826,77 @@ PrefabInstance: propertyPath: m_LocalEulerAnglesHint.z value: 0 objectReference: {fileID: 0} + - target: {fileID: 3218036852510780958, guid: 5634fecaf16a6234cbecd102e2675311, type: 3} + propertyPath: m_Size.x + value: 123.91608 + objectReference: {fileID: 0} + - target: {fileID: 3218036852510780958, guid: 5634fecaf16a6234cbecd102e2675311, type: 3} + propertyPath: m_Offset.x + value: -20.458038 + objectReference: {fileID: 0} - target: {fileID: 3218036852510780959, guid: 5634fecaf16a6234cbecd102e2675311, type: 3} propertyPath: m_Name value: BottomlessPit objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 5634fecaf16a6234cbecd102e2675311, type: 3} +--- !u!1001 &4788021208292696788 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 0} + m_Modifications: + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_RootOrder + value: 6 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalPosition.x + value: 511 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalPosition.y + value: 34.75 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalPosition.z + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683717, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 4788021209095683739, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} + propertyPath: m_Name + value: Treasure + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: f7f57f82eafa6be46b71b71e9117b9bf, type: 3} --- !u!1001 &6691474245549666830 PrefabInstance: m_ObjectHideFlags: 0 @@ -325018,5 +324952,13 @@ PrefabInstance: propertyPath: m_Name value: Player objectReference: {fileID: 0} + - target: {fileID: 6634715301000360765, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} + propertyPath: m_SpriteTilingProperty.oldSize.x + value: 1.125 + objectReference: {fileID: 0} + - target: {fileID: 6634715301000360765, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} + propertyPath: m_SpriteTilingProperty.oldSize.y + value: 2.75 + objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} diff --git a/Assets/Scripts/Actors/Player.cs b/Assets/Scripts/Actors/Player.cs index 3537aa7..1b2155a 100644 --- a/Assets/Scripts/Actors/Player.cs +++ b/Assets/Scripts/Actors/Player.cs @@ -57,6 +57,7 @@ namespace MontanaJohns.Actors { if(health <= 0) { + MainCamera.GetComponent().ResetLevel(); ResetStats(); health = stats.maxHealth; transform.position = spawnPoint; diff --git a/Assets/Scripts/BoobyTrap.cs b/Assets/Scripts/BoobyTrap.cs index 72fc6ce..2ce736c 100644 --- a/Assets/Scripts/BoobyTrap.cs +++ b/Assets/Scripts/BoobyTrap.cs @@ -5,12 +5,23 @@ using UnityEngine; public class BoobyTrap : MonoBehaviour { + [SerializeField] GameObject boobyTrap; + [SerializeField] GameObject spawnPoint; + + bool triggered; + + private void Start() + { + Instantiate(spawnPoint); + } + private void OnTriggerEnter2D(Collider2D collision) { - if (collision.gameObject.tag == "Player") + if (collision.gameObject.tag == "Player" && !triggered) { + triggered = true; gameObject.GetComponent().sprite = null; - //TODO spawn the boulder + Instantiate(boobyTrap, spawnPoint.transform.position, Quaternion.identity); } } } diff --git a/Assets/Scripts/Boulder.cs b/Assets/Scripts/Boulder.cs new file mode 100644 index 0000000..5aa2beb --- /dev/null +++ b/Assets/Scripts/Boulder.cs @@ -0,0 +1,45 @@ +using MontanaJohns.Actors; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class Boulder : MonoBehaviour +{ + [SerializeField] float speed; + [SerializeField] float maxSpeed; + + private GameObject player; + private Rigidbody2D rb; + + // Start is called before the first frame update + void Start() + { + player = GameObject.FindGameObjectWithTag("Player"); + rb = transform.GetComponent(); + + } + + // Update is called once per frame + void Update() + { + if (player.transform.position.x < transform.position.x) + { + transform.Rotate(0, 0, 1); + } + else + { + transform.Rotate(0, 0, -1); + } + transform.position = Vector2.MoveTowards(transform.position, new Vector2(player.transform.position.x, 0), speed * Time.deltaTime); + if(rb.velocity.x >= maxSpeed) + rb.velocity = new Vector2(maxSpeed, rb.velocity.y); + } + + private void OnTriggerEnter2D(Collider2D collision) + { + if (collision.gameObject.tag == "Player") + { + collision.GetComponent().TakeDamage(999); + } + } +} diff --git a/Assets/Scripts/Boulder.cs.meta b/Assets/Scripts/Boulder.cs.meta new file mode 100644 index 0000000..d053a76 --- /dev/null +++ b/Assets/Scripts/Boulder.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 760b14f92dafdd34381066ba181a1f93 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/LevelController.cs b/Assets/Scripts/LevelController.cs new file mode 100644 index 0000000..6d91d71 --- /dev/null +++ b/Assets/Scripts/LevelController.cs @@ -0,0 +1,17 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class LevelController : MonoBehaviour +{ + [SerializeField] GameObject treasure; + // Start is called before the first frame update + + public void ResetLevel() + { + Destroy(GameObject.Find("Boulder(Clone)")); + Destroy(GameObject.Find("BoobyTrapSpawnPoint(Clone)")); + Destroy(GameObject.Find("Treasure")); + Instantiate(treasure); + } +} diff --git a/Assets/Scripts/LevelController.cs.meta b/Assets/Scripts/LevelController.cs.meta new file mode 100644 index 0000000..b672ba6 --- /dev/null +++ b/Assets/Scripts/LevelController.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 37b6adf04336a564cb72facb6e18b968 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sprites/boulder.png b/Assets/Sprites/boulder.png new file mode 100644 index 0000000..f6b8017 Binary files /dev/null and b/Assets/Sprites/boulder.png differ diff --git a/Assets/Sprites/boulder.png.meta b/Assets/Sprites/boulder.png.meta new file mode 100644 index 0000000..87698ef --- /dev/null +++ b/Assets/Sprites/boulder.png.meta @@ -0,0 +1,122 @@ +fileFormatVersion: 2 +guid: 648d147b41e0c5740bd0d01c60f6e07f +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + 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 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 256 + 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 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 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 + 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 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + nameFileIdTable: {} + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: -- cgit v1.2.3-70-g09d2 From ee708901a74b9d442e2e8397b699a568928a8dc7 Mon Sep 17 00:00:00 2001 From: Neil Kollack Date: Fri, 15 Apr 2022 01:07:41 -0500 Subject: feat: health on HUD --- Assets/Prefabs/Player.prefab | 26 ++- Assets/Scenes/Jungle.unity | 427 ++++++++++++++++++++++++++++++++++++++++- Assets/Scripts/Actors/Actor.cs | 6 +- Assets/Scripts/UI.cs | 43 +++++ Assets/Scripts/UI.cs.meta | 11 ++ Assets/Sprites/heart.png | Bin 0 -> 1849 bytes Assets/Sprites/heart.png.meta | 122 ++++++++++++ 7 files changed, 617 insertions(+), 18 deletions(-) create mode 100644 Assets/Scripts/UI.cs create mode 100644 Assets/Scripts/UI.cs.meta create mode 100644 Assets/Sprites/heart.png create mode 100644 Assets/Sprites/heart.png.meta (limited to 'Assets/Scripts/Actors') diff --git a/Assets/Prefabs/Player.prefab b/Assets/Prefabs/Player.prefab index 01949b8..c5f16a4 100644 --- a/Assets/Prefabs/Player.prefab +++ b/Assets/Prefabs/Player.prefab @@ -79,6 +79,7 @@ GameObject: - component: {fileID: 6634715301000360765} - component: {fileID: 2776418409999972327} - component: {fileID: 6691474245549666832} + - component: {fileID: 1811562883} m_Layer: 8 m_Name: Player m_TagString: Player @@ -317,14 +318,7 @@ MonoBehaviour: jumpForce: 1200 damage: 0 groundCheckPoint: {fileID: 2776418409611166769} - stats: - maxHealth: 0 - speedMultiplier: 0 - maxJumps: 0 - jumpForce: 0 - damage: 0 health: 0 - jumpCount: 0 spawnPoint: {x: 0, y: 0, z: 0} --- !u!114 &6691474245549666832 MonoBehaviour: @@ -340,3 +334,21 @@ MonoBehaviour: m_EditorClassIdentifier: cursorTexture: {fileID: 2800000, guid: 5b4111e5d50609b4ca5b2eda3c125f71, type: 3} disableDistance: 20 +--- !u!114 &1811562883 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2776418409999972310} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: e59148c42c36f95438441511c27f1728, type: 3} + m_Name: + m_EditorClassIdentifier: + heartCount: 3 + hearts: + - {fileID: 0} + - {fileID: 0} + - {fileID: 0} + heartSprite: {fileID: 21300000, guid: 454fb9103270323479e05b92e4ecf4d0, type: 3} diff --git a/Assets/Scenes/Jungle.unity b/Assets/Scenes/Jungle.unity index 5f3f615..ee256d9 100644 --- a/Assets/Scenes/Jungle.unity +++ b/Assets/Scenes/Jungle.unity @@ -10061,6 +10061,109 @@ Grid: m_CellGap: {x: 0, y: 0, z: 0} m_CellLayout: 0 m_CellSwizzle: 0 +--- !u!1 &614050341 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 614050345} + - component: {fileID: 614050344} + - component: {fileID: 614050343} + - component: {fileID: 614050342} + m_Layer: 5 + m_Name: Canvas + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &614050342 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 614050341} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3} + m_Name: + m_EditorClassIdentifier: + m_IgnoreReversedGraphics: 1 + m_BlockingObjects: 0 + m_BlockingMask: + serializedVersion: 2 + m_Bits: 4294967295 +--- !u!114 &614050343 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 614050341} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3} + m_Name: + m_EditorClassIdentifier: + m_UiScaleMode: 1 + m_ReferencePixelsPerUnit: 100 + m_ScaleFactor: 1 + m_ReferenceResolution: {x: 800, y: 600} + m_ScreenMatchMode: 0 + m_MatchWidthOrHeight: 0 + m_PhysicalUnit: 3 + m_FallbackScreenDPI: 96 + m_DefaultSpriteDPI: 96 + m_DynamicPixelsPerUnit: 1 + m_PresetInfoIsWorld: 0 +--- !u!223 &614050344 +Canvas: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 614050341} + m_Enabled: 1 + serializedVersion: 3 + m_RenderMode: 0 + m_Camera: {fileID: 0} + m_PlaneDistance: 100 + m_PixelPerfect: 0 + m_ReceivesEvents: 1 + m_OverrideSorting: 0 + m_OverridePixelPerfect: 0 + m_SortingBucketNormalizedSize: 0 + m_AdditionalShaderChannelsFlag: 0 + m_SortingLayerID: 0 + m_SortingOrder: 0 + m_TargetDisplay: 0 +--- !u!224 &614050345 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 614050341} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0, y: 0, z: 0} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 1313057978} + - {fileID: 886349456} + - {fileID: 2019698000} + m_Father: {fileID: 0} + m_RootOrder: 7 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 0} + m_AnchorMax: {x: 0, y: 0} + m_AnchoredPosition: {x: 0, y: 0} + m_SizeDelta: {x: 0, y: 0} + m_Pivot: {x: 0, y: 0} --- !u!1001 &620326469 PrefabInstance: m_ObjectHideFlags: 0 @@ -11159,6 +11262,82 @@ Transform: m_CorrespondingSourceObject: {fileID: 295837306294826493, guid: 8b360e413c8b3f947a7b0f072403514d, type: 3} m_PrefabInstance: {fileID: 874616603} m_PrefabAsset: {fileID: 0} +--- !u!1 &886349455 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 886349456} + - component: {fileID: 886349458} + - component: {fileID: 886349457} + m_Layer: 5 + m_Name: Heart (1) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &886349456 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 886349455} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.25, y: 0.25, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 614050345} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 50, y: -20} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &886349457 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 886349455} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 454fb9103270323479e05b92e4ecf4d0, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &886349458 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 886349455} + m_CullTransparentMesh: 1 --- !u!1001 &888586544 PrefabInstance: m_ObjectHideFlags: 0 @@ -12537,6 +12716,82 @@ Transform: m_CorrespondingSourceObject: {fileID: 5267721061292888517, guid: 47596d04057f55146bb75d8cea49ccdb, type: 3} m_PrefabInstance: {fileID: 1303550327} m_PrefabAsset: {fileID: 0} +--- !u!1 &1313057977 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1313057978} + - component: {fileID: 1313057980} + - component: {fileID: 1313057979} + m_Layer: 5 + m_Name: Heart + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &1313057978 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1313057977} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.25, y: 0.25, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 614050345} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 20, y: -20} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &1313057979 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1313057977} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 454fb9103270323479e05b92e4ecf4d0, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &1313057980 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1313057977} + m_CullTransparentMesh: 1 --- !u!1 &1316225623 GameObject: m_ObjectHideFlags: 0 @@ -14138,6 +14393,82 @@ Transform: m_Father: {fileID: 3073203} m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: -27.178} +--- !u!1 &1670021802 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1670021805} + - component: {fileID: 1670021804} + - component: {fileID: 1670021803} + m_Layer: 0 + m_Name: EventSystem + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!114 &1670021803 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1670021802} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 01614664b831546d2ae94a42149d80ac, type: 3} + m_Name: + m_EditorClassIdentifier: + m_MoveRepeatDelay: 0.5 + m_MoveRepeatRate: 0.1 + m_XRTrackingOrigin: {fileID: 0} + m_ActionsAsset: {fileID: -944628639613478452, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_PointAction: {fileID: -1654692200621890270, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_MoveAction: {fileID: -8784545083839296357, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_SubmitAction: {fileID: 392368643174621059, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_CancelAction: {fileID: 7727032971491509709, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_LeftClickAction: {fileID: 3001919216989983466, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_MiddleClickAction: {fileID: -2185481485913320682, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_RightClickAction: {fileID: -4090225696740746782, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_ScrollWheelAction: {fileID: 6240969308177333660, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_TrackedDevicePositionAction: {fileID: 6564999863303420839, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_TrackedDeviceOrientationAction: {fileID: 7970375526676320489, guid: ca9f5fa95ffab41fb9a615ab714db018, type: 3} + m_DeselectOnBackgroundClick: 1 + m_PointerBehavior: 0 +--- !u!114 &1670021804 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1670021802} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 76c392e42b5098c458856cdf6ecaaaa1, type: 3} + m_Name: + m_EditorClassIdentifier: + m_FirstSelected: {fileID: 0} + m_sendNavigationEvents: 1 + m_DragThreshold: 10 +--- !u!4 &1670021805 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1670021802} + 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_RootOrder: 8 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1001 &1675512535 PrefabInstance: m_ObjectHideFlags: 0 @@ -324353,6 +324684,82 @@ Transform: m_CorrespondingSourceObject: {fileID: 5267721061292888517, guid: 47596d04057f55146bb75d8cea49ccdb, type: 3} m_PrefabInstance: {fileID: 1983189679} m_PrefabAsset: {fileID: 0} +--- !u!1 &2019697999 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 2019698000} + - component: {fileID: 2019698002} + - component: {fileID: 2019698001} + m_Layer: 5 + m_Name: Heart (2) + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!224 &2019698000 +RectTransform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2019697999} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.25, y: 0.25, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 614050345} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} + m_AnchorMin: {x: 0, y: 1} + m_AnchorMax: {x: 0, y: 1} + m_AnchoredPosition: {x: 80, y: -20} + m_SizeDelta: {x: 100, y: 100} + m_Pivot: {x: 0.5, y: 0.5} +--- !u!114 &2019698001 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2019697999} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} + m_Name: + m_EditorClassIdentifier: + m_Material: {fileID: 0} + m_Color: {r: 1, g: 1, b: 1, a: 1} + m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} + m_Maskable: 1 + m_OnCullStateChanged: + m_PersistentCalls: + m_Calls: [] + m_Sprite: {fileID: 21300000, guid: 454fb9103270323479e05b92e4ecf4d0, type: 3} + m_Type: 0 + m_PreserveAspect: 0 + m_FillCenter: 1 + m_FillMethod: 4 + m_FillAmount: 1 + m_FillClockwise: 1 + m_FillOrigin: 0 + m_UseSpriteMesh: 0 + m_PixelsPerUnitMultiplier: 1 +--- !u!222 &2019698002 +CanvasRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2019697999} + m_CullTransparentMesh: 1 --- !u!1 &2035916049 GameObject: m_ObjectHideFlags: 0 @@ -324904,6 +325311,18 @@ PrefabInstance: m_Modification: m_TransformParent: {fileID: 142095922} m_Modifications: + - target: {fileID: 1811562883, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} + propertyPath: hearts.Array.data[0] + value: + objectReference: {fileID: 1313057979} + - target: {fileID: 1811562883, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} + propertyPath: hearts.Array.data[1] + value: + objectReference: {fileID: 886349457} + - target: {fileID: 1811562883, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} + propertyPath: hearts.Array.data[2] + value: + objectReference: {fileID: 2019698001} - target: {fileID: 2776418409999972307, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} propertyPath: m_RootOrder value: 4 @@ -324952,13 +325371,5 @@ PrefabInstance: propertyPath: m_Name value: Player objectReference: {fileID: 0} - - target: {fileID: 6634715301000360765, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} - propertyPath: m_SpriteTilingProperty.oldSize.x - value: 1.125 - objectReference: {fileID: 0} - - target: {fileID: 6634715301000360765, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} - propertyPath: m_SpriteTilingProperty.oldSize.y - value: 2.75 - objectReference: {fileID: 0} m_RemovedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3} diff --git a/Assets/Scripts/Actors/Actor.cs b/Assets/Scripts/Actors/Actor.cs index 55aed29..63854d9 100644 --- a/Assets/Scripts/Actors/Actor.cs +++ b/Assets/Scripts/Actors/Actor.cs @@ -26,11 +26,11 @@ namespace MontanaJohns.Actors protected bool isGrappling; protected Vector2? grapplePoint = null; protected LayerMask groundLayers; - Collection items; - - protected int health; + protected Collection items; protected int jumpCount; protected Vector2 acceleration; + + public int health; protected virtual void Awake() { diff --git a/Assets/Scripts/UI.cs b/Assets/Scripts/UI.cs new file mode 100644 index 0000000..0c0802e --- /dev/null +++ b/Assets/Scripts/UI.cs @@ -0,0 +1,43 @@ +using MontanaJohns.Actors; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class UI : MonoBehaviour +{ + [SerializeField] private int heartCount; + [SerializeField] private Image[] hearts; + [SerializeField] private Sprite heartSprite; + + public int health; + + private void Start() + { + for (int i = 0; i < hearts.Length; i++) + { + if (i < heartCount) + hearts[i].enabled = true; + else + hearts[i].enabled = false; + } + } + + private void Update() + { + health = gameObject.GetComponent().health; + for(int i = 0; i < heartCount; i++) + { + /* Can be used to have two sprites, one empty/one full/half full, etc. + if (i < health) + hearts[i].sprite = heartSprite; + else + hearts[i].sprite = heartSprite2; + */ + if (i < health) + hearts[i].enabled = true; + else + hearts[i].enabled = false; + } + } +} diff --git a/Assets/Scripts/UI.cs.meta b/Assets/Scripts/UI.cs.meta new file mode 100644 index 0000000..6dadbf3 --- /dev/null +++ b/Assets/Scripts/UI.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: e59148c42c36f95438441511c27f1728 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Sprites/heart.png b/Assets/Sprites/heart.png new file mode 100644 index 0000000..890f86d Binary files /dev/null and b/Assets/Sprites/heart.png differ diff --git a/Assets/Sprites/heart.png.meta b/Assets/Sprites/heart.png.meta new file mode 100644 index 0000000..b982324 --- /dev/null +++ b/Assets/Sprites/heart.png.meta @@ -0,0 +1,122 @@ +fileFormatVersion: 2 +guid: 454fb9103270323479e05b92e4ecf4d0 +TextureImporter: + internalIDToNameTable: [] + externalObjects: {} + serializedVersion: 11 + 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 + isReadable: 0 + streamingMipmaps: 0 + streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 + grayScaleToAlpha: 0 + generateCubemap: 6 + cubemapConvolution: 0 + seamlessCubemap: 0 + textureFormat: 1 + maxTextureSize: 2048 + textureSettings: + serializedVersion: 2 + filterMode: 0 + aniso: 1 + mipBias: 0 + wrapU: 1 + wrapV: 1 + wrapW: 1 + nPOTScale: 0 + lightmap: 0 + compressionQuality: 50 + spriteMode: 1 + spriteExtrude: 1 + spriteMeshType: 1 + alignment: 0 + spritePivot: {x: 0.5, y: 0.5} + spritePixelsToUnits: 254 + 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 + platformSettings: + - serializedVersion: 3 + buildTarget: DefaultTexturePlatform + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 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 + 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 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 0 + spriteSheet: + serializedVersion: 2 + sprites: [] + outline: [] + physicsShape: [] + bones: [] + spriteID: 5e97eb03825dee720800000000000000 + internalID: 0 + vertices: [] + indices: + edges: [] + weights: [] + secondaryTextures: [] + nameFileIdTable: {} + spritePackingTag: + pSDRemoveMatte: 0 + pSDShowRemoveMatteOption: 0 + userData: + assetBundleName: + assetBundleVariant: -- cgit v1.2.3-70-g09d2