chore(release): v1.5.10 - Skeleton body switch for player model mods
New client-side option Skeleton - Visuals -> Body Model Enabled. Off, a Skeleton takes the human branch of the VisEquipment postfix: vanilla body on, no bone meshes, eye glow, jaw correction or skull flame, and the helmet is left alone. Requested by players using EnhancedValheimVRM, where the bones floated around the replacement model. README: New in block for v1.5.10, changelog entry (also the Russian fixes since 1.5.9), and a line under the Skeleton features.
This commit is contained in:
parent
aca3eabb2f
commit
bb1ca57924
10 changed files with 43 additions and 15 deletions
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "RacesOfValheim",
|
||||
"description": "A Valheim mod that adds ten custom playable races (Aswid, Draugh, Dvergar, Fenrir, Furling, Skadi, Skeleton, Sverm, Trenta, Trol) each with unique abilities, traits, race stations and a deep boss-driven progression system.",
|
||||
"version_number": "1.5.9",
|
||||
"version_number": "1.5.10",
|
||||
"website_url": "",
|
||||
"dependencies": [
|
||||
"denikson-BepInExPack_Valheim-5.4.2333",
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ namespace RacesOfValheim
|
|||
{
|
||||
public const string PluginGUID = "com.nandor.racesofvalheim";
|
||||
public const string PluginName = "Races Of Valheim";
|
||||
public const string PluginVersion = "1.5.9";
|
||||
public const string PluginVersion = "1.5.10";
|
||||
|
||||
private readonly Harmony harmony = new Harmony(PluginGUID);
|
||||
|
||||
|
|
|
|||
|
|
@ -41,6 +41,7 @@ namespace RacesOfValheim
|
|||
|
||||
// ─── Visuals ───────────────────────────────────────────────────────────
|
||||
public static ConfigEntry<bool> HeadFireVFXEnabled;
|
||||
public static ConfigEntry<bool> BodyModelEnabled;
|
||||
|
||||
public static void Bind(ConfigFile config)
|
||||
{
|
||||
|
|
@ -71,6 +72,8 @@ namespace RacesOfValheim
|
|||
const string visuals = "Skeleton - Visuals";
|
||||
HeadFireVFXEnabled = config.Bind(visuals, "Head Fire VFX Enabled", true,
|
||||
new ConfigDescription("Whether the burning-skull effect (worn from tier 5+) renders at all. A client-side preference: disabling it stops you from seeing it on yourself and on every other skeleton you look at, but does not change what other players see."));
|
||||
BodyModelEnabled = config.Bind(visuals, "Body Model Enabled", true,
|
||||
new ConfigDescription("Whether Skeleton players wear the skeleton body. Turn it off if you use a player model mod (EnhancedValheimVRM and the like): Skeletons then keep the vanilla viking body, so the replacement model shows without bones clipping through it. Abilities are unchanged. Client-side, like the option above: it applies to every Skeleton you see, yourself included, and changes nothing for other players."));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -62,10 +62,11 @@ namespace RacesOfValheim
|
|||
Transform jaw = ResolveJaw();
|
||||
if (jaw == null || jaw.parent == null) return;
|
||||
|
||||
if (!SkeletonVisuals.IsSkeletonPlayer(m_player))
|
||||
if (!SkeletonVisuals.ShowsSkeletonBody(m_player))
|
||||
{
|
||||
// Nothing rewrites this bone on its own, so a player who stops being a Skeleton
|
||||
// would otherwise keep wearing the correction on their human face.
|
||||
// (or switches the skeleton body off) would otherwise keep wearing the correction
|
||||
// on their human face.
|
||||
if (m_applied)
|
||||
{
|
||||
jaw.localPosition = m_baseLocalPosition;
|
||||
|
|
|
|||
|
|
@ -254,7 +254,9 @@ namespace RacesOfValheim
|
|||
// before it could find out it was looking at a Skeleton.
|
||||
string race = SkeletonVisuals.GetPlayerRace(p);
|
||||
|
||||
if (race == SkeletonVisuals.RaceId)
|
||||
// With "Body Model Enabled" off a Skeleton takes the human branch below, the same
|
||||
// as any other race, so the toggle also works live: the next refresh swaps back.
|
||||
if (race == SkeletonVisuals.RaceId && SkeletonConfig.BodyModelEnabled.Value)
|
||||
{
|
||||
if (__instance.m_bodyModel != null)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -323,9 +323,13 @@ namespace RacesOfValheim
|
|||
VisEquipment currentVis = Player.m_localPlayer.GetComponent<VisEquipment>();
|
||||
if (currentVis != null)
|
||||
{
|
||||
// Hide Helmets (Valheim uses singular GameObject for helmet)
|
||||
var helmetObj = HarmonyLib.Traverse.Create(currentVis).Field<GameObject>("m_helmetItemInstance").Value;
|
||||
SkeletonVisuals.SetEquipmentPieceHidden(helmetObj, true);
|
||||
// Hide Helmets (Valheim uses singular GameObject for helmet). Only over a skull:
|
||||
// a viking body wears its helmet, and the VisEquipment postfix puts it back.
|
||||
if (SkeletonConfig.BodyModelEnabled.Value)
|
||||
{
|
||||
var helmetObj = HarmonyLib.Traverse.Create(currentVis).Field<GameObject>("m_helmetItemInstance").Value;
|
||||
SkeletonVisuals.SetEquipmentPieceHidden(helmetObj, true);
|
||||
}
|
||||
|
||||
// Scale Body Armor (Chest, Legs, Shoulder) by 5%
|
||||
string[] armorFields = { "m_chestItemInstances", "m_legItemInstances", "m_shoulderItemInstances" };
|
||||
|
|
@ -440,7 +444,7 @@ namespace RacesOfValheim
|
|||
}
|
||||
|
||||
// Flames on the skull, worn with the fire-tier model and nothing else.
|
||||
headFlame.Apply(Player.m_localPlayer, SkeletonConfig.HeadFireVFXEnabled.Value && SkeletonVisuals.GetModel(Player.m_localPlayer, state) == SkeletonProgression.FireModel);
|
||||
headFlame.Apply(Player.m_localPlayer, SkeletonConfig.HeadFireVFXEnabled.Value && SkeletonConfig.BodyModelEnabled.Value && SkeletonVisuals.GetModel(Player.m_localPlayer, state) == SkeletonProgression.FireModel);
|
||||
|
||||
if (rules.FireAura)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -49,6 +49,16 @@ namespace RacesOfValheim
|
|||
|
||||
public static bool IsSkeletonPlayer(Player player) => GetPlayerRace(player) == RaceId;
|
||||
|
||||
/// <summary>
|
||||
/// Whether this client draws the skeleton's bones on this player. False for every
|
||||
/// non-Skeleton, and for every Skeleton when "Body Model Enabled" is off: model-replacement
|
||||
/// mods (EnhancedValheimVRM and the like) hide the vanilla body and draw their own, so the
|
||||
/// borrowed bones ended up floating around the replacement model. With the option off the
|
||||
/// Skeleton keeps every ability and only looks like a plain viking.
|
||||
/// </summary>
|
||||
public static bool ShowsSkeletonBody(Player player) =>
|
||||
SkeletonConfig.BodyModelEnabled.Value && IsSkeletonPlayer(player);
|
||||
|
||||
/// <summary>
|
||||
/// Fully hides (or restores) one equipped item instance - a helmet, typically.
|
||||
///
|
||||
|
|
|
|||
|
|
@ -128,8 +128,11 @@ namespace RacesOfValheim
|
|||
vis.SetBeardItem(0);
|
||||
|
||||
// Hide Helmet
|
||||
var helmetObj = HarmonyLib.Traverse.Create(vis).Field<GameObject>("m_helmetItemInstance").Value;
|
||||
SkeletonVisuals.SetEquipmentPieceHidden(helmetObj, true);
|
||||
if (SkeletonConfig.BodyModelEnabled.Value)
|
||||
{
|
||||
var helmetObj = HarmonyLib.Traverse.Create(vis).Field<GameObject>("m_helmetItemInstance").Value;
|
||||
SkeletonVisuals.SetEquipmentPieceHidden(helmetObj, true);
|
||||
}
|
||||
|
||||
// Scale Body Armor
|
||||
string[] armorFields = { "m_chestItemInstances", "m_legItemInstances", "m_shoulderItemInstances" };
|
||||
|
|
@ -165,7 +168,7 @@ namespace RacesOfValheim
|
|||
|
||||
// The burning skull, grown locally for whoever we are looking at. The tier is on the
|
||||
// ZDO, so this client can work out for itself whether they should be alight.
|
||||
m_skeletonHeadFlame.Apply(m_player, SkeletonConfig.HeadFireVFXEnabled.Value && SkeletonVisuals.GetModel(m_player, state) == SkeletonProgression.FireModel);
|
||||
m_skeletonHeadFlame.Apply(m_player, SkeletonConfig.HeadFireVFXEnabled.Value && SkeletonConfig.BodyModelEnabled.Value && SkeletonVisuals.GetModel(m_player, state) == SkeletonProgression.FireModel);
|
||||
|
||||
// Apply Scale
|
||||
Vector3 targetScale = rules.ScaleMultiplier;
|
||||
|
|
|
|||
|
|
@ -15,9 +15,9 @@ Support the mod: [Patreon — NandorTheModder](https://www.patreon.com/c/NandorT
|
|||
|
||||
---
|
||||
|
||||
## New in v1.5.9
|
||||
## New in v1.5.10
|
||||
|
||||
Skeletons can laugh: type /evillaugh. The Furling's fire bonus now covers crossbow bolts, and a crossbow in hand no longer fires on every attack while you are transformed. Full details in the [changelog](#v159).
|
||||
Using a player model mod such as EnhancedValheimVRM? Turn off `Skeleton - Visuals` → `Body Model Enabled` and Skeletons keep the vanilla body, so no bones clip through your model. Full details in the [changelog](#v1510).
|
||||
|
||||
---
|
||||
|
||||
|
|
@ -30,6 +30,7 @@ Skeletons can laugh: type /evillaugh. The Furling's fire bonus now covers crossb
|
|||
- **Stamina-less Combat:** Skeletons use no stamina and do not have a stamina bar.
|
||||
- **Undead Diet:** Cannot eat normal food. Max health increases automatically as you defeat bosses to make up for lack of food buffs.
|
||||
- **Lit Sockets:** Your skull carries the eye lights of the creature your tier is built from, in that creature's own colour — so they change as the body does.
|
||||
- **Body Model switch:** with a player model mod (EnhancedValheimVRM and the like), set `Skeleton - Visuals` → `Body Model Enabled` to off and Skeletons keep the vanilla body. Abilities stay the same.
|
||||
|
||||
### 2. Skadi
|
||||

|
||||
|
|
@ -447,6 +448,10 @@ Both halves have an off switch under `Factions` in Configuration Manager: **Fact
|
|||
|
||||
## Changelog
|
||||
|
||||
### v1.5.10
|
||||
- **New - Skeleton body switch for player model mods:** with EnhancedValheimVRM or another model replacer, the skeleton's bones stayed on screen and floated around the new model. Set `Skeleton - Visuals` → `Body Model Enabled` to off and Skeletons keep the vanilla body: no bones, eye lights or skull flames, and the helmet shows. Abilities don't change. The setting is client-side, so it applies to every Skeleton you see and changes nothing for other players. The race strips hair and beard, so the vanilla body is bald, and the auto-resurrection still shows the skeleton for the few seconds it climbs out of the ground. Thanks to the players who reported it and tested the fix.
|
||||
- **Fix - Russian translation:** corrections to several Russian texts, by Axibed.
|
||||
|
||||
### v1.5.9
|
||||
- **New - /evillaugh (Skeleton):** the Skeleton throws its head back, clacks its jaw, shakes its shoulders and punches both fists into the air for four seconds. Everyone nearby sees it.
|
||||
- **Change - Furling fire bolts:** the Wickerman's fire damage now also applies to crossbow bolts, not only to arrows.
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "RacesOfValheim",
|
||||
"description": "A Valheim mod that adds ten custom playable races (Aswid, Draugh, Dvergar, Fenrir, Furling, Skadi, Skeleton, Sverm, Trenta, Trol) each with unique abilities, traits, race stations and a deep boss-driven progression system.",
|
||||
"version_number": "1.5.9",
|
||||
"version_number": "1.5.10",
|
||||
"website_url": "",
|
||||
"dependencies": [
|
||||
"denikson-BepInExPack_Valheim-5.4.2333",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue