Minecraft:Commands/kill: Difference between revisions
More actions
Sync: updated from Minecraft |
Sync: updated from Minecraft |
||
| (2 intermediate revisions by the same user not shown) | |||
| Line 8: | Line 8: | ||
}} | }} | ||
Kills | Kills [[Minecraft:Entity|entities]] (players, mobs, items, etc.). | ||
== Usage == | == Usage == | ||
| Line 69: | Line 69: | ||
|{{HistoryLine||v1.2.6|dev=server 0.2.8|Added {{cmd|kill|link=none}}. It currently deals {{hp|1000}} [[Minecraft:damage]].}} | |{{HistoryLine||v1.2.6|dev=server 0.2.8|Added {{cmd|kill|link=none}}. It currently deals {{hp|1000}} [[Minecraft:damage]].}} | ||
|{{HistoryLine|java}} | |{{HistoryLine|java}} | ||
|{{HistoryLine||1.3.1|dev=12w16a|{{cmd|kill|link=none}} is now usable in singleplayer.|Parsing of the command is now more strict, rejecting extra characters after the command name (such as {{cmd|killme|link=none}} or {{cmd|killed|link=none}}). However, arguments are still ignored, meaning {{cmd|kill playername|link=none}} still only kills the executor.|{{cmd|kill|link=none}} now uses void damage instead of generic damage, bypassing armor. The death message is now "<var>player</var> fell out of the world" instead of "<var>player</var> died".|{{cmd|kill|link=none}} now prints the message "Ouch | |{{HistoryLine||1.3.1|dev=12w16a|{{cmd|kill|link=none}} is now usable in singleplayer.|Parsing of the command is now more strict, rejecting extra characters after the command name (such as {{cmd|killme|link=none}} or {{cmd|killed|link=none}}). However, arguments are still ignored, meaning {{cmd|kill playername|link=none}} still only kills the executor.|{{cmd|kill|link=none}} now uses void damage instead of generic damage, bypassing armor. The death message is now "<var>player</var> fell out of the world" instead of "<var>player</var> died".|{{cmd|kill|link=none}} now prints the message "Ouch. That look{{sic}} like it hurt." on execution.}} | ||
|{{HistoryLine||1.6.1|dev=13w24b|{{cmd|kill|link=none}} now deals 3.4×10{{^|38}} damage.}} | |{{HistoryLine||1.6.1|dev=13w24b|{{cmd|kill|link=none}} now deals 3.4×10{{^|38}} damage.}} | ||
|{{HistoryLine||1.8|dev=14w02a|Added <code>(player{{!}}entity)</code> argument to {{cmd|kill|link=none}}.|Replaced the "Ouch! That looked like it hurt" message with "Killed <var>player</var>".}} | |{{HistoryLine||1.8|dev=14w02a|Added <code>(player{{!}}entity)</code> argument to {{cmd|kill|link=none}}.|Replaced the "Ouch! That looked like it hurt" message with "Killed <var>player</var>".}} | ||
| Line 97: | Line 97: | ||
[[Minecraft:ja:コマンド/kill]] | [[Minecraft:ja:コマンド/kill]] | ||
[[Minecraft:ko:명령어/kill]] | [[Minecraft:ko:명령어/kill]] | ||
[[Minecraft:lzh:令/kill]] | |||
[[Minecraft:pt:Comandos/kill]] | [[Minecraft:pt:Comandos/kill]] | ||
[[Minecraft:ru:Команды консоли/kill]] | [[Minecraft:ru:Команды консоли/kill]] | ||
[[Minecraft:uk:Команди консолі/kill]] | [[Minecraft:uk:Команди консолі/kill]] | ||
[[Minecraft:zh:命令/kill]] | [[Minecraft:zh:命令/kill]] | ||
Latest revision as of 11:06, 15 August 2026
Template:Redirect Template:Infobox command
Kills entities (players, mobs, items, etc.).
Usage
Directly kills living targets compulsorily (directly removes the entity) and prompts Template:Cd, or Template:Cd if multiple entities are killed, which is irrespective of any of the targeted mob(s)' protective effects (Minecraft:armor, Minecraft:Protection, and Minecraft:Resistance). However, the damage can be adjusted by the Minecraft:ender dragon. Minecraft:Totems of undying can't be triggered when their owner(s) die(s) because of this command.
When the command kills mob(s), it issues the appropriate Minecraft:death message. Players and mobs killed this way drop loot, and Minecraft:slimes, Minecraft:magma cubes, and Minecraft:sulfur cubes that are not of minimum size spawn smaller ones. Non-mob entities disappear if they are targeted.
Template:IN, Minecraft:ender dragons killed by this command will skip their death animation and immediately open the Minecraft:exit portal.
Template:IN, players in Minecraft:Creative mode cannot be killed using this command.
Syntax
- Java Edition
kill [<targets>]
- Bedrock Edition
kill [target: target]
Arguments
- Specifies the target(s) to kill. If not specified, defaults to the player who executed the command.
- Template:Arg desc
Result
Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table
Output
Template:Output table Template:Output table Template:Output table Template:Output table Template:Output table Template:Output table
Examples
- To kill the player executing the command:
kill @sorkill - To kill the player Steve:
kill Steve - To kill item entities:
kill @e[type=item] - To kill all entities except players (if there are too many entities, some won’t be killed.) :
kill @e[type=!player] - To kill all creepers within 10 blocks:
- Template:El:
kill @e[distance=..10,type=creeper] - Template:El:
kill @e[r=10,type=creeper]
- Template:El:
- To kill all arrows that are stuck in a Minecraft:target:
kill @e[type=arrow,nbt={inBlockState:{Name:"minecraft:target"}}]Template:Only
History
Java Edition
Bedrock Edition
External links
Minecraft:de:Befehl/kill Minecraft:es:Comandos/kill Minecraft:fr:Commandes/kill Minecraft:it:Comandi/kill Minecraft:ja:コマンド/kill Minecraft:ko:명령어/kill Minecraft:lzh:令/kill Minecraft:pt:Comandos/kill Minecraft:ru:Команды консоли/kill Minecraft:uk:Команди консолі/kill Minecraft:zh:命令/kill