0x3E S3EPacketTeams

Create/update/remove a scoreboard team. Manages team name, prefix/suffix, players, friendly fire, and nametag visibility.

Clientbound (Server → Client) · PLAY · net/minecraft/network/play/server/S3EPacketTeams.java

Published 2026-06-18 · Updated 2026-10-14

scoreboardteam
Comprehensive 7/8

Fields

FieldTypeDescription
nameStringTeam name
displayNameStringTeam display name
prefix/suffixStringName prefix/suffix
friendlyFirebyte0=off, 1=on, 3=seeFriendlyInvisibles
nametagVisibilityStringalways, hideForOtherTeams, hideForOwnTeam, never
colorbyteTeam color for player list
playersString[]Team members
actionbyte0=create, 1=remove, 2=infoUpdate, 3=addPlayers, 4=removePlayers

Wire Encoding

FieldTypeNotes
NameString
Actionbyte0=create, 1=remove, 2=update, 3=add, 4=remove
Per-Action FieldsvariesDepends on action

MCP References

MCPNetHandlerPlayClient.handleTeams()

Handler Interface

HNDINetHandlerPlayClient

Vanilla Source

S3EPacketTeams.java187 lines · MCP 1.8.9Original ↗
1
package net.minecraft.network.play.server;
2
3
import com.google.common.collect.Lists;
4
import java.io.IOException;
5
import java.util.Collection;
6
import net.minecraft.network.Packet;
7
import net.minecraft.network.PacketBuffer;
8
import net.minecraft.network.play.INetHandlerPlayClient;
9
import net.minecraft.scoreboard.ScorePlayerTeam;
10
import net.minecraft.scoreboard.Team;
11
12
public class S3EPacketTeams implements Packet<INetHandlerPlayClient>
13
{
14
    private String name = "";
15
    private String displayName = "";
16
    private String prefix = "";
17
    private String suffix = "";
18
    private String nameTagVisibility;
19
    private int color;
20
    private Collection<String> players;
21
    private int action;
22
    private int friendlyFlags;
23
24
    public S3EPacketTeams()
25
    {
26
        this.nameTagVisibility = Team.EnumVisible.ALWAYS.internalName;
27
        this.color = -1;
28
        this.players = Lists.<String>newArrayList();
29
    }
30
31
    public S3EPacketTeams(ScorePlayerTeam teamIn, int actionIn)
32
    {
33
        this.nameTagVisibility = Team.EnumVisible.ALWAYS.internalName;
34
        this.color = -1;
35
        this.players = Lists.<String>newArrayList();
36
        this.name = teamIn.getRegisteredName();
37
        this.action = actionIn;
38
39
        if (actionIn == 0 || actionIn == 2)
40
        {
41
            this.displayName = teamIn.getTeamName();
42
            this.prefix = teamIn.getColorPrefix();
43
            this.suffix = teamIn.getColorSuffix();
44
            this.friendlyFlags = teamIn.func_98299_i();
45
            this.nameTagVisibility = teamIn.getNameTagVisibility().internalName;
46
            this.color = teamIn.getChatFormat().getColorIndex();
47
        }
48
49
        if (actionIn == 0)
50
        {
51
            this.players.addAll(teamIn.getMembershipCollection());
52
        }
53
    }
54
55
    public S3EPacketTeams(ScorePlayerTeam teamIn, Collection<String> playersIn, int actionIn)
56
    {
57
        this.nameTagVisibility = Team.EnumVisible.ALWAYS.internalName;
58
        this.color = -1;
59
        this.players = Lists.<String>newArrayList();
60
61
        if (actionIn != 3 && actionIn != 4)
62
        {
63
            throw new IllegalArgumentException("Method must be join or leave for player constructor");
64
        }
65
        else if (playersIn != null && !playersIn.isEmpty())
66
        {
67
            this.action = actionIn;
68
            this.name = teamIn.getRegisteredName();
69
            this.players.addAll(playersIn);
70
        }
71
        else
72
        {
73
            throw new IllegalArgumentException("Players cannot be null/empty");
74
        }
75
    }
76
77
    /**
78
     * Reads the raw packet data from the data stream.
79
     */
80
    public void readPacketData(PacketBuffer buf) throws IOException
81
    {
82
        this.name = buf.readStringFromBuffer(16);
83
        this.action = buf.readByte();
84
85
        if (this.action == 0 || this.action == 2)
86
        {
87
            this.displayName = buf.readStringFromBuffer(32);
88
            this.prefix = buf.readStringFromBuffer(16);
89
            this.suffix = buf.readStringFromBuffer(16);
90
            this.friendlyFlags = buf.readByte();
91
            this.nameTagVisibility = buf.readStringFromBuffer(32);
92
            this.color = buf.readByte();
93
        }
94
95
        if (this.action == 0 || this.action == 3 || this.action == 4)
96
        {
97
            int i = buf.readVarIntFromBuffer();
98
99
            for (int j = 0; j < i; ++j)
100
            {
101
                this.players.add(buf.readStringFromBuffer(40));
102
            }
103
        }
104
    }
105
106
    /**
107
     * Writes the raw packet data to the data stream.
108
     */
109
    public void writePacketData(PacketBuffer buf) throws IOException
110
    {
111
        buf.writeString(this.name);
112
        buf.writeByte(this.action);
113
114
        if (this.action == 0 || this.action == 2)
115
        {
116
            buf.writeString(this.displayName);
117
            buf.writeString(this.prefix);
118
            buf.writeString(this.suffix);
119
            buf.writeByte(this.friendlyFlags);
120
            buf.writeString(this.nameTagVisibility);
121
            buf.writeByte(this.color);
122
        }
123
124
        if (this.action == 0 || this.action == 3 || this.action == 4)
125
        {
126
            buf.writeVarIntToBuffer(this.players.size());
127
128
            for (String s : this.players)
129
            {
130
                buf.writeString(s);
131
            }
132
        }
133
    }
134
135
    /**
136
     * Passes this Packet on to the NetHandler for processing.
137
     */
138
    public void processPacket(INetHandlerPlayClient handler)
139
    {
140
        handler.handleTeams(this);
141
    }
142
143
    public String getName()
144
    {
145
        return this.name;
146
    }
147
148
    public String getDisplayName()
149
    {
150
        return this.displayName;
151
    }
152
153
    public String getPrefix()
154
    {
155
        return this.prefix;
156
    }
157
158
    public String getSuffix()
159
    {
160
        return this.suffix;
161
    }
162
163
    public Collection<String> getPlayers()
164
    {
165
        return this.players;
166
    }
167
168
    public int getAction()
169
    {
170
        return this.action;
171
    }
172
173
    public int getFriendlyFlags()
174
    {
175
        return this.friendlyFlags;
176
    }
177
178
    public int getColor()
179
    {
180
        return this.color;
181
    }
182
183
    public String getNameTagVisibility()
184
    {
185
        return this.nameTagVisibility;
186
    }
187
}

Deobfuscated MCP 1.8.9 source of S3EPacketTeams, fetched directly from Marcelektro/MavenMCP-1.8.9 (net/minecraft/network/play/server/S3EPacketTeams.java) at build time and verified present.

Deep Dive

Role in the protocol

Scoreboard team management. The action byte drives five modes: 0 create, 1 remove, 2 update info, 3 add players, 4 remove players. Info fields for actions 0 and 2 are display name (32-char cap), prefix (16), suffix (16), a friendly-fire byte, the nametag visibility string (32), and a color byte indexing EnumChatFormatting. Player lists follow for actions 0, 3, and 4 as a VarInt count of 40-char names. Team color drives the nametag color in the client renderer, which makes this packet the surface for team-colored nametag features.

Vanilla handling

handleTeams creates or fetches the team by registered name, applies the info fields for actions 0 and 2, then adds or removes memberships for actions 3 and 4. The client stores teams in its scoreboard; the nametag renderer reads team color and visibility per player each frame. ServerConfigurationManager replays existing teams to a joining player with action 0.

Why clients touch it

Only Rise 6.x. StaffDetector carries a fully commented-out S3EPacketTeams branch that would scan team members for staff names and trigger an auto-leave (/hub) after six hits; the live module relies on the S38 player-list scan instead. The commented block proves the teams surface was tried and abandoned in favor of S38. Rise also registers the class in the script API. No client colors ESP by team here: nametag coloring is left to vanilla rendering.

Exploit surface

The color byte is server-controlled; a client cannot push team colors back because S3E is clientbound. Nametag-visibility abuse (hiding tags via team properties) is a server-side decision. The interesting angle is staff detection: team rosters leak staff membership on servers that place staff in teams, and the Rise staff list plus a six-hit counter is the pattern. It is entirely client-side reading and undetectable.

Server-Side Handling

ServerScoreboard broadcasts S3E on team create (0), remove (1), info update (2), player add (3), and player remove (4). ServerConfigurationManager sends a create replay to each joining player so the client knows existing teams and their colors before the world settles. All sends go through sendPacketToAllPlayers or the per-player handler.

Protocol Analysis

Wire order: team name (16-char cap), action byte, then for actions 0 and 2 the info block, then for actions 0, 3, and 4 a VarInt count of 40-char member names. The packet constructors throw IllegalArgumentException for player actions with empty member lists, and the read path trusts the action byte to choose which trailing fields exist.

Anti-Cheat Landscape

Not monitored. The team color byte feeds EnumChatFormatting.func_175744_a, so a malformed color renders garbage but cannot crash. StaffDetector's commented branch is the only staff-detection use of teams in the corpus, and it never runs.

implementation Implementation Cases

Team management and nametag color. Rise 6.x StaffDetector contains the only module reference, and it is commented out: the teams scan was replaced by the S38 player-list scan. Everything else is vanilla plus the script API table.

StaffDetector (Rise 6.1.30, Rise 6.2.4)

Detect staff by name and auto-leave. The S3EPacketTeams branch is disabled in the shipped source; the module's active path scans S38PacketPlayerListItem instead.

onPacketReceive contains a commented block that iterates teams.func_149310_g(), checks member names against a hardcoded staff array, increments a counter per hit, and sends /hub via C01PacketChatMessage after six hits. The counter decays each PreMotion tick. The block is dead code in both 6.1.30 and 6.2.4.

Source: Rise 6.1.30, com/alan/clients/module/impl/exploit/StaffDetector.java

Vanilla hook: PacketReceiveEvent (commented branch), PreMotionEvent (active counter decay).
None. The packet branch never executes; the counter is client-side state.
Variations: Rise 6.2.4 ships the identical file under Client-release2/Client/src/main/java.
NetworkAPI (script API) (Rise 6.1.30, Rise 6.2.4)

Expose the packet class to Rise's JavaScript scripting API.

S3EPacketTeams is listed in the clientbound Class array of NetworkAPI.java (line 105).

Source: Rise 6.1.30, com/alan/clients/script/api/NetworkAPI.java

Vanilla hook: None directly.
None. Registry only.
Variations: 6.2.4 ships the byte-identical file with the Client-release2 path prefix.
Rise 6.x: PacketReceiveEvent and PreMotionEvent on StaffDetector; script API table for the class.
Only Rise 6.x references S3E outside vanilla. StaffDetector shows the teams scan replaced by the S38 scan; the script API carries the class for scripts.

anticheat Anti-Cheat Checks

S3E is the one scoreboard packet anticheats actually consume and produce. Grim reads the outbound team stream into per-entity team state that its collision predicates use; intave rewrites the collision rule on outbound team packets and emits team packets to hide fake-player nametags; Shard's monitor emits team packets to render the target name tag and watches for conflicting team traffic. Photon's Teaming is the only flagging check in the domain and it is driven by Bukkit events, not the packet. The rest of the corpus is noise: Rammelkast and AntiCheatPlus match the 'AntiCheat Team' license header on every file, NCP's CollisionUtil reads the Bukkit scoreboard API, and Negativity plus Artemis only register the packet class.

TeamHandler (Grim) (GrimAnticheat-Grim)

Keep a transaction-ordered mirror of the client's team state so entity checks know the collision and push rules between players and entities.

TeamHandler is a PacketSendListener on PacketType.Play.Server.TEAMS. On each S3E it wraps the packet, reads the team name, and schedules a real-time task at the last transaction id so the update applies at the same tick the client processes it. CREATE builds a new EntityTeam, REMOVE drops it, and the other modes update the stored team with the collision rule from the packet. EntityTeam maps members to the team by UUID, and MovementTicker plus EntityPredicates consult it to decide whether an entity can push the player.

Detects: Nothing directly. It feeds collision semantics: team-based collision rules are read consistently because the mirror is transaction-ordered, so push-based exploits cannot desync it.

Source: GrimAnticheat-Grim, common/src/main/java/ac/grim/grimac/utils/team/TeamHandler.java

Variations: CheckManager registers the handler per player (CheckManager.java line 119). No other anticheat mirrors team state for physics; the collision-rule consumers are unique to Grim's simulation.
Teaming (Photon) (Photon-GitHub-AntiCheatAddition)

Flag UHC players who cooperate by clustering, the teaming cheat domain that S3E team membership normally exposes.

Every 5 seconds the check builds a 3D RTree of eligible players (adventure or survival mode, out of combat, outside configured safe zones and WorldGuard no-PVP regions), then clusters players within a configurable proximity range who can see each other. Any cluster larger than the allowed size flags every member with a violation level equal to the surplus. The corpus hit is the team domain: the check never parses S3E and never reads Bukkit team state.

Detects: Players teaming in UHC-style gamemodes: two or more players who move together and avoid PVP.

Source: Photon-GitHub-AntiCheatAddition, src/main/java/de/photon/anticheataddition/modules/checks/teaming/Teaming.java

Variations: None in the corpus. Photon's ModuleManager registers the module, and Placeholders exposes its violation level for alert messages.
EntityCollisionDisabler (intave) (intave-intave)

Patch outbound team packets so the monitored player stops colliding with entities, a server-side no-collision service.

A HIGHEST-priority ProtocolLib subscription on the outbound SCOREBOARD_TEAM packet rewrites the collision-rule string field to 'never' before the packet reaches the client. Version-dependent field indexes handle the 1.13 and 1.17 wire changes, and on 1.17+ the rule is read from the optional internal structure instead of the top-level string list. Active only on 1.9+ servers where the team packet carries a collision rule.

Detects: Nothing cheat-related. It is the anticheat applying a collision exemption through the vanilla team mechanism instead of a per-player flag.

Source: intave-intave, src/main/java/de/jpx3/intave/module/tracker/entity/EntityCollisionDisabler.java

Variations: Same anticheat, opposite direction: ScoreboardAccessor and FakePlayerBody emit S3E team packets to hide the fake-player nametag (see the next check).
ScoreboardAccessor fake-player nametag (intave) (intave-intave)

Hide the nametag of intave's fake-player bait entities so ESP and nametag features cannot distinguish them from real players.

sendScoreboard builds a PacketPlayOutScoreboardTeam with action 3 (ADD_PLAYERS) that places the fake player profile in a dedicated team, then, when hiding is requested, sends a second team packet with action 2 (UPDATE) that sets nameTagVisibility to NEVER. FakePlayerBody invokes it at spawn (FakePlayerBody.java line 318).

Detects: Nothing. The team packets are the bait infrastructure behind the aura and reach checks; the nametag must vanish or the fake entity is trivially spotted.

Source: intave-intave, src/main/java/de/jpx3/intave/player/fake/ScoreboardAccessor.java

Variations: FakePlayerBody.java owns the spawn flow and FakePlayerEventService loads the accessor by class name for the 1.8 pipeline.
Monitor nametag team bridge (Shard) (KaelusAI-Shard)

Render the monitored target's name tag by emitting its own S3E team packets, and keep that rendering valid against other plugins' team traffic.

ViewTeamPacketBridge builds WrapperPlayServerTeams packets (CREATE, UPDATE, ADD_ENTITIES and REMOVE) whose prefix and suffix carry the rendered tag, with the collision rule and nametag visibility forced to ALWAYS so the monitor's tag never interferes with physics. Its companion ViewTeamConflictObserver listens for outbound S3E at MONITOR priority and, when the session renders above the name, marks the target's tag for rebind whenever another plugin creates a team or adds the target to one.

Detects: Nothing. The name-tag rendering is the monitor output channel; the observer exists so a server plugin that manages its own teams does not break the view.

Source: KaelusAI-Shard, src/main/kotlin/ac/shard/monitor/view/ViewTeamPacketBridge.kt

Variations: ScoreboardSlotObserver and ScoreboardPacketBridge cover the sibling scoreboard packets for the sidebar output; ViewTeamConflictObserverTest and TargetTeamStateTest exercise the rebind logic.

Wiki Cross-Reference

The team color byte maps onto formatting codes: 0-15 are the chat colors and 16-21 are obfuscation, bold, strikethrough, underline, italic, and reset.

The friendly-fire field is a bitmask (0x01 allow friendly fire, 0x02 see same-team invisible players), so value 3 means both behaviors are on.

MCP 1.8.9 S3EPacketTeams implements Packet dispatching to INetHandlerPlayClient.handleTeams; wire serde is readPacketData/writePacketData via readByte, readStringFromBuffer, readVarIntFromBuffer.

1.8.9 callers: ServerScoreboard.addPlayerToTeam sends new S3EPacketTeams (line 96) +1 more: https://github.com/Marcelektro/MavenMCP-1.8.9/blob/master/src/main/java/net/minecraft/scoreboard/ServerScoreboard.java

Cross-checked against minecraft.wiki (CC BY-SA 3.0) for 1.8.9 accuracy.

Vanilla Internals

Full 1.8.9 logic-class sources that send or handle this packet, stored verbatim.