game.player.parts — the procedural banana hero and his floppy banana baton.
Every builder returns plain MeshGeometry (see game.shared.geo). Frames:
* body, face, jacket: the avatar ROOT frame (y up from the ground, +Z is
where the banana faces), so they sit where the rig's hips/spine are.
* shades: relative to P.SHADES_PIVOT (the head centre at eye height).
* sleeve / limb: along +Y from the joint they start at.
* glove: origin at the hand bone, +Y toward the fingers, +X toward the
index/thumb side, +Z the palm.
* sneaker: origin at the ankle bone, +Z toward the toes, ground at -0.075.
* baton: origin at the fist, +Y along the baton, the banana bows toward -Z.
bodyR(y: number) → number
| arg | type | description |
|---|
| y | number | |
u01(y: number) → number
| arg | type | description |
|---|
| y | number | |
bow(y: number) → number
The banana's gentle bow: the belly sits forward of the ends.
| arg | type | description |
|---|
| y | number | |
ridge(th: number, y: number) → number
| arg | type | description |
|---|
| th | number | |
| y | number | |
surface(y: number, th: number, extra: number?) → void
A point on (or `extra` metres off) the body surface. th = pi/2 is the front.
| arg | type | description |
|---|
| y | number | |
| th | number | |
| extra | number? | |
normalAt(th: number) → void
| arg | type | description |
|---|
| th | number | |
thetaFor(x: number, y: number) → number
Angle on the body for a sideways offset x at height y (front half).
| arg | type | description |
|---|
| x | number | |
| y | number | |
at(g: any, pos: { number }, rot: { number }?, scl: { number }?) → any
| arg | type | description |
|---|
| g | any | |
| pos | { number } | |
| rot | { number }? | |
| scl | { number }? | |
gap(y: number) → number
| arg | type | description |
|---|
| y | number | |
jr(y: number, th: number, inner: boolean) → number
| arg | type | description |
|---|
| y | number | |
| th | number | |
| inner | boolean | |
jpoint(y: number, th: number, inner: boolean, extra: number?) → void
| arg | type | description |
|---|
| y | number | |
| th | number | |
| inner | boolean | |
| extra | number? | |
shell(inner: boolean) → void
| arg | type | description |
|---|
| inner | boolean | |
ring(y: number, extra: number, rad: number) → void
| arg | type | description |
|---|
| y | number | |
| extra | number | |
| rad | number | |
sleeve(L: number) → any
| arg | type | description |
|---|
| L | number | |
radial(th: number, t: number) → void
| arg | type | description |
|---|
| th | number | |
| t | number | |
limb(L: number, r0: number, r1: number) → any
| arg | type | description |
|---|
| L | number | |
| r0 | number | |
| r1 | number | |
capsule(from: { number }, to: { number }, r: number) → any
| arg | type | description |
|---|
| from | { number } | |
| to | { number } | |
| r | number | |
glove(mirror: boolean) → any
| arg | type | description |
|---|
| mirror | boolean | |
radial(_th: number, t: number) → void
| arg | type | description |
|---|
| _th | number | |
| t | number | |
batonBody( ) → any
The floppy part: one closed, ridged, curved banana from the neon ring to the
stem tip. Its own frame starts at the ring (y = 0).
radial(th: number, t: number) → void
| arg | type | description |
|---|
| th | number | |
| t | number | |
sori(t: number) → number return
| arg | type | description |
|---|
| t | number | |
facets(loops: { { { number } } }, centers: { { number } }, bucketOf: (number) → void
Faceted surface from closed section loops (each loop k points, same count),
every facet strip flat-shaded and sorted into a bucket by `bucketOf(k)`.
| arg | type | description |
|---|
| loops | { { { number } } } | |
| centers | { { number } } | |
| bucketOf | (number | |
katanaBlade( ) → any
The blade: shinogi-zukuri section (edge, hamon line, ridge, spine), a wavy
hamon splitting the bright edge from the dark steel, the kissaki curving the
edge up to meet the straight spine.
katanaHilt( ) → any
Hilt: ray-skin core under a black criss-cross wrap, chrome pommel, gold
collar and an oval gold guard with a neon rim.
saya( ) → any
The scabbard, from the mouth at the guard to the end cap, following the sori.
band(u: number, len: number, grow: number) → any
| arg | type | description |
|---|
| u | number | |
| len | number | |
| grow | number | |