fix(eyes): female face placement, smaller Dvergar/Aswid eyes, grey Alfar eyes
The female body maps the painted eyes about 6 mm lower and a quarter closer together than the male one (read from bodymale/bodyfem and the skin UVs), so every race's male-tuned eyes sat on the female brow. PlayerFace moves them for the Dvergar, Aswid, Sverm and Alfar. Dvergar eyes shrink to an 18 mm radius. The Aswid's borrowed sockets are halved before the config multiplier and the smoke is off by default. Alfar eyes become slanted, wrapped black almonds with a wet sheen. They are placed in fixed head-local units: the live lossyScale under the non-uniform Alfar body drifted as the head turned, and the 0.5 s cosmetic pass made the eyes trail the face.
This commit is contained in:
parent
a927a6d4b3
commit
026def2fde
8 changed files with 139 additions and 42 deletions
|
|
@ -126,7 +126,9 @@ namespace RacesOfValheim
|
|||
public static readonly float EyeSeparation = 0.032f; // half the distance between them
|
||||
public static readonly float EyeForward = 0.081f; // centre ~63mm out
|
||||
public static readonly float EyeHeight = 0.181f; // ~15mm lower than before
|
||||
public static readonly float EyeSize = 0.062f; // ~48mm across, so a 24mm radius
|
||||
// Then cut down after playtest: at 0.062 the cap read as two lamps covering the face. An
|
||||
// 18mm radius at the same depth leaves a cap of about 22mm on a 0.78 Dvergar.
|
||||
public static readonly float EyeSize = 0.036f;
|
||||
|
||||
// How hard the eyes burn. The colours the game gives a starred dverger are HDR - one star
|
||||
// is (0, 4, 3.3) - and anything past 1 clips to white on the way to the bloom pass, which
|
||||
|
|
|
|||
|
|
@ -277,10 +277,16 @@ namespace RacesOfValheim
|
|||
// metre was the entire drift: the offsets below are under a centimetre in local units
|
||||
// and never stood a chance of mattering next to it.
|
||||
float raceScale = GetVisualScale(player);
|
||||
Vector3 baseLocal = localForward * (DvergarConfig.EyeForward * raceScale * toLocal)
|
||||
+ localUp * (DvergarConfig.EyeHeight * raceScale * toLocal);
|
||||
|
||||
float eyeLocalSize = DvergarConfig.EyeSize * raceScale * toLocal;
|
||||
float height = DvergarConfig.EyeHeight;
|
||||
float separation = DvergarConfig.EyeSeparation;
|
||||
float eyeSize = DvergarConfig.EyeSize;
|
||||
PlayerFace.AdjustEyes(player, ref height, ref separation, ref eyeSize);
|
||||
|
||||
Vector3 baseLocal = localForward * (DvergarConfig.EyeForward * raceScale * toLocal)
|
||||
+ localUp * (height * raceScale * toLocal);
|
||||
|
||||
float eyeLocalSize = eyeSize * raceScale * toLocal;
|
||||
|
||||
for (int i = 0; i < holder.childCount; i++)
|
||||
{
|
||||
|
|
@ -293,7 +299,7 @@ namespace RacesOfValheim
|
|||
float side = i == 0 ? -1f : 1f;
|
||||
float size = i == 0 ? eyeLocalSize * DvergarConfig.LeftEyeSizeMultiplier : eyeLocalSize;
|
||||
|
||||
eye.localPosition = baseLocal + localRight * (side * DvergarConfig.EyeSeparation * raceScale * toLocal);
|
||||
eye.localPosition = baseLocal + localRight * (side * separation * raceScale * toLocal);
|
||||
eye.localScale = Vector3.one * size;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue