aboutsummaryrefslogtreecommitdiffstats
path: root/Assets
diff options
context:
space:
mode:
authorNeil Kollack <nkollack@gmail.com>2022-04-25 14:08:29 -0500
committerNeil Kollack <nkollack@gmail.com>2022-04-25 14:08:29 -0500
commit8937508dc82ea0e35b2ca3db22fb0aa0a45daa1a (patch)
treeb696290f517ccb36917621ac248cd4ba13a18787 /Assets
parentae8cb8133f521d3223c1cba9d81ce62b3d4937b1 (diff)
fix: WebGL grapple movement
Diffstat (limited to 'Assets')
-rw-r--r--Assets/Prefabs/Player.prefab4
-rw-r--r--Assets/Scenes/Jungle.unity8
-rw-r--r--Assets/Scripts/Actors/Actor.cs7
3 files changed, 5 insertions, 14 deletions
diff --git a/Assets/Prefabs/Player.prefab b/Assets/Prefabs/Player.prefab
index d955ce6..fd46928 100644
--- a/Assets/Prefabs/Player.prefab
+++ b/Assets/Prefabs/Player.prefab
@@ -24,7 +24,7 @@ Transform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 2776418409611166768}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
- m_LocalPosition: {x: -0.375, y: -1.5, z: 0}
+ m_LocalPosition: {x: -0.5, y: -1.5, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
@@ -391,7 +391,7 @@ Transform:
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8892911079024906682}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
- m_LocalPosition: {x: 0.375, y: -1.5, z: 0}
+ m_LocalPosition: {x: 0.5, y: -1.5, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
diff --git a/Assets/Scenes/Jungle.unity b/Assets/Scenes/Jungle.unity
index 2f6721b..8537840 100644
--- a/Assets/Scenes/Jungle.unity
+++ b/Assets/Scenes/Jungle.unity
@@ -438568,10 +438568,6 @@ PrefabInstance:
propertyPath: hearts.Array.data[2]
value:
objectReference: {fileID: 2019698001}
- - target: {fileID: 2776418409611166769, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3}
- propertyPath: m_LocalPosition.x
- value: -0.5
- objectReference: {fileID: 0}
- target: {fileID: 2776418409999972307, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3}
propertyPath: m_RootOrder
value: 4
@@ -438620,10 +438616,6 @@ PrefabInstance:
propertyPath: m_Name
value: Player
objectReference: {fileID: 0}
- - target: {fileID: 5336306221325820075, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3}
- propertyPath: m_LocalPosition.x
- value: 0.5
- objectReference: {fileID: 0}
m_RemovedComponents: []
m_SourcePrefab: {fileID: 100100000, guid: b2169aaeb9a0e4542b1fb9d601bcc4b2, type: 3}
--- !u!114 &7434619225285215647
diff --git a/Assets/Scripts/Actors/Actor.cs b/Assets/Scripts/Actors/Actor.cs
index d342032..c28abd5 100644
--- a/Assets/Scripts/Actors/Actor.cs
+++ b/Assets/Scripts/Actors/Actor.cs
@@ -121,16 +121,15 @@ namespace MontanaJohns.Actors
}
public virtual void MoveY(float inputX, float inputY, float doNotExceed, float maxSpeedModifier = 0f)
{
- Debug.Log(inputY);
if(_rigidBody.position.y <= doNotExceed)
{
var maxSpeed = stats.maxSpeed + maxSpeedModifier;
- _rigidBody.AddForce(new Vector2(0, inputY * stats.speedMultiplier * 10));
+ _rigidBody.AddForce(new Vector2(0, inputY * stats.speedMultiplier * 20));
- if (inputY < 0 && Mathf.Abs(_rigidBody.velocity.y) > maxSpeed)
+ /*if (inputY < 0 && Mathf.Abs(_rigidBody.velocity.y) > maxSpeed)
_rigidBody.velocity = new Vector2(_rigidBody.velocity.x, -maxSpeed);
else if (inputY > 0 && Mathf.Abs(_rigidBody.velocity.y) > maxSpeed)
- _rigidBody.velocity = new Vector2(_rigidBody.velocity.x, maxSpeed);
+ _rigidBody.velocity = new Vector2(_rigidBody.velocity.x, maxSpeed);*/
}
}