import hardcorepawn.fog.*; fog myFog; float nearDist; float farDist; color fogColor; float a; void setup() { size(200,200,P3D); myFog=new fog(this); nearDist=150; farDist=300; fogColor=color(64,128,256); myFog.setupFog(nearDist,farDist); myFog.setColor(fogColor); a=0; } void draw() { a+=0.002; background(fogColor); camera(200*sin(a),200*cos(a),200*sin((a+0.5)/1.8),0,0,0,0,-1,0); fill(255,0,0); box(50); translate(0,0,-50); fill(0,255,0); box(50); translate(0,50,0); fill(0,0,255); box(50); myFog.doFog(); }