spaceship/vfx
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Claude 4ebd832a70 #232: stop rebuilding the gas vents every frame
GasVentField called queue_redraw() every frame and its _draw rebuilt six
vents of seven glowing polygons each - 168 antialiased polylines
re-tessellated per frame, since every NeonDraw call expands into four.

Measured first: 40 rasterisations over 30 frames, costing 6.6ms against a
32.4ms floor. For scale, the black hole's cached disc costs 0.1ms.

Both halves are pieces now. The sources never move, never recolour and never
fade, so they are rasterised once. The rising bubbles genuinely change size
and opacity, but size is scale and opacity is modulate - neither needs the
geometry rebuilding. 40 rasterisations over 30 frames became 0.

Two things worth recording.

The static extraction alone measured NOTHING - 7.1ms against 6.6ms, inside
the noise. softpipe is a CPU rasteriser: it prices FILL, and cached geometry
fills the same pixels. It cannot see a tessellation saving at all. After the
full change the frame time read NEGATIVE with the floor drifting 28 to 39ms
between runs, so no millisecond figure is claimed here. The rasterisation
count is the reproducible result; what it is worth on a phone is unmeasured.

And scaling a NeonPiece scales its STROKE with it. The bubbles were first
built as unit circles scaled up by their radius, which multiplied NeonDraw's
widths by five to fourteen - a hundred pixels of glow around a fourteen
pixel bubble. They rendered as bright blobs, the rasterisation count said
40 -> 0, and only the screenshot disagreed. Built at the largest radius and
scaled DOWN now, so the stroke only ever thins. The trap is noted at the
call site: scale is safe for moving and shrinking a piece and quietly wrong
for growing one.

NeonPiece.add_polygon gained a width, which it needed to keep the vents'
authored stroke rather than silently fattening them.

179/179.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019AJMdB7iuHuLFZM1aBu3GD
2026-09-15 23:44:16 -04:00
..
AsteroidExplosionVFX.gd #155, #152: shots reach further and sooner, and the other explosions catch up 2026-08-29 14:39:35 +02:00
AsteroidExplosionVFX.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
BombBlastVFX.gd #114: the enemy bomber flies, and its bombs arrive 2026-08-23 21:58:56 +02:00
BombBlastVFX.gd.uid Add the .uid files Godot generated for the newest scripts 2026-08-24 12:10:41 +02:00
BuildingExplosionVFX.gd #99 (#97a): buildings have health, and can be destroyed 2026-08-23 13:37:40 +02:00
BuildingExplosionVFX.gd.uid Add the .uid files Godot generated for the new scripts 2026-08-23 19:23:50 +02:00
DimensionalBreach.gd #125: slow the prologue down, and give the breach a real black hole 2026-08-24 13:25:10 +02:00
DimensionalBreach.gd.uid Add the .uid files for the newest tests 2026-08-24 20:50:51 +02:00
DimensionalBreach.tscn #125: slow the prologue down, and give the breach a real black hole 2026-08-24 13:25:10 +02:00
EnemyExplosionVFX.gd #155, #152: shots reach further and sooner, and the other explosions catch up 2026-08-29 14:39:35 +02:00
EnemyExplosionVFX.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
ExplosionParticle.gd #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
ExplosionParticle.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
ExplosionVFXBase.gd Implement #85, #86, #87 and #88 2026-08-22 02:20:12 +02:00
ExplosionVFXBase.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
GasBombEffect.gd Sharpen upgrades, mark the convoy's destination, and give the world sound 2026-09-05 12:16:17 +02:00
GasBombEffect.gd.uid Add the .uid files Godot generated for the newest scripts 2026-08-24 12:10:41 +02:00
LaserBeamEffect.gd Sharpen upgrades, mark the convoy's destination, and give the world sound 2026-09-05 12:16:17 +02:00
LaserBeamEffect.gd.uid Add the .uid files Godot generated for the newest scripts 2026-08-24 12:10:41 +02:00
LightBurstVFX.gd #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
LightBurstVFX.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
MuzzleSparkVFX.gd #90: give the laser an ignition instead of a blink 2026-08-22 23:29:55 +02:00
MuzzleSparkVFX.gd.uid Implement #85, #86, #87 and #88 2026-08-22 02:20:12 +02:00
NeonDraw.gd #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
NeonDraw.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
NeonPiece.gd #232: stop rebuilding the gas vents every frame 2026-09-15 23:44:16 -04:00
NeonPiece.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
ResourcePickupVFX.gd #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
ResourcePickupVFX.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
ShipExplosionVFX.gd #155, #152: shots reach further and sooner, and the other explosions catch up 2026-08-29 14:39:35 +02:00
ShipExplosionVFX.gd.uid #84: move 215 root files into a folder hierarchy 2026-08-21 19:44:14 +02:00
ShipWreckVFX.gd #130, #135: a vessel's death takes a moment, and leaves an interceptor 2026-08-28 15:05:02 +02:00
ShipWreckVFX.gd.uid #130, #135: a vessel's death takes a moment, and leaves an interceptor 2026-08-28 15:05:02 +02:00