Advertisement
jayhillx

DamageSource

Jun 5th, 2021
220
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. public ITextComponent getDeathMessage(LivingEntity playerEntityIn) {
  2. PlayerEntity playerEntity = (PlayerEntity) playerEntityIn;
  3. String s = "death.attack." + this.damageType;
  4. String s1 = s + ".boundPlayer";
  5.  
  6. playerEntityIn.getCapability(BindingCapabilities.LIFE_BOUND_CAPABILITY).ifPresent(cap -> {
  7. UUID uuid = cap.getUUID();
  8. PlayerEntity other = playerEntityIn.getServer().getPlayerList().getPlayerByUUID(cap.getUUID());
  9.  
  10. });
  11.  
  12. return playerEntity != null ? new TranslationTextComponent(s1, , playerEntity.getGameProfile()) : new TranslationTextComponent(s, playerEntityIn.getDisplayName());
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement