gouramesh
Tawpy's geometry, written as numbers. Every part of the Victoria crowned pigeon is generated here from the four builders in `game.hero.pgmesh` — a lens for the volumes, a lathe for the bill and the eyes, a ribbon for the crest plumes and the tail feathers — and handed back as fla…
gouramesh
Tawpy's geometry, written as numbers. Every part of the Victoria crowned pigeon
is generated here from the four builders in game.hero.pgmesh — a lens for the
volumes, a lathe for the bill and the eyes, a ribbon for the crest plumes and
the tail feathers — and handed back as flat-array Geom tables, the shape
renderer.mesh.create takes.
Nothing here touches engine state, spawns anything or draws anything. It is
arithmetic. game.hero.gouraart uploads what it returns, paints the plumage
against these UVs and hangs the parts on an entity.
The bird
She is a heavy ground bird: a deep body on short thick legs, a small head
carried close on a short neck, a long fanned tail, and the lace crest standing
over all of it. Feet at y = 0, facing her local -Z (the lane runs that way),
symmetric about X. She stands 1.00 to the crest tips and measures 1.38 from bill
tip to tail tip.
Exports
M.goura() -> { [string]: Geom }— every mesh she is made of:body,breast,neck,head,bill,eye,pupil,plume,wingR,wingL,rectrix,shank,foot. Costs a few milliseconds;gouraartcalls it once a session.M.ANCHOR— where each pivot hangs in its parent.gouraartbuilds the entity tree from it, so the geometry and the joints cannot drift apart.M.CROWN_HEIGHT— the height the anchors are written at, so a rig at another size scales bycrownHeight / CROWN_HEIGHT.M.CREST(count,spread,rake) withM.plumeAngles(i, count, flare)andM.plumeLength(i, count)— where each crest plume sits in the fan and how long it is.flareopens and closes the whole fan, which is what the boom and the startle drive.M.TAIL(count,spread,droop) withM.tailAngles(i, count, fan)andM.tailLength(i, count)— the same for the rectrices.fanopens the tail.M.bodyHalfZ(y),M.bodyHalfX(y),M.bodyOffsetZ(y)— the body's ellipse at a height, which is how the breast patch finds the surface it sits a hair outside of.
Notes
- The two wings are separate geometry rather than one mesh used twice: each draws its tip in toward her flank as the body tapers, so a folded wing finishes inside her silhouette instead of standing off it as a flap. Mirroring one mesh with a negative scale would turn its triangles inside out.
- The lathe's open arc faces
+Z, so the breast patch is built there and the rig yaws it half a turn onto her front. - The bill is built up its own
+Yand stood forward by a quarter turn on the rig, so a positivezoffon a bill ring is the culmen bending DOWN. - A swept part is roughened for feather texture, but never on the rows where its cross-section has closed to a point: those vertices sit on top of one another and displacing them turns the triangles between them inside out.
Scoped to this part · feeds back into the world's score.