13
0
geforkt von Mirrors/Paper
Paper/paper-api
Bukkit/Spigot 7396e8f7c4 Recalculate damage modifiers in event for old method. Fixes BUKKIT-5681
When we added the new API in EntityDamageEvent to give control over the
various things that modify the final damage done we caused a change in
behavior for users of the old #setDamage(double) method. Before changing
the damage would happen before the modifiers were calculated so they would
be based on the final damage value from the event. Now they are calculated
at the beginning so changing the damage does not change the modifiers.

To allow the old style and the new to coexist we now expose the vanilla
modifer calculations to the event in the form of Function objects. These
are used in #setDamage(double) to calculate the difference in the modifier
between the old damage and the new and apply this difference to the current
modifier. The difference is between the vanilla values for both damage
values and is applied on top of the event's modifier value as this should
make old and new API usage work together in a way that isn't surprising.

By: Travis Watkins <amaranth@ubuntu.com>
2014-07-09 16:19:27 -05:00
..
src Recalculate damage modifiers in event for old method. Fixes BUKKIT-5681 2014-07-09 16:19:27 -05:00
.gitignore Ignore all .DS_Store files, not just root folder 2013-03-30 18:04:11 -03:00
CONTRIBUTING.md Minecraft spec has changed and we're required to follow. We now build with Java 6. 2013-07-10 19:30:45 -04:00
LICENCE.txt We're GPL. 2011-01-02 10:57:42 +01:00
pom.xml Update Bukkit for Minecraft 1.7.10 2014-06-25 20:29:14 -05:00
README.md Add missing new line to README.md 2013-03-18 22:35:10 -04:00

Bukkit

A Minecraft Server API.

Website: http://bukkit.org
Bugs/Suggestions: http://leaky.bukkit.org
Contributing Guidelines: CONTRIBUTING.md

Compilation

We use maven to handle our dependencies.

  • Install Maven 3
  • Check out this repo and: mvn clean install