feat: the Ljoskjarne floats 0.8 m above the ground

This commit is contained in:
kanym 2026-10-30 21:56:36 +01:00
commit 38bb8f1813
2 changed files with 3 additions and 3 deletions

View file

@ -4,7 +4,7 @@ using UnityEngine;
namespace RacesOfValheim namespace RacesOfValheim
{ {
/// <summary> /// <summary>
/// The Ljoskjarne's body: a stone pyramid, 2 m to a side and 2 m tall, floating 0.5 m above the /// The Ljoskjarne's body: a stone pyramid, 2 m to a side and 2 m tall, floating 0.8 m above the
/// ground. Dark steel carved with Valheim's own runes (the Ashlands rune tile's glyphs, laid out by /// ground. Dark steel carved with Valheim's own runes (the Ashlands rune tile's glyphs, laid out by
/// scripts/paint_nexus.py), and a cyan seam down the middle of each face. /// scripts/paint_nexus.py), and a cyan seam down the middle of each face.
/// ///
@ -20,7 +20,7 @@ namespace RacesOfValheim
{ {
private const float Height = 2f; private const float Height = 2f;
private const float HalfBase = 1f; private const float HalfBase = 1f;
private const float Lift = 0.5f; private const float Lift = 0.8f;
private const string SourceMaterialPrefab = "piece_cartographytable"; private const string SourceMaterialPrefab = "piece_cartographytable";
private const string EmbersSource = "fx_Torch_Carried"; private const string EmbersSource = "fx_Torch_Carried";

View file

@ -129,7 +129,7 @@ shade = np.clip(nm @ np.array([-0.5,0.5,0.7])/np.linalg.norm([-0.5,0.5,0.7]), 0,
Image.fromarray((np.clip(face*shade[...,None]*1.6,0,1)*255).astype(np.uint8)).save(os.path.join(d,"prev_nexus_bump.png")) Image.fromarray((np.clip(face*shade[...,None]*1.6,0,1)*255).astype(np.uint8)).save(os.path.join(d,"prev_nexus_bump.png"))
# --- preview: the pyramid as AlfarNexus builds it # --- preview: the pyramid as AlfarNexus builds it
HGT, B, LIFT = 2.0, 1.0, 0.5 # AlfarNexusLook: 2 m tall, 2 m base, floating 0.5 m up HGT, B, LIFT = 2.0, 1.0, 0.8 # AlfarNexusLook: 2 m tall, 2 m base, floating 0.8 m up
apex = np.array([0, LIFT+HGT, 0]); c = [np.array(p) for p in [(-B,LIFT,-B),(B,LIFT,-B),(B,LIFT,B),(-B,LIFT,B)]] apex = np.array([0, LIFT+HGT, 0]); c = [np.array(p) for p in [(-B,LIFT,-B),(B,LIFT,-B),(B,LIFT,B),(-B,LIFT,B)]]
lit = np.asarray(out, dtype=np.float32)/255 lit = np.asarray(out, dtype=np.float32)/255
lit = lit*(1-glow[...,None]) + np.array([0.35,0.75,1.0])*glow[...,None] lit = lit*(1-glow[...,None]) + np.array([0.35,0.75,1.0])*glow[...,None]