OvercastNetwork / SportBukkit

CraftBukkit and Bukkit modifications that improve stability and add new features
99 stars 84 forks source link

Fix maxNoDamageTicks being cut in half #98

Open jedediah opened 10 years ago

jedediah commented 10 years ago

For no apparent reason, noDamageTicks was counting down from maxNoDamageTicks to maxNoDamageTicks/2. Both of these values can be set through the Bukkit API, but there is no correction for this strange offset. As a result, the value passed to setMaxNoDamageTicks would effectively be cut in half, and the value passed to setNoDamageTicks would be reduced by maxNoDamageTicks/2.

tonybruess commented 10 years ago

Missing two // CraftBukkit comments

jedediah commented 10 years ago

added comments

ttaylorr commented 10 years ago

Looks good to merge

tonybruess commented 10 years ago

One thing. Bukkit/CraftBukkit@bccc961ddf29fa2c9463e5648fc425a78fa4a7b5 changed the damage API and mentioned the changes affecting noDamageTicks. Not sure exactly what they did, but would it be better to update SportBukkit? I updated it a while ago but it caused issues with our kill tracking.