OK So I am progressing through my game and I have come up with an issue.

Due to the way the animations work for 2d, I am running all the animations for the player in a customer player controller. This includes the swing sword animation.

Going through the tutorial for the real time battle it is having me add the Damage Dealer component on the sword.

In my case, I added it to the hit box the sword generates when the animation is fired since its only active during that time period and its based on what direction the player is facing. This may not be the best way.. but It works.

My problem is the enemy or no player is taking any damage or doing any damage.

I had to modify most of what I did in the tutorial, but I think I have it all set up right.

Any idea what I am missing?
  • Hm, hard to tell without knowing your setup.

    General advice:
    - make sure you're using 2D colliders and they're set up correctly (e.g. setting them to be triggers when using the trigger start types)
    - make sure the damage dealer is activated long enough to do damage > when using Mecanim animations, keep in mind that they're not reporting any play time back, so waiting for an animation to finish will only be done if you defined a duration in ORK's animation setup
    - pause the game during the attack and check if the collider of the damage dealer actually overlaps with a damage zone of the enemy :)
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.