Developer notes · web game engineering
Client Prediction and Server Authority: Netcode Patterns from Browser Shooters
Masked Special Forces and Bloxd.io solve the same problem — responsive multiplayer in an unreliable network — with different models. This case study compares their choices and the failures each accepts.
T
h
e
f
u
n
d
a
m
e
n
t
a
l
t
r
a
d
e
L
a
t
e
n
c
y
i
s
p
h
y
s
i
c
a
l
:
a
r
o
u
n
d
t
r
i
p
a
c
r
o
s
s
c
o
n
t
i
n
e
n
t
s
t
a
k
e
s
8
0
-
2
0
0
m
s
,
a
n
d
n
o
i
m
p
l
e
m
e
n
t
a
t
i
o
n
r
e
m
o
v
e
s
i
t
.
N
e
t
c
o
d
e
c
h
o
o
s
e
s
w
h
o
f
e
e
l
s
t
h
e
d
e
l
a
y
.
C
l
i
e
n
t
p
r
e
d
i
c
t
i
o
n
(
B
l
o
x
d
'
s
m
o
v
e
m
e
n
t
)
m
a
k
e
s
t
h
e
p
l
a
y
e
r
'
s
o
w
n
a
c
t
i
o
n
s
i
n
s
t
a
n
t
a
n
d
a
c
c
e
p
t
s
v
i
s
i
b
l
e
c
o
r
r
e
c
t
i
o
n
s
f
o
r
o
t
h
e
r
s
.
S
e
r
v
e
r
a
u
t
h
o
r
i
t
y
(
M
a
s
k
e
d
S
p
e
c
i
a
l
F
o
r
c
e
s
'
h
i
t
r
e
g
i
s
t
r
a
t
i
o
n
)
m
a
k
e
s
o
u
t
c
o
m
e
s
f
a
i
r
a
n
d
a
c
c
e
p
t
s
i
n
p
u
t
d
e
l
a
y
o
n
c
o
n
f
i
r
m
a
t
i
o
n
.
E
v
e
r
y
m
u
l
t
i
p
l
a
y
e
r
i
m
p
l
e
m
e
n
t
a
t
i
o
n
a
l
l
o
c
a
t
e
s
b
e
t
w
e
e
n
t
h
e
s
e
t
w
o
,
p
e
r
i
n
t
e
r
a
c
t
i
o
n
t
y
p
e
.
Pattern: predict-own, reconcile-others
Movement is the case for prediction: the player's own position simulates locally and reconciles against server snapshots, so the world feels attached to your input. Remote players interpolate between snapshots — never predicted — because predicting someone you cannot correct produces visible artifacts. Bloxd follows this split exactly, which is why your building feels instant while other players sometimes pop.
Pattern: rewind for hit registration
Shooters invert the priority: fairness over feel. Masked Special Forces rewinds the world to the shooter's timestamp for hit checks, so what you saw when firing is what the server judges. The cost is peeker's advantage — the defender's cover is thinner on your screen than on theirs. The implementation's choice not to expand the rewind window keeps that advantage small at the cost of occasional refused hits at high latency. Honest trade, correctly documented in the review.
Pattern: delta and chunk streaming
Both games stream world state as deltas: Bloxd chunks voxel edits (RLE-compressed, only dirty chunks), the shooter streams player transforms at 20Hz with interpolation. The shared principle — send what changed, interpolate the rest — is what keeps browser multiplayer playable on ordinary connections. Full-state sync is the bug a reviewer finds; delta sync is the fix.
The browser's actual constraints
WebRTC data channels (unreliable/unordered) are the transport browsers offer for game traffic; WebSocket (reliable/ordered) is the fallback. Head-of-line blocking on WebSocket is why fast-paced browser shooters schedule their own reliability on top of unreliable channels where possible. The catalog's titles run WebSocket — visible in their graceful handling of packet loss, and visible in their ceiling during packet bursts. The next netcode generation in browser games moves to WebTransport.
All developer notes · Review portal · About the engineering desk