The Sword Duel — First-Person Rapier Fencing, Mouse-as-Blade
First-person rapier duel in a cobblestone European piazza at dusk. Your mouse direction is your blade direction. Watch the opponent's shoulder dip for the tell. Parry, riposte, lunge.
What this is
A first-person rapier duel in a cobblestone European piazza at dusk. Lit by warm hanging lanterns + sunset sky. Stone fountain at center. You hold a rapier visible at the bottom-right of your view. Mouse direction controls the blade tip in space — driven by a critically- damped spring (k=16, c=5) for real inertia. A 22-segment additive ribbon trail follows the blade tip. Left-click thrust (lunge), right-click parry (timed deflection). The opponent — a fencer in period clothing with long coat and plumed hat — telegraphs attacks: shoulder dip for thrust, foot raise for lunge, eye-tracking your blade. Both have stamina that depletes from misses, blocks, and being-blocked. Slow-mo on the killing strike. Three rounds. Match.
Why this is mind-blowing
Sword fighting in games is usually mash-and-swing. This is reading the opponent. The dual-scene viewmodel (sword in its own scene to prevent wall clipping) plus the spring-damped blade plus the telegraphed AI attacks gives you a duel that feels like a duel. The piazza setting is the cinematic frame.
Single-file first-person sword duel in three.js. The viewer holds a
rapier. Mouse direction = blade tip position. Left click thrust, right
click parry. The opponent (a single fencer in period clothing) attacks
with telegraphed motions — watch their shoulder + eyes for the tell.
Stamina-based — depleted = death. Three rounds = match. Cobblestone
European piazza at dusk, lanterns, warm light. Audio: blade clinks,
footwork on stone, breath.
Paste this into Claude, Cursor, or Copilot. Change one thing that matters to you.
What I learned shipping it
- Critically-damped spring (k=16, c=5) on the mouse-driven aim vector gives the blade real weight without lag. Plain damping is sluggish; springs are tactile.
- A 22-segment ribbon trail behind the blade tip with opacity scaling on aim velocity is what makes the sword READ as a sword. Without the trail, it's a stick.
- Telegraphed opponent attacks (shoulder dip = thrust, foot raise = lunge) turn timing-game into a reading-the-opponent game. The whole duel becomes about anticipation, not reflex.