Natural gene / phase 1 + overlay

The leopard complex (appaloosa)

Real-horse TRPM1 (LP) plus two modifier loci, PATN1 and PATN2, and the only gene in the model that reads other loci to decide what it paints. LP alone gives the appaloosa characteristics — roaning that spares the bony parts, a scatter of white spots, striped hooves, a white-rimmed eye. The bold patterns — leopard, fewspot, spotted blanket, snowcap — come from the modifiers, which mean nothing on a horse with no LP.

What it does

What to look for: appaloosa markings — white roaning that spares the bony parts of the face and legs, a scatter of spots, striped hooves, and a white rim around the eye.

This one needs three genes, not one. On its own it gives you the speckled "varnish roan" look. The bold patterns people actually want — leopard, fewspot, spotted blanket, snowcap — only appear when the horse also carries the pattern modifiers, and those modifiers do nothing whatsoever on a horse without this gene. Breeding for the flashy patterns means breeding for all of it at once.

Crossing two of them

Health: LP/LP → CSNB (night blindness), informational — costs nothing

Its gene carrot

Gene keys
horsegenetics.leopard, horsegenetics.patn1, horsegenetics.patn2
Alleles
LP lp  ·  PATN1 n  ·  PATN2 n
Outcomes (LP)
wild, mottled, varnish-roan, leopard, fewspot, blanket, snowcap, semi-leopard
Outcomes (PATN1/PATN2)
wild only — pure modifiers, they never paint
Priority
leopard 73 (white band), PATN1 93, PATN2 94 (paints-nothing band)
Default alleles
lp, n, n
Wild frequency
LP ~1 in 40 per allele; PATN only drawn onto an LP founder
Deterministic
no — every visible LP outcome varies per horse
Epi draws
off the expressing LP copy: nextLong() seed + 2–3 nextFloat() jitters per painter
Health
LP/LP → CSNB (night blindness), informational — costs nothing
Reads
coatDependsOn() = [patn1, patn2]

The outcome grid

The visible pattern is a function of this locus's zygosity and the two modifier pairs. expressionOf(pair) — which only sees the LP pair — can only give a coarse answer (varnish-roan for any LP horse, which keeps the gallery to two leopard-complex pens). The pipeline calls expressionIn(pair, genotype), which reads PATN1 and PATN2 and returns the real one of eight:

LPno PATN+ PATN1+ PATN2+ both
LP/lpmottledleopardblanketsemi-leopard
LP/LPvarnish-roanfewspotsnowcapsemi-leopard
lp/lpwild type — a solid coat, whatever PATN says
  • mottled — light, uneven roaning that keeps its colour over the bones, a few small white spots, plus the always-on triad. The appaloosa “look” without a bold pattern.
  • varnish-roan — heavy, uneven whitening that reaches the head and leaves darker varnish marks over the horse’s bony prominences, so it ends up outlined by its own anatomy. Not true roan, and not a stronger version of it.
  • leopard — a white body carrying round dark spots of the base colour, head to hoof.
  • fewspot — almost solid white, a handful of spots left.
  • blanket — a solid white sheet over the hips with dark spots inside it; the rest of the horse its ordinary colour, legs coloured.
  • snowcap — the same blanket with no spots.
  • semi-leopard — a spotted blanket that reaches forward over the barrel, between blanket and full leopard.

The painters

All phase 1, like the other white genes — they only ever push pigment toward zero, so the bald white template shows through. Every number comes from the expressing LP copy's stored values, so a foal that inherits the copy reproduces the exact pattern.

All four go through one private whiten(f, px, py, amount), which is PigmentField.whiten and nothing else. That matters most for paintVarnish, which is all partial whitening: on a black-based appaloosa the old per-gene approximation left a side view carrying 211 warm texels — the varnish reading tan rather than grey — against the 64 a plain black horse gets from the template's own shading. It is 59 now.

outcomepaintershape
leopard, fewspotpaintSpottedthe whole horse white; round base-colour spots punched back in from a BodyNoise.cellDistance (Worley) field — a spot where the distance to the nearest jittered cell centre is under a radius. Fewspot uses a wider spacing and a smaller radius.
blanket, snowcap, semi-leopardpaintBlanketwhite from the rump forward to a coverage fraction of the BODY X-span, the front edge wobbled with value noise; spots inside via the same Worley field (snowcap sets density to zero). A large blanket creeps onto the top of the hind legs.
mottled, varnish-roanpaintVarnisha coarse white mix from a two-octave fractal — deliberately far patchier than classic roan’s near-per-texel mix — at near-full strength over the barrel, neck, head and legs, with pigment retained over the bony prominences and nothing on the mane / tail / ears. Slightly asymmetric (LP varnish is). Mottled also drops a few crisp white snowflake spots.

Varnish marks — the horse outlined by its own skeleton

Rebuilt 2026-09-06 against the reference, NOT yet looked at

Varnish roan used to be drawn as classic roan with a different weighting: the same noise frequency, a front-to-back gradient, and a flat half-strength over the head. That made it a weaker roan, when the whole point is that the two look fundamentally different. It now has the trait it is actually recognised by.

A varnish horse whitens around its bones without erasing them. Pigment persists over the cheekbones, shoulder blades, elbows, hips, stifles and knees, and those residual darker zones are what the pattern is named for. So paintVarnish subtracts a retention field before it roans anything:

MarkWhere it is derived fromShape
Shoulder blade, point of hipThe BODY box, one per sideWide and shallow — a shield, dark at the core and fading out
Elbow / stifle, knee / hockEach leg’s own box, at its top and part-way downSmall and deep, so the joint reads as outlined
CheekboneThe HEAD box, one per sideSmall and deep

Every mark is derived from the mesh’s own part boxes rather than written down as coordinates, so a mesh change moves them with it. The strongest mark wins rather than the sum — two overlapping marks must not add up to a solid patch — and the distance is wobbled by a noise field so the island’s outline is ragged. A real varnish mark follows the bone loosely, not exactly. How deeply the marks hold is rolled per horse, because “varnishing out” is a process and different horses are at different points along it.

Against classic roan

RoanPatternsTest pins the comparison through the real pipeline, and it is the reference’s own identification checklist:

Varnish roanClassic roan
HeadWhitens, keeping colour over facial boneDark — the mask is diagnostic
Shoulder / hipDark shields; measured 0.36–0.54 luma darker than the barrel around themNo shield at all — measured within 0.06
DistributionIrregular pale areas; measurably patchierEven salt-and-pepper
LegsColour kept over the joints themselvesDark below an inverted-V boundary

“White finds white” is not applied here yet — leopard composes with the other white loci at priority 73 (early), so a leopard horse that is also sabino simply gets sabino white added on top. Multi-pattern appaloosas want an in-game look; flagged in verification.

The always-on triad

Every LP horse — any non-wild outcome — also gets, in the overlay phase (so the eye redraw cannot wipe them):

  • Striped hooves — vertical light/dark bands over the bottom HOOF_FRACTION of each leg, from a body-space phase; the light bands blend toward a pale horn colour.
  • A white-rimmed eyeshadeEyes toward a cool near-white. Because the shade is luma-scaled, the bright sclera lifts while the dark pupil stays dark.

Mottled skin — the third member of the triad — is not drawn; the coat has no skin layer, only hair. Flagged in the roadmap.

CSNB

Every LP/LP horse has congenital stationary night blindness — the same TRPM1 change that makes the pattern also stops the retina resetting in the dark. The mod has no night vision for a horse to lose, so like deafness on a splash homozygote it is informational: shown on the info panel and the paper dump, costing the horse nothing. One copy carries the pattern with none of the defect, which is why the pairing worth breeding for is also the one that hides it.

In the wild, and in breeds

LP founders are ~1 in 40 per allele — a bit under 5% carriers, well under 1% LP/LP — and a wild founder only draws a variant PATN copy if it already rolled LP at LeopardGene (which sorts earlier, so the founder context has it). So a wild spotted appaloosa is a genuine find; the pattern is common once you breed for it.

Appaloosa, Knabstrupper, Kiger Mustang, Mustang and Shetland Pony roll real LP + PATN pools — the Appaloosa and Knabstrupper heavily, so most of a herd shows a pattern; the mustangs and the Shetland lightly.

First-guess constants

Spot size and spacing, blanket coverage, roaning strength, the hoof-stripe frequency and the eye-rim tint are all eyeballed off sample bakes. Whether a blanket sits on the hindquarters at the right height, whether the spots read as spots on a 3D horse, and whether the hoof stripes are visible are the open in-game questions — verification §0.

Why the modifiers are separate genes

LP is one locus (TRPM1). PATN1 and PATN2 are real, independently inherited modifier loci, so they have to be separate genes — a breeder works toward “this line carries PATN1” the same way they work toward any other allele. They just have no phenotype of their own: a PATN1 carrier with no LP looks like any other horse.

That creates a texture-cache problem. A gene is left out of a horse's coat code unless affectsCoat() is true, and every one of PATN's own combinations is a wild type — so a LP/LP PATN1/PATN1 horse and a plain LP/LP one would collide in the cache and render identically. The fix is a new hook, Gene.coatDependsOn(): LeopardGene names both modifiers, and Genotype.coatCode() folds their alleles into the texture key — but only for a horse that actually carries LP, so a PATN carrier with no leopard complex still shares its texture. BreedFounder likewise treats a named modifier like a coat gene (forced wild unless the breed lists it).

Not a pattern for third-party genes

Cross-locus reads make a gene hard to reason about, hard to show in a punnett square and hard to breed toward. The built-in leopard complex earns the exception because it is a real, famous pattern that genuinely works this way. See the roadmap’s settled decisions.

Source: common/genetics/genes/LeopardGene.java, Patn1Gene.java, Patn2Gene.java, AppaloosaModifierGene.java