How to have a different entity get affected during player animation

Started by PixelKid on

Topic category: Advanced modding

Last seen on 15:36, 5. Aug 2024
Joined May 2024
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to have a different entity get affected during player animation

I have been working on a mod for the last 6 months and while I'm waiting on  fixing a problem, I decided to address this.

I am working on adding Abilities and spells to the Minecraft game and am wondering how to damage another entity or cause it to play another animation on animation contact, and how it is possible to do a fly animation, would that be overriding the motion vector of entity, or will the animation keep it in the air when it goes up in animation.

Example:

A player uses the punch ability to punch a zombie, in return the zombie gets 5 damage dealt and plays the Fall animation where it falls over.

Second: is it possible to Fail an animation (the player times the sword swing wrong and falls_over animation happens.)

Note: I am planning to use Blockbench with geckolib plugin and the mcreator plugins Player animator and nerdy's geckolib plugin.

Any Help will be appreciated! -PixelKid