Log inGet started
World

Lanternwake

Branchmain
Branchesmain
Commitdc8f400ee9

README.md

game.vicar — the Hollow Vicar

The thing that walks the lanes of Lanternwake. One model, generated entirely in Luau: a tall, wrong clergyman with no feet, whose hem pools in the fen water and drags behind it, and who carries a cold blue-green light where a face should be.

What it puts in the scene

An entity named HollowVicar under the Vicar container. That name is the contract with the hunt slice, which drives its position and rotation. Everything below the root belongs to this module:

HollowVicar                 ← hunt moves this, and only this
└ VicarBody                 ← breath, lean, sway, the constant half-turn
  ├ VicarCassock            the skirt, hem to throat
  ├ VicarMozzetta           the shoulder cape, a shell with a scalloped edge
  ├ VicarTatters            strips of rotted hem floating behind it
  ├ VicarClasp              the only metal on the figure
  ├ VicarHead               turns toward you when it is hunting
  │ ├ VicarHood             a shell with a 26 mm wall and a black interior
  │ ├ VicarFace             the glow
  │ └ VicarFaceLight        the point light the fog needs it to carry
  └ VicarArm{L,R}           ├ VicarFore{L,R} ├ VicarHand{L,R}

Roughly 32,000 triangles across twelve runtime meshes, built once and cached.

How it animates

Nothing here decides where the Vicar is. update(dt) reads the root's motion back and animates the body around it, so the hunt slice only has to say where the thing stands:

what it is doingwhat you see
standinga slow swell through the shoulders, the head drifting
walkinga glide with a lateral roll — no footfall bob, it has no feet
stalking (vicarState == "chase")faster, pitched forward, arms thrown wider, the facelight up
noticing you (vicarSpotted)the head snaps round and the facelight flares hard

It reads Core.state.vicarState and listens for vicarSpotted and playerCaught. It emits nothing.

The materials

vicar_cassock, vicar_mozzetta and vicar_hood are three settings of one shader, vicar_wool — sodden Victorian serge with a diagonal twill, a capillary waterline, fen silt, mildew in the folds and a fibre sheen. It reads three channels baked into every vertex: .r height, .g ambient occlusion, .b fold depth. That is why one shader dresses a hood, a sleeve and a pooled hem at the right wetness without a per-part parameter set.

vicar_glowface is vicar_glow, a self-shading emissive. vicar_clasp and vicar_hand are pbr.

Debug handles

require("game.vicar").report()      -- root, position, triangles, speed, flare
require("game.vicar").flare(1.6)    -- make it notice you
require("game.vicar").invalidate()  -- drop the cached meshes, then build() again