Unity 5: 2D Platformer: Trigger/Collisions problem
HI, So I have been working on a little first 2d platformer for android. And I made my enemy move and when I attach a restart level script to the enemy, the player can pass through the enemy. I put a little box collider in the middle of the enemy to see if the player would end up triggering the script if stuck inside the enemy but it doesn't seem to work still. The video will give you visual of what is happening and the player model is the same one from the Sample assets right now. I have also posted the load level script I use.
Reloading Script:
using UnityEngine;
namespace Assets { public class LoadLevel2 : MonoBehaviour { private void OnTriggerEnter2D(Collider2D other) { if (other.tag == "Player") Application.LoadLevel("2"); } } }
VIDEO: [https://vid.me/cLhd]