Shot Script angefangen kleine änderung am AR Model
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
using UnityEngine;
|
||||
|
||||
public class Shoot : MonoBehaviour
|
||||
{
|
||||
[SerializeField] GameObject bulletPrefab;
|
||||
// Start is called once before the first execution of Update after the MonoBehaviour is created
|
||||
void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
if (Input.GetKeyDown(KeyCode.Mouse0))
|
||||
{
|
||||
Shot();
|
||||
}
|
||||
}
|
||||
public void Shot()
|
||||
{
|
||||
Instantiate(bulletPrefab);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
fileFormatVersion: 2
|
||||
guid: a10d4b5b33d924c428453e46c9513163
|
||||
Reference in New Issue
Block a user