0x03 S03PacketTimeUpdate

Synchronizes the world time (total world age and day/night cycle time). Sent every few seconds or when time accelerates (sleeping).

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

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

worldtime
Comprehensive 8/8

Fields

FieldTypeDescription
totalWorldTimelongTotal ticks since world creation (monotonically increasing)
worldTimelongCurrent day/night time (0-24000). worldTime % 24000 for time-of-day.

Wire Encoding

FieldTypeNotes
World AgelongIncremented each tick
Time of Daylong0-24000, wraps around

MCP References

MCPNetHandlerPlayClient.handleTimeUpdate()

Handler Interface

HNDINetHandlerPlayClient

Notes

Time values: 0=dawn, 6000=noon, 12000=sunset, 18000=midnight. When all players sleep, time jumps to 0 (dawn). S03 is used by modules to calculate server TPS (ticks per second) by measuring the time between S03 updates.

Vanilla Source

S03PacketTimeUpdate.java68 lines · MCP 1.8.9Original ↗
1
package net.minecraft.network.play.server;
2
3
import java.io.IOException;
4
import net.minecraft.network.Packet;
5
import net.minecraft.network.PacketBuffer;
6
import net.minecraft.network.play.INetHandlerPlayClient;
7
8
public class S03PacketTimeUpdate implements Packet<INetHandlerPlayClient>
9
{
10
    private long totalWorldTime;
11
    private long worldTime;
12
13
    public S03PacketTimeUpdate()
14
    {
15
    }
16
17
    public S03PacketTimeUpdate(long totalWorldTimeIn, long totalTimeIn, boolean doDayLightCycle)
18
    {
19
        this.totalWorldTime = totalWorldTimeIn;
20
        this.worldTime = totalTimeIn;
21
22
        if (!doDayLightCycle)
23
        {
24
            this.worldTime = -this.worldTime;
25
26
            if (this.worldTime == 0L)
27
            {
28
                this.worldTime = -1L;
29
            }
30
        }
31
    }
32
33
    /**
34
     * Reads the raw packet data from the data stream.
35
     */
36
    public void readPacketData(PacketBuffer buf) throws IOException
37
    {
38
        this.totalWorldTime = buf.readLong();
39
        this.worldTime = buf.readLong();
40
    }
41
42
    /**
43
     * Writes the raw packet data to the data stream.
44
     */
45
    public void writePacketData(PacketBuffer buf) throws IOException
46
    {
47
        buf.writeLong(this.totalWorldTime);
48
        buf.writeLong(this.worldTime);
49
    }
50
51
    /**
52
     * Passes this Packet on to the NetHandler for processing.
53
     */
54
    public void processPacket(INetHandlerPlayClient handler)
55
    {
56
        handler.handleTimeUpdate(this);
57
    }
58
59
    public long getTotalWorldTime()
60
    {
61
        return this.totalWorldTime;
62
    }
63
64
    public long getWorldTime()
65
    {
66
        return this.worldTime;
67
    }
68
}

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

Deep Dive

Role in the protocol

Two longs, totalWorldTime and worldTime, broadcast by MinecraftServer to every player in a dimension once per second (tickCounter % 20 == 0, line ~701 in the MCP builds) and re-sent on player join by ServerConfigurationManager (line ~787). worldTime is the day/night counter the client renders modulo 24000: 0 dawn, 6000 noon, 12000 sunset, 18000 midnight. The constructor folds the doDaylightCycle gamerule into the wire format by negation: when the rule is off the server transmits -worldTime, so the sign bit is the freeze flag and the boolean never exists as a packet field.

Vanilla handling

NetHandlerPlayClient.handleTimeUpdate runs on the main thread via PacketThreadUtil and performs two writes: theWorld.setTotalWorldTime(packet.func_149366_c()) and theWorld.setWorldTime(packet.func_149365_d()). Between corrections the client advances time-of-day itself in its tick loop, so the packet is a periodic correction, not the clock source. That is the property the Ambiance family exploits: cancel the correction and the locally pinned time holds until the next one would have arrived.

Why clients touch it

The Ambiance family spans Memeware 7.3, Rise 5.99, Rise 6.1.30, Rise 6.2.4 and LiquidSense Dev (the AquaVit fork), and Tenacity 6.0 ships the same idea as AlwaysNight. All six cancel S03 on the receive event and overwrite world time on a per-frame hook: Memeware writes 0 or 20000 depending on a Morning/Night mode, Rise 5.99 writes time + elapsed * timeSpeed, Rise 6.x adds weather forcing, LiquidSense Dev offers Daytime/Night/DIY/DayWithNight with a cycling counter, Tenacity writes a configurable value defaulting to 12000. Notably absent is Fullbright: it is a gamma/lighting override that never touches this packet, and no TPS estimator in the corpus derives server lag from S03 deltas even though the two longs are a natural clock.

Exploit surface

Cosmetic only and invisible to the server, because the client never reports displayed time back. Observers see the desync side effects: a pinned clock shows a frozen sky on the client's own screen, and when all players sleep and the server jumps time to 0 the module visibly fights the correction. No anti-cheat measures this packet. The only hazard is a module that writes worldTime unclamped, which can push the negative freeze encoding into the local renderer and break the sky shader path.

Server-Side Handling

MinecraftServer broadcasts S03PacketTimeUpdate(totalWorldTime, worldTime, doDaylightCycle) to all players in the dimension every 20 ticks (line ~701), and ServerConfigurationManager sends a fresh copy on player join (line ~787). When doDaylightCycle is false the server negates worldTime before sending; the constructor also maps a negated 0 to -1 so the freeze flag survives the zero case. The server never validates or rates the packet stream because it is the sole author.

Protocol Analysis

Two raw longs on the wire; the third constructor argument (doDaylightCycle) is encoded by negation, so worldTime < 0 means the day/night cycle is frozen server-side and the client should display abs(worldTime) without local advancement. Clients that only read the longs (all 5 module implementations here) are unaffected by the sign trick. The packet is sent in the PLAY state and is dimension-scoped, so it stops at the dimension boundary and a fresh one arrives on respawn.

Anti-Cheat Landscape

No anti-cheat flags time manipulation: the client clock is cosmetic, server-authoritative only in the sense that the server periodically corrects it, and nothing gameplay-relevant derives from it. The modules are undetectable from the wire because cancellation happens before the packet reaches the vanilla handler and no corresponding serverbound traffic exists.

implementation Implementation Cases

Once-per-second world-clock correction (two longs, doDaylightCycle encoded as a sign bit). Six modules across the 10 clients cancel it and pin the client clock locally, all with the same two-step shape: cancel on receive, rewrite on frame. Pure client-side cosmetics with zero server visibility.

Ambiance / Ambience (Memeware 7.3, Rise 5.99, Rise 6.1.30, Rise 6.2.4)

Pin the client's day/night clock to a fixed value by cancelling server time corrections.

A receive-side packet event cancels every S03PacketTimeUpdate, then a per-frame hook rewrites the world clock: Memeware 7.3 sets 0 (Morning) or 20000 (Night) on UpdateEvent; Rise 5.99 computes time + elapsedMillis * timeSpeed on Render3D; Rise 6.x does the same and additionally forces weather by cancelling S2BPacketChangeGameState states 1 and 2. The cancel prevents the server value from ever landing, so the local write is the only clock.

Source: Memeware 7.3, me/memewaredevs/client/module/render/Ambiance.java

Vanilla hook: PacketInEvent (cancel); UpdateEvent (rewrite).
No detection surface: the packet is receive-only, the server never learns the client's displayed time, and the cancelled packets are invisible on the wire. The only tell is a frozen or wrong sky on the client's own screen.
Variations: Rise 5.99 cancels on PacketReceiveEvent and writes time + elapsed * timeSpeed on Render3DEvent. Rise 6.1.30 and 6.2.4 (renamed Ambience) add a weather mode that also cancels S2BPacketChangeGameState rain/thunder states, a snow color override and a temperature hook for particle rendering. Rise 6.x additionally whitelists S03 in the script API (com/alan/clients/script/api/NetworkAPI.java) so JS scripts can observe it.
AlwaysNight (Tenacity 6.0)

Hold the client's world time at a configurable value (default 12000, midnight) by cancelling server time updates.

A PacketReceiveEvent handler cancels S03PacketTimeUpdate; onEnable and a render-tick listener write the configured value into the world, and onDisable restores time 0. The number setting accepts any value in 0..24000 in 1000-step increments, so the module is a general time pin despite the AlwaysNight name.

Source: Tenacity 6.0, dev/tenacity/module/impl/world/AlwaysNight.java

Vanilla hook: PacketReceiveEvent (cancel); render tick (rewrite).
Identical to the Ambiance family: receive-side cancellation is unobservable by the server, and no gameplay state depends on the client clock.
Variations: Tenacity is the only one of the 8 clients that ships this as a World-category module with a user-configurable value; the other four hardcode or speed-adjust the time in the render category.
Ambience (LiquidSense Dev) (LiquidSense Dev)

Pin the client's day/night clock by cancelling every S03PacketTimeUpdate, with four time modes, in the AquaVit LiquidSense fork (LiquidBounce base).

onPacket cancels any PacketEvent whose packet is an S03PacketTimeUpdate. onUpdate advances a private counter a by the DayWithNight step on an MSTimer and rewrites the world clock per mode: Daytime 1000, Night 16000, DIY the configured value (default 13000), DayWithNight the cycled counter wrapped at 24000.

Source: LiquidSense Dev, me/AquaVit/liquidSense/modules/render/Ambience.java

Vanilla hook: PacketEvent (receive, @EventTarget) to cancel; UpdateEvent to rewrite.
Identical to the Ambiance family: receive-side cancellation is unobservable by the server and no gameplay state depends on the client clock, so there is no flag surface.
Variations: The AquaVit fork is the LiquidSense Dev representative; the CCBlueX LiquidBounce Dev tree itself has no S03 module hit in the corpus. Memeware/Rise pin two hardcoded values, Tenacity's AlwaysNight is configurable with no cycle, and this fork adds a DayWithNight cycling mode driven by an MSTimer.
PacketReceiveEvent (PacketInEvent on Memeware, PacketEvent on LiquidSense Dev) to cancel, plus a per-frame hook (UpdateEvent, Render3DEvent or render tick) to rewrite world time.
Memeware uses the lwjeb-style PacketInEvent with event.cancel(); Rise 5.99 and 6.x use PacketReceiveEvent with setCancelled and write on Render3D; Tenacity uses its IEventListener and cancels via event.cancel(). All six share the same two-step shape: cancel the correction, then own the clock. LiquidSense Dev (AquaVit fork) cancels via @EventTarget PacketEvent and rewrites on UpdateEvent driven by an MSTimer, adding the only cycling (DayWithNight) mode in the corpus.

anticheat Anti-Cheat Checks

The time update packet is a server-authoritative clock correction: two longs broadcast once per second, with the doDaylightCycle gamerule folded into the sign of worldTime. Server-side anticheats never reference it. The corpus sweep for the packet names S03PacketTimeUpdate and PacketPlayOutTimeUpdate returns zero hits, and the keyword pass over 'Time' only surfaces timer utilities, TimeUtil classes and tick-delta heuristics, none of which read this packet. The client never reports its displayed time back, so the cancel-and-pin time modules are invisible on the wire and no check in any cloned anticheat targets them.

Wiki Cross-Reference

Time runs at 20 ticks per second with 24000 ticks per day, and time of day is the world time modulo 24000.

The default server increments world time by 20 every second.

MCP 1.8.9 S03PacketTimeUpdate implements Packet dispatching to INetHandlerPlayClient.handleTimeUpdate; wire serde is readPacketData/writePacketData via readLong.

1.8.9 callers: MinecraftServer.updateTimeLightAndEntities sends new S03PacketTimeUpdate (line 762) +1 more: https://github.com/Marcelektro/MavenMCP-1.8.9/blob/master/src/main/java/net/minecraft/server/MinecraftServer.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.

Module Analyses Using S03PacketTimeUpdate

Full source walkthroughs of the modules and anti-cheats that use this packet.