Added assets from old repo
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
using UnityEngine;
|
||||
|
||||
public class BackWallCheck : MonoBehaviour
|
||||
{
|
||||
public bool backTouchingWall;
|
||||
private playerController PlayerController;
|
||||
void Start()
|
||||
{
|
||||
PlayerController = GameObject.Find("Player").GetComponent<playerController>();
|
||||
}
|
||||
private void OnCollisionEnter2D(Collision2D other)
|
||||
{
|
||||
if (other.gameObject.layer == 6 && PlayerController.isGrounded == false) PlayerController.Flip();
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user