gasPuff function
void
gasPuff(])
A puff of gas: a darker belly hanging low, a body, a denser core, a lit cap up and to the left.
Implementation
void gasPuff(
Painter p,
double x,
double y,
double r,
double a,
int belly,
int body,
int cap, [
int hi = 0,
]) {
if (a < 0.02 || r < 0.6) return;
p.disc(x + r * 0.06, y + r * 0.28, r * 0.9, belly, a * 0.55);
p.disc(x, y, r, body, a * 0.45);
p.disc(x + r * 0.03, y - r * 0.02, r * 0.76, body, a * 0.5);
p.disc(x - r * 0.2, y - r * 0.34, r * 0.52, cap, a * 0.45);
if (hi != 0) p.disc(x - r * 0.3, y - r * 0.55, r * 0.26, hi, a * 0.32);
}