Guest User

Untitled

a guest
Jul 21st, 2018
78
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. public class DrowningDamage extends EnvironmentalDamage {
  2.  
  3. public DrowningDamage(FileConfiguration fileConfiguration) {
  4. super(fileConfiguration);
  5. }
  6.  
  7. @Nonnull
  8. @Override
  9. public String getIconName() {
  10. return "drowning-damage";
  11. }
  12.  
  13. @Nonnull
  14. @Override
  15. public EnvironmentDamageType getEnvironment() {
  16. return EnvironmentDamageType.DROWNING;
  17. }
  18.  
  19. @Nonnull
  20. @Override
  21. public String getCauseName() {
  22. return "Drowning";
  23. }
  24.  
  25. @Override
  26. public boolean isApplicable(EntityDamageEvent event) {
  27. return event.getCause() == EntityDamageEvent.DamageCause.DROWNING;
  28. }
  29. }
RAW Paste Data