- BubbleTrail.gd: GPUParticles3D, auto-configured in _ready, set_intensity() API - BlockBreakParticles.gd: one_shot burst, emit_burst(pos, color) API - DolphinController.gd: bubble_trail onready + speed_factor hook in _update_movement - Dolphin.tscn: BubbleEmitterPoint (0,0,1.2) > BubbleTrail child added Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
22 lines
613 B
Plaintext
22 lines
613 B
Plaintext
shader_type spatial;
|
|
render_mode cull_front, depth_draw_never, blend_mix;
|
|
|
|
uniform vec3 surface_color : source_color = vec3(0.15, 0.45, 0.65);
|
|
uniform float wave_speed = 0.3;
|
|
uniform float wave_amplitude = 0.15;
|
|
|
|
void vertex() {
|
|
float wave1 = sin(VERTEX.x * 0.5 + TIME * wave_speed) * wave_amplitude;
|
|
float wave2 = cos(VERTEX.z * 0.4 + TIME * wave_speed * 1.3) * wave_amplitude * 0.7;
|
|
VERTEX.y += wave1 + wave2;
|
|
}
|
|
|
|
void fragment() {
|
|
ALBEDO = surface_color;
|
|
float fresnel = pow(1.0 - dot(NORMAL, VIEW), 2.0);
|
|
ALPHA = 0.4 + fresnel * 0.4;
|
|
METALLIC = 0.2;
|
|
ROUGHNESS = 0.3;
|
|
EMISSION = surface_color * 0.1;
|
|
}
|