Drop the resolution gate in LoadPaintByName/ReadMapPng. A slot saved at any size is now bilinearly resampled per map to the current avatar's textureSize (new ResampleBilinear/Bilerp helpers, running on the stored bytes with no gamma conversion to match downstream consumption), so any painting loads onto any avatar regardless of the size it was saved at.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The fur is drawn from a CPU-baked unit-scale mesh whose instance matrix
carries the avatar's world scale, so the extrusion scaled fully 1:1 with
the player (hider 0.5 / hunter 1.5). That read as too-short fur on the
small hider and too-long on the big hunter, and the curvature droop was
sized off the raw unity_ObjectToWorld which doesn't carry the per-instance
scale in the RenderMeshInstanced path.
- FurShellRenderer pushes the avatar's lossyScale (_FurObjScale) plus a new
Fur Scale Influence (0..1, default 0.5) that blends the fur SIZE between
fully proportional (1) and a constant world length (0). The shader
pre-divides the object-space displacement so the net world length follows
effScale; curl droop and wind use the same effScale, keeping the curl
SHAPE invariant across avatar sizes and influence settings.
- The body's see-through X-ray reveal (forward half) is mirrored onto the
visible fur so strands glow WITH the reveal instead of hiding it under
opaque fur. FurShellRenderer pulls the live colour/pulse/flash from the
sibling MeshPainter (new getters), in phase with the body. A new X-Ray
Fur Strength (default 0.2) tames the per-shell accumulation, since the
body writes the glow once (opaque) but the fur stacks N transparent
shells that each composite it.
Co-Authored-By: Claude <noreply@anthropic.com>
X-ray hit flash: drive a dedicated flash mode instead of the normal
reveal - pulse off (steady), intensity boost (xrayFlashBoost, default 3x),
snap-on, then restore authored color/pulse exactly. Fixes the weak/dark
flicker where the 0.35s hit window often caught only the pulse's near-off
plateau.
Spawn/respawn freeze: pool GPU RenderTextures across despawn->respawn
(TeardownGpu recycles, CreateRT pops) so a hider->hunter conversion no
longer churns ~70MB of RT alloc/free on every observer; reuse staging
textures to cut per-map GC. Defer the blank base-seed on reveal-gated
remote replicas (DeferInitialSeed) - the real pixels arrive with the
snapshot apply anyway; gate the FurShellRenderer alongside the body so a
deferred replica never shows the pooled RT's stale fur; EnsureBackendSeeded
+ TryCaptureSnapshot guard against capture-before-reseed.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- Laser.shader + HunterLaserBeam: additive HDR beam, fade in/out over opacity
and thickness, code-driven LineRenderer, tunable emission multiplier.
- FirstPersonMode: TryShoot computes world endpoint, fires beam with lateral
muzzle offset (right) so it isn't dead-center from hunter view.
- NetworkPlayerSetup: shot relay RPCs (owner->server->all) + hit-flash RPC
(server->all), flash OR-branch in ComputeXRay.
- MatchManager: hit reveal broadcasts X-ray flash first, delays hider removal
by hitRevealDelay so the glow is visible before the body vanishes.
- MeshPainter reseed: in-place fast path avoids full GPU backend teardown on
snapshot apply (no ~70MB RT churn), fixes spawn/paint-load hitch.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Hide remote avatars until this client has actually applied a snapshot
reaching the owner-published baseline cutoff, preventing the default
grey/white material from flashing before a player's painting has loaded.
- PlayerPaintSync: owner-authoritative _publishedCutoff NetworkVariable,
receiver tracks _appliedCutoff; explicit blank publish for never-painted
avatars so they still reveal.
- NetworkPlayerSetup: cache _paintSync, hide body renderers on spawn, gate
UpdateVisibility on PaintRevealReady.
- MeshPainter.Pick: fur toggle now follows pickedHeight (own paint-mesh
only), matching the Occlusion/Height pipette behaviour.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- Fur-Map trägt nur noch R = Länge (linearer Datenkanal); Farbe kommt per-texel
aus der Live-Albedo-RT (an _BaseMap des Shell-Shaders gebunden)
- Toggle_Fur als echtes Gate (IsChannelActive = fur), Default aus, furLength 0.5
- Weicher Alpha-Übergang (radial/tip/length coverage) statt Hard-Clip; Transparent-
Pass mit Depth-Bias (Offset -1,-1) gegen Body-Durchflimmern
- Root dunkler / Tip heller aus gemalter Farbe abgeleitet (kein Fix-Tint)
- Gravity/Curl in World-Space nach Transform (unabhängig von Mesh-Rotation)
- Pipette aktiviert Fur-Toggle immer; liest R-Kanal als Länge
- First-Person blendet FurShellRenderer mit aus
- Netzwerk (FlagFur), Undo, Persistence (fur.png R=Länge) mitgezogen
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Fur wird die vierte kanonische Paint-Map (RGB=Farbe, A=Länge). Integration
über Seed (kahl), GPU/CPU-Paint, Undo, Netzwerk-Sync, Persistence (fur.png,
v6) und Live-RT-Hook im FurShellRenderer. HUD-Binding (Toggle/Picker/Alpha)
aktiviert. Fur-Alpha lerpt jetzt zu einer Ziel-Opacity (Slider_FurOpacity)
statt additiv Richtung 1 zu akkumulieren (zwei Brush-Passes: Fade + Deposit).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The orbit rig read the wheel unfiltered for zoom, so scrolling a paint-mode
scroll list also zoomed the camera. Gate the zoom behind a shared
InputUtil.PointerOverUi() helper (EventSystem raycast); MeshPainter's private
IsPointerOverUi() now delegates to the same helper (DRY).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replace the flat binary .paint format with a folder per painting under
Paintings/<key>/: albedo/emission as sRGB PNGs, the packed MSO map split
into human-readable metallic/occlusion/smoothness grayscale PNGs, and the
non-baked scalars (name, size, emission intensity, camo/height knobs) in
painting.json. MSO.B is always 0 (pack shader), so the split round-trips
losslessly with no alpha ambiguity. Public API (SavePaintAs/LoadPaintByName/
ListSavedPaintings/PaintExists/DeletePaint) and the network snapshot path
(WriteCanonicalMaps/ReadCanonicalMaps) are unchanged.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Paint RTs were ARGB32 (8 bpp). Repeated source-over at low alpha rounds
back to the previous value once the per-stroke decrement dst*alpha drops
below half an LSB, so it freezes at a grey floor (~0.5/alpha in 255ths) -
e.g. black at low opacity never reaches 0. Switch the accumulation buffers
to ARGBHalf (16-bit linear). The sRGB round-trip stays at the byte boundary
(seed decodes on upload, ReadRtPixels re-encodes on readback), so canonical
bytes and CPU/GPU parity are unchanged - only the accumulation gained bits.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
MapPropIds (in MeshPainter.Backend.cs) referenced the *Id fields from the
MeshPainter.cs partial in its field initializer. Static field-initializer
order across partial-class files is unspecified in C#; after the script
reorg the composite array initialized before the *Id fields and captured 0
for every property id. HasProperty(0) is always false, so AssignMapTexture
bound no maps at all -> the shader fell back to its white default textures,
making every fresh avatar fully glossy (smoothness 1) and emissive.
Build MapPropIds lazily on first access (runtime, after all static
initializers) so the file order no longer matters. The per-stroke allocation
savings are preserved; only a single null-check per call is added.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Move scripts under Assets/Scripts/ into Components, GameMode, Helper,
Network, Enum, Struct and ScriptableObject folders. Pure file moves
(plus folder .meta files); no code changes.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>