Im getting this error and i dont know why
NullReferenceException: Object reference not set to an instance of an object EnemyMovement.Update () (at Assets/scripts/Enemy/EnemyMovement.cs:27) this is the script it is refering to using...
View ArticleNavmesh with finding closest player
I already have code to find the closest player and go towards them but how do I implement this while using NavMesh so I can avoid walls? Code: using UnityEngine; using System.Collections; public class...
View ArticleHow to use dashing as a combat mechanic?
I'm making my first game in unity and I'm trying to make a simple 2D platformer combat game. I got the movement and dashing to work and now I want to use dashing as a way to fight. In my player script...
View ArticleHow to handle knockback with large swarms of enemy
A main aspect of my game is it being a horde hack and slash, but I've run into the issue of how do I handle knocking back enemies when they collide with other enemies? my enemies are moved using...
View ArticleWy does the enemy shake when it gets to the player?
using System.Collections; using System.Collections.Generic; using UnityEngine; public class groundEnemy : MonoBehaviour { [SerializeField] Transform player; [SerializeField] Transform distancePoint;...
View ArticleWhy does the enemy shake when it gets to the player?,Why does my enemy shake...
public class groundEnemy1 : MonoBehaviour { public GameObject player; public bool flip; public float speed; // Start is called before the first frame update void Start() { } // Update is called once...
View ArticleHelp with obstacle avoidance for 2D top-down game
Hello everyone, I need help implementing an obstacle avoidance maneuver for enemies in a 2D top-down game. The obstacles have the layer and tag 'Asteroid' or 'Station', and the enemies should navigate...
View ArticlePlease help with the script: If crouch not kill if !crouched kill
I wanna do , that if the Bunny collide with the player (Tag "Player") while the player is crouching that the Bunny cant collide with the player (walk trough the Player) but if the bunny collides while...
View Article