- SkinnedPlayerModel: generic play_oneshot() (generalizes the Land lock), Hit and Dance in the clip table (Dance loops), restartable clips - Hit flinch: victims visibly react on every peer's screen via the existing damage broadcast — no new RPC - Dance emote on B: toggles while grounded and idle, breaks on any movement; synced to remotes via synced_is_dancing (all three spawner configs) - Anime radial speed-lines overlay (canvas shader): fades in past ~1.2x walk speed, spikes on dash, widescreen-corrected clear center - New input action 'emote' (B) in project.godot 11/11 FSM tests, spawn smoke 0 failures. Co-Authored-By: Claude Fable 5 <[email protected]>
39 lines
1.3 KiB
Plaintext
39 lines
1.3 KiB
Plaintext
shader_type canvas_item;
|
|
|
|
// Anime-style radial speed lines. Fullscreen ColorRect overlay; `intensity`
|
|
// (0..1) is driven by the player controller from horizontal speed + dash.
|
|
// Lines live at the screen edges and jitter inward, center stays clear.
|
|
|
|
uniform float intensity : hint_range(0.0, 1.0) = 0.0;
|
|
uniform vec4 line_color : source_color = vec4(1.0, 1.0, 1.0, 1.0);
|
|
|
|
float hash(float n) {
|
|
return fract(sin(n * 4310.17) * 43758.5453);
|
|
}
|
|
|
|
void fragment() {
|
|
vec2 uv = UV - vec2(0.5);
|
|
uv.x *= 1.6; // widescreen: keep the clear zone round-ish
|
|
float dist = length(uv);
|
|
float ang = atan(uv.y, uv.x);
|
|
|
|
// Quantize the circle into spokes; each spoke gets a stable random phase.
|
|
float spokes = 90.0;
|
|
float id = floor((ang / 6.2831853 + 0.5) * spokes);
|
|
float rnd = hash(id);
|
|
|
|
// Only some spokes draw, and they flicker over time.
|
|
float alive = step(0.55, fract(rnd + floor(TIME * 9.0) * 0.13));
|
|
|
|
// Thin line across the spoke's angular width.
|
|
float local = fract((ang / 6.2831853 + 0.5) * spokes);
|
|
float line = smoothstep(0.5, 0.05, abs(local - 0.5)) ;
|
|
|
|
// Radial extent: start further out for weak intensity, reach inward as it grows.
|
|
float start = mix(0.62, 0.34, intensity) + rnd * 0.12;
|
|
float mask = smoothstep(start, start + 0.25, dist);
|
|
|
|
float a = intensity * alive * line * mask;
|
|
COLOR = vec4(line_color.rgb, a * line_color.a * 0.55);
|
|
}
|