Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
MythicMobs MythicMobs
  • Project overview
    • Project overview
    • Details
    • Activity
  • Issues 148
    • Issues 148
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Operations
    • Operations
    • Incidents
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Activity
  • Create a new issue
  • Issue Boards
Collapse sidebar
  • MythicCraft
  • MythicMobsMythicMobs
  • Issues
  • #889

Closed
Open
Created Aug 04, 2022 by 0tickpulse@0tickpulse

(Bug) preventknockback true on damage, damagepercent, basedamage mechanics cause damage event to have unknown damager

Summary

In damage, damagepercent, and basedamage mechanics, there is an option preventknockback. This option is intended to prevent the damage event from causing any knockback for the target. However, if you set preventknockback to true in a damage/damagepercent/basedamage mechanic, the damage event has an unknown damager.

Steps to reproduce

  1. Create a test mob:
TestMob:
  Template: TemplateSkills
  Type: IRON_GOLEM
  Display: "Test Mob"
  Health: 3000000
  Damage: 0
  Options:
    NoAI: True
  Skills:
    - actionmessage{m="&7Damager<&co> &c<trigger.name>"} @PIR{r=100} ~onDamaged
  1. Create two skills:
Damage1:
  Skills:
  - damage{amount=1;preventknockback=false} @EIR{r=5}
Damage2:
  Skills:
  - damage{amount=1;preventknockback=true} @EIR{r=5}
  1. Spawn TestMob, move within 5 blocks of the mob, and cast the two damage skills.

The issue

Damage1 works as intended. The action message displays Damager: <your username>. However, Damage2 does not work as intended. The actionbar message displays Damager: Unknown.

Why is this significant?

Firstly, if you use preventknockback=true in your damage skill, this disables the @Trigger targeter for mobs. In other words, you cannot get the damager/cast skills on the damager.

Secondly, this causes issues with other plugins. For example, many party plugins (tested: McMMO, Parties and Friends) disable PVP in the party. However, that won't work if the damager is unknown.

Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking