mirror of
https://github.com/Leahnaya/TheKingsRace.git
synced 2026-08-24 03:14:39 -05:00
Fixed dPlayerMovement & dWallrun references
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
fileFormatVersion: 2
|
||||
<<<<<<< HEAD:Assets/Scripts/PlayerScripts/DebugPlayer.meta
|
||||
guid: 236528fef9e9ed54fa77a41f6facd741
|
||||
guid: 4cd5ae7ca30110140ac070f8d0126019
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
=======
|
||||
|
||||
@@ -21,7 +21,7 @@ public class dWallRun : NetworkBehaviour
|
||||
public float wallGravityDownForce = 20f;
|
||||
|
||||
[Space]
|
||||
PlayerMovement playerMovementController;
|
||||
dPlayerMovement playerMovementController;
|
||||
|
||||
Vector3[] directions;
|
||||
RaycastHit[] hits;
|
||||
@@ -53,7 +53,7 @@ public class dWallRun : NetworkBehaviour
|
||||
|
||||
void Start()
|
||||
{
|
||||
playerMovementController = GetComponent<PlayerMovement>();
|
||||
playerMovementController = GetComponent<dPlayerMovement>();
|
||||
|
||||
directions = new Vector3[]{
|
||||
Vector3.right,
|
||||
|
||||
@@ -37,7 +37,7 @@ public class dPlayerMovement : NetworkBehaviour
|
||||
private float distToGround;
|
||||
|
||||
//Wallrunning
|
||||
private WallRun wallRun;
|
||||
private dWallRun wallRun;
|
||||
|
||||
//Ground Check
|
||||
public bool isGrounded; //Better custom is grounded
|
||||
@@ -91,7 +91,7 @@ public class dPlayerMovement : NetworkBehaviour
|
||||
|
||||
capCol.enabled = false;
|
||||
//Wallrun
|
||||
wallRun = gameObject.GetComponent<WallRun>();
|
||||
wallRun = gameObject.GetComponent<dWallRun>();
|
||||
|
||||
up = this.gameObject.GetComponentInParent<Transform>().up;
|
||||
}
|
||||
@@ -239,7 +239,7 @@ public class dPlayerMovement : NetworkBehaviour
|
||||
public void AddImpact(Vector3 dir, float force)
|
||||
{
|
||||
|
||||
if (!IsLocalPlayer) { return; }
|
||||
//if (!IsLocalPlayer) { return; }
|
||||
|
||||
dir.Normalize();
|
||||
if (dir.y < 0) dir.y = -dir.y; // reflect down force on the ground
|
||||
|
||||
@@ -101,10 +101,6 @@ public class PlayerMovement : NetworkBehaviour
|
||||
|
||||
// Don't do movement unless this is the local player controlling it
|
||||
// Otherwise we let the server handle moving us
|
||||
<<<<<<< HEAD
|
||||
|
||||
=======
|
||||
>>>>>>> Particles
|
||||
//if (!IsLocalPlayer) { return; }
|
||||
|
||||
// Don't lock the cursor multiple times if this isn't the local player
|
||||
|
||||
Reference in New Issue
Block a user