- Home /
3d Buzz 2D tutorial - CharacterController2D - Enemies.
If anyone has done this tutorial,
I only have the one issue to resolve, on applying the CharacterController2D to the enemy (which I previously used with the player and works fine)
The Enemy just bounces off the screen when I press play and falls to eternity.
has anybody come across this
I can provide screenshots of the script and a little video if that helps.
It seems that anything I attach the charactercontroller2d script to (apart from the player) causes it to fall through the screen
Answer by maca912 · Oct 30, 2014 at 01:09 AM
I've actually corrected this by bringing in a
_controller.HandleCollisions = true;
collider2D.enabled = true;
I placed it in the Update section
on the simple enemy ai.
I also found out that because i had inverted the X axis on the enemy image, the raycast inverted also, causing the enemy to get locked in any platform it bumped into.
I flipped the image in photoshop, reverted the scale and brought it back in to the project and that's seemed to have sorted it.
though when the enemy re-spawns back to its original larger size. I'm working on a way around this.
Your answer
Follow this Question
Related Questions
How to make Enemy shoot at Player Top Down 1 Answer
Damaging Enemies 1 Answer
[PUN] Getting warnings and having problems with instantiation and PhotonView 1 Answer
Enemy keeps moving in one direction. Help pls! 2 Answers
How I make my enemy face the player or flip towards player (top-down game)? 0 Answers