Too Many Attributes
» Entity actions » Obscure kill

Obscure kill

too-many-attributes:obscure_killpower type

When the holder kills a player, that player's death message is hidden from chat. Give it a message to show that instead.

FieldTypeDefaultDescription
messageText componentoptionalThe message shown in place of the death message, written like /tellraw's. Left out: no message at all.
asString"victim"Who @s is in the message's selectors, scores and nbt: victim (the dead player) or holder.
bientity_conditionBi-entity conditionoptionalActor: the holder. Target: the victim. Kills that fail it keep their usual death message.

It also accepts Origins' usual condition. Kills while it's false keep their usual death message.

  • The killer is the player or mob credited for the kill, the same one the death message would name. That covers arrows, and a fall or lava death right after a hit.
  • Only players' death messages are changed.
  • The death screen shows the replacement message, or a blank one when the message is hidden.
  • Who sees it follows the showDeathMessages gamerule and the victim's team death message setting, like the usual message.
  • Several powers on the killer: the first one with a message is used. If none has one, the message is hidden.
  • message can be a string, an object or an array, the same as /tellraw's.

Example: "Silent assassin". Kills while sneaking leave no message.

json
{
  "type": "too-many-attributes:obscure_kill",
  "condition": {
    "type": "origins:sneaking"
  }
}

Example: "Vanished". The death message becomes the victim's name and a gray line, with no killer named.

json
{
  "type": "too-many-attributes:obscure_kill",
  "message": [
    {
      "selector": "@s"
    },
    {
      "text": " vanished without a trace",
      "color": "gray",
      "italic": true
    }
  ]
}