Quantcast
Channel: Unity Forum
Viewing all articles
Browse latest Browse all 1466670

2D Enemy Script

$
0
0
Hello everyone! I'm helping create a game for a college final and am not very well versed in C# or computer programming as a whole. I created an enemy script that is supposed to trigger an enemy attack when the player is close. For reference, I used an enemy tutorial from inScope Studios on Youtube and modified it to use OnTriggerEnter rather than OnCollider.
Code (CSharp):
  1. using System.Collections;
  2. using System.Collections.Generic;
  3. using UnityEngine;
  4.  
  5. public class EnemyScript : MonoBehaviour...
2D Enemy Script

Viewing all articles
Browse latest Browse all 1466670

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>