mirror of
https://github.com/frizbee19/FebGameJam.git
synced 2026-10-11 18:19:11 +00:00
Moved Some stuff around before the merge
I move stuff :)
This commit is contained in:
1 parent
8486b14d17
commit
ce568ed8e5
8 files changed
+70
-21
No files matched your search
@@ -0,0 +1,30 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class ScriptRayHit : MonoBehaviour
|
||||
{
|
||||
|
||||
public RaycastHit2D hit;
|
||||
public Ray ray;
|
||||
private int counter;
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
counter = 0;
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
hit = Physics2D.Raycast(transform.position, transform.TransformDirection(Vector2.right), 4f);
|
||||
if (hit)
|
||||
{
|
||||
//Debug.Log(" Hit a wall "+ hit.collider.name);
|
||||
//Debug.Log(counter);
|
||||
}
|
||||
counter++;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user