Minecraft:Commands/ban: Difference between revisions
More actions
Remove broken links to missing pages |
Fix template calls: add MC/ prefix |
||
| Line 1: | Line 1: | ||
{{About|the command that kicks and bans players from a server|the command that only kicks players|Commands/kick}} | {{About|the command that kicks and bans players from a server|the command that only kicks players|Commands/kick}} | ||
{{Redirect|Blocked|the game mechanic that prevents an attack from taking effect|Blocking}} | {{MC/Redirect|Blocked|the game mechanic that prevents an attack from taking effect|Blocking}} | ||
{{Exclusive|java}} | {{MC/Exclusive|java}} | ||
These commands control a [[Minecraft:Server|server's]] banlist, or blacklist. A blacklist is a list of players or IP addresses that are not allowed to connect to the server. Bans supersede any whitelisting in place. | These commands control a [[Minecraft:Server|server's]] banlist, or blacklist. A blacklist is a list of players or IP addresses that are not allowed to connect to the server. Bans supersede any whitelisting in place. | ||
| Line 18: | Line 18: | ||
=== Arguments === | === Arguments === | ||
{{ | {{MC/Argument|targets|game_profile}} | ||
: Specifies the player profile(s) to be added to the blacklist. | : Specifies the player profile(s) to be added to the blacklist. | ||
: {{ | : {{MC/Arg desc|je=game_profile}} | ||
{{ | {{MC/Argument|reason|message}} | ||
: Message to display to the banned player, to other operators, and in the server logs. If unspecified, defaults to <code>Banned by an operator.</code> | : Message to display to the banned player, to other operators, and in the server logs. If unspecified, defaults to <code>Banned by an operator.</code> | ||
: {{ | : {{MC/Arg desc|je=message}} | ||
=== Result === | === Result === | ||
| Line 35: | Line 35: | ||
=== Output === | === Output === | ||
{{Output table}} | {{MC/Output table}} | ||
{{Output table|edition=je|On fail|N/A|0|0}} | {{MC/Output table|edition=je|On fail|N/A|0|0}} | ||
{{Output table|On success|N/A|1|the number of new player names added to blacklist.}} | {{MC/Output table|On success|N/A|1|the number of new player names added to blacklist.}} | ||
{{Output table}} | {{MC/Output table}} | ||
== ban-ip == | == ban-ip == | ||
| Line 53: | Line 53: | ||
=== Arguments === | === Arguments === | ||
{{ | {{MC/Argument|targets|string}} | ||
: Specifies the IP address to be added to the blacklist. Can also be a name of an online player, which represents the IP of that player. | : Specifies the IP address to be added to the blacklist. Can also be a name of an online player, which represents the IP of that player. | ||
: {{ | : {{MC/Arg desc|je=string|type=word}} | ||
{{ | {{MC/Argument|reason|message}} | ||
: Message to display to the banned player, to other operators, and in the server logs. If unspecified, defaults to <code>Banned by an operator.</code> | : Message to display to the banned player, to other operators, and in the server logs. If unspecified, defaults to <code>Banned by an operator.</code> | ||
: {{ | : {{MC/Arg desc|je=message}} | ||
=== Result === | === Result === | ||
| Line 70: | Line 70: | ||
=== Output === | === Output === | ||
{{Output table}} | {{MC/Output table}} | ||
{{Output table|edition=je|On fail|N/A|0|0}} | {{MC/Output table|edition=je|On fail|N/A|0|0}} | ||
{{Output table|On success|N/A|1|the number of online players that connecting with the specified IP}} | {{MC/Output table|On success|N/A|1|the number of online players that connecting with the specified IP}} | ||
{{Output table}} | {{MC/Output table}} | ||
== banlist == | == banlist == | ||
| Line 94: | Line 94: | ||
=== Output === | === Output === | ||
{{Output table}} | {{MC/Output table}} | ||
{{Output table|edition=je|On success|N/A|1|the number of entries in the specified list.}} | {{MC/Output table|edition=je|On success|N/A|1|the number of entries in the specified list.}} | ||
{{Output table}} | {{MC/Output table}} | ||
== banip == | == banip == | ||
| Line 104: | Line 104: | ||
}} | }} | ||
Bans a player by IP number. Cannot be undone in-game; {{ | Bans a player by IP number. Cannot be undone in-game; {{MC/Cd|banned-ip.txt}} must manually be changed. | ||
The Classic equivalent of {{ | The Classic equivalent of {{MC/Cmd|ban-ip}}. | ||
=== Syntax === | === Syntax === | ||
| Line 113: | Line 113: | ||
== History == | == History == | ||
{{HistoryTable | {{HistoryTable | ||
|{{HistoryLine|java classic}} | |{{MC/HistoryLine|java classic}} | ||
|{{HistoryLine||rowspawn=2|0.0.16a|Added {{ | |{{HistoryLine||rowspawn=2|0.0.16a|Added {{MC/Cmd|ban|link=none}} and {{MC/Cmd|banip|link=none}}.}} | ||
|{{HistoryLine|java indev}} | |{{MC/HistoryLine|java indev}} | ||
|{{HistoryLine||0.31|Due to Indev's lack of support for servers, commands are no longer usable.}} | |{{MC/HistoryLine||0.31|Due to Indev's lack of support for servers, commands are no longer usable.}} | ||
|{{HistoryLine|java alpha}} | |{{MC/HistoryLine|java alpha}} | ||
|{{HistoryLine||v1.0.16|{{ | |{{HistoryLine||v1.0.16|{{MC/Cmd|banip|link=none}} has been renamed to {{MC/Cmd|ban-ip|link=none}}. | ||
|{{ | |{{MC/Cmd|ban|link=none}} and {{MC/Cmd|ban-ip|link=none}} are now usable again. | ||
|Added {{ | |Added {{MC/Cmd|banlist|link=none}}.}} | ||
}} | }} | ||
| Line 127: | Line 127: | ||
== Navigation == | == Navigation == | ||
{{Navbox commands}} | {{MC/Navbox commands}} | ||
de:Befehl/ban | de:Befehl/ban | ||
Latest revision as of 20:08, 9 April 2026
|
For the {{{Description}}} of the same name, see [[{{{Destination}}}]]. |
Template:Hatnote Script error: No such module "Exclusive".
These commands control a server's banlist, or blacklist. A blacklist is a list of players or IP addresses that are not allowed to connect to the server. Bans supersede any whitelisting in place.
ban
Adds the player profile(s) into the server blacklist, which prevents anyone from connecting to the server with uuids of these profiles.
Syntax
ban <targets> [<reason>]
Arguments
<targets>: game_profile
- Specifies the player profile(s) to be added to the blacklist.
- {{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|game_profile}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}
<reason>: message
- Message to display to the banned player, to other operators, and in the server logs. If unspecified, defaults to
Banned by an operator. - {{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|message}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}
Result
Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table
Output
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:situation-{{#var:output-table-lines}}|On fail}}{{#vardefine:output1-{{#var:output-table-lines}}|N/A}}{{#vardefine:output2-{{#var:output-table-lines}}|0}}{{#vardefine:output3-{{#var:output-table-lines}}|0}}{{#vardefine:command-row-{{#var:commands-num}}|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-editions-num|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-edition-{{#var:output-editions-num}}|je}}{{#vardefine:output-edition-row-{{#var:output-editions-num}}|1}} {{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:situation-{{#var:output-table-lines}}|On success}}{{#vardefine:output1-{{#var:output-table-lines}}|N/A}}{{#vardefine:output2-{{#var:output-table-lines}}|1}}{{#vardefine:output3-{{#var:output-table-lines}}|the number of new player names added to blacklist.}}{{#vardefine:command-row-{{#var:commands-num}}|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-edition-row-{{#var:output-editions-num}}|Expression error: Unrecognized punctuation character "{".}}
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}
ban-ip
Adds an IP address to the blacklist. Adds the narrowly-specified address or address of the named online player into the server blacklist, preventing anyone from connecting to the server from that address.
Syntax
ban-ip <target> [<reason>]
Arguments
<targets>: string
- Specifies the IP address to be added to the blacklist. Can also be a name of an online player, which represents the IP of that player.
- {{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|string}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}
<reason>: message
- Message to display to the banned player, to other operators, and in the server logs. If unspecified, defaults to
Banned by an operator. - {{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|message}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}
Result
Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table
Output
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:situation-{{#var:output-table-lines}}|On fail}}{{#vardefine:output1-{{#var:output-table-lines}}|N/A}}{{#vardefine:output2-{{#var:output-table-lines}}|0}}{{#vardefine:output3-{{#var:output-table-lines}}|0}}{{#vardefine:command-row-{{#var:commands-num}}|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-editions-num|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-edition-{{#var:output-editions-num}}|je}}{{#vardefine:output-edition-row-{{#var:output-editions-num}}|1}} {{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:situation-{{#var:output-table-lines}}|On success}}{{#vardefine:output1-{{#var:output-table-lines}}|N/A}}{{#vardefine:output2-{{#var:output-table-lines}}|1}}{{#vardefine:output3-{{#var:output-table-lines}}|the number of online players that connecting with the specified IP}}{{#vardefine:command-row-{{#var:commands-num}}|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-edition-row-{{#var:output-editions-num}}|Expression error: Unrecognized punctuation character "{".}}
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}
banlist
Displays the server's blacklist.
Syntax
banlist [ips|players]
Result
Template:Result table Template:Result table Template:Result table Template:Result table
Output
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:situation-{{#var:output-table-lines}}|On success}}{{#vardefine:output1-{{#var:output-table-lines}}|N/A}}{{#vardefine:output2-{{#var:output-table-lines}}|1}}{{#vardefine:output3-{{#var:output-table-lines}}|the number of entries in the specified list.}}{{#vardefine:command-row-{{#var:commands-num}}|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-editions-num|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-edition-{{#var:output-editions-num}}|je}}{{#vardefine:output-edition-row-{{#var:output-editions-num}}|1}}
{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}
banip
Template:Outdated feature Template:Infobox command
Bans a player by IP number. Cannot be undone in-game;
- REDIRECT Template:Code
Template:Redr must manually be changed.
The Classic equivalent of
- REDIRECT Template:Command
Syntax
banip (<address>|<name>) [<reason>]
History
See also
de:Befehl/ban es:Comandos/ban ja:コマンド/ban pt:Comandos/ban ru:Команды консоли/ban uk:Команди консолі/ban zh:命令/ban