Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Minecraft:Commands/ban: Difference between revisions

From SAS Gaming Wiki
SyncBot (talk | contribs)
Remove broken links to missing pages
SyncBot (talk | contribs)
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 ===
{{argument|targets|game_profile}}
{{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.
: {{arg desc|je=game_profile}}
: {{MC/Arg desc|je=game_profile}}


{{argument|reason|message}}
{{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>
: {{arg desc|je=message}}
: {{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 ===
{{argument|targets|string}}
{{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.
: {{arg desc|je=string|type=word}}
: {{MC/Arg desc|je=string|type=word}}


{{argument|reason|message}}
{{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>
: {{arg desc|je=message}}
: {{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; {{cd|banned-ip.txt}} must manually be changed.
Bans a player by IP number. Cannot be undone in-game; {{MC/Cd|banned-ip.txt}} must manually be changed.


The Classic equivalent of {{cmd|ban-ip}}.
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 {{cmd|ban|link=none}} and {{cmd|banip|link=none}}.}}
|{{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|{{cmd|banip|link=none}} has been renamed to {{cmd|ban-ip|link=none}}.
|{{HistoryLine||v1.0.16|{{MC/Cmd|banip|link=none}} has been renamed to {{MC/Cmd|ban-ip|link=none}}.
|{{cmd|ban|link=none}} and {{cmd|ban-ip|link=none}} are now usable again.
|{{MC/Cmd|ban|link=none}} and {{MC/Cmd|ban-ip|link=none}} are now usable again.
|Added {{cmd|banlist|link=none}}.}}
|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

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

Template:Infobox command

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

Template:Infobox command

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

Template:Infobox command

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;

  1. REDIRECT Template:Code

Template:Redr must manually be changed.

The Classic equivalent of

  1. REDIRECT Template:Command

Template:Redr.

Syntax

banip (<address>|<name>) [<reason>]

History

Template:HistoryTable

See also

Navigation

All editions
Removed
Template:El only
Debug
Removed
Template:Els only
Template:El only
Removed
Template:El only
Removed
Template:Els only
Removed
Joke
Related

de:Befehl/ban es:Comandos/ban ja:コマンド/ban pt:Comandos/ban ru:Команды консоли/ban uk:Команди консолі/ban zh:命令/ban