Merge branch 'fix-furling-remote-scale': other players see a Furling at Furling size

This commit is contained in:
kanym 2026-10-23 19:07:14 +02:00
commit 557664c41f

View file

@ -11,9 +11,13 @@ namespace RacesOfValheim
{
public static void Postfix(Player __instance)
{
if (__instance == null || __instance != Player.m_localPlayer) return;
if (FurlingRace.IsFurling())
if (__instance == null) return;
// Every player, not only the local one, with the race read off the ZDO. Scale is not
// replicated: each client sizes the characters it draws. When this sized only the
// local player from its own m_customData, a Furling was small on their own screen
// and full height on everybody else's.
if (DvergarVisuals.GetPlayerRace(__instance) == "Furling")
{
// Scale player visuals down by 19% (0.9 * 0.9 = 0.81)
GameObject visual = Traverse.Create(__instance).Field("m_visual").GetValue<GameObject>();