FireLink

Version 3.3 — © 1996-2003 Christian Cohnen

The fire effect is one of the most iconic demoscene tricks — every demo on the Amiga, Atari ST or PC had one. The algorithm is beautifully simple: seed random hot pixels at the bottom of the screen, then propagate upward by averaging each pixel with its neighbors below and subtracting a small cooling factor. The result is a surprisingly realistic flame that rises, flickers and fades — all from a few lines of integer math and a color palette lookup.

FireLink wraps this classic effect into a clickable banner applet. A transparent foreground image (the link text or logo) floats over the flames, with an optional second image for mouseover state. The three-color gradient (backColormidColorendColor) lets you create anything from traditional red/yellow fire to white smoke, green plasma or blue ice. The cool parameter controls flame height, and with mouse enabled you can paint fire with the cursor.

Features

Parameters

NameTypeDescriptionDefaultRequired
imagefilenameTransparent foreground image (GIF) shown over the fireno
image2filenameAlternative image shown on mouseoverno
coolint (1–16)Cooling factor — higher values produce shorter flames1no
spotsintNumber of new fire hotspots seeded at the bottom each framewidth/16no
clearsintNumber of bottom pixels cleared each framewidth/8no
mouseEnable mouse-as-torch (presence enables it)offno
backColorhex colorColor gradient start (coldest)#000000no
midColorhex colorColor gradient midpoint#FF0000no
endColorhex colorColor gradient end (hottest)#00FFFFno
linkURLLink target when applet is clickedno
targetWindowStringTarget window for link (_blank, _self, etc.)_selfno

Code Example

<applet archive="FireLink.jar"
  code="FireLink.class" width="100" height="30">
  <param name="link" value="https://www.chriscohnen.de">
  <param name="image" value="hotlink.gif">
  <param name="cool" value="2">
  <param name="spots" value="20">
  <param name="clears" value="10">
  <param name="backColor" value="#000000">
  <param name="midColor" value="#FF0000">
  <param name="endColor" value="#FFFF66">
</applet>

Version History

VersionDateChanges
2.1May 1997First public version — link image with background fire
3.0November 1999Mouseover image, target window, renamed “pic” to “image”
3.2November 2003Build system, obfuscation
3.3August 2004Fixed left mouse click to link