for(_='("+[e~]=Zc[c.YYfyZX,"90%",WX"hsl~V),UUVWg-T180Re(QMath.OOPI/R*Ni)*(R+L]+"%)"K233280J50DOsin(NCD0*CBt[k][2]b,d);c.fill(15Ocos(,1],c.s20*r()--;)30](YbaUYmYl0,0I=b-+4,M=.5>r()&&F(0]-*f/) -4-28I,MUOrandom((,l){for(function +/13K,Yfc)-250+D*k/URI+NL7UM+CL4))k in c)c[k[0]+[k[6]]Zk;S=s=f=0;t=[];e=360*S;k=0;kt.push([Bk-k,Uk]E(rs=(91*s+49297)%J;return s/J}Es=S;V+=.1Wg=*s+DK;Yfcw=a.width,h=a.heightk=2;k{avQX"rgba(.1)";Ytak*h/5+h/10 YbaYmw,hw,0i=;iw/*i+2,3-w,hYre)}A=199;Ak=(A+f%0)%avQUp=/(+--Us=3],P=2<h/2?2:h/2,Ytaw/2+Bf)*-p,h-P UcalQp,pUr(T*-h*h,10T250]-5DUXc[SZ"hsla~W/8++3+"%",1-(-0)/]+")",-0-2D4]U+2D+651],4]UYreUf%0==k&&(t[kZ[B(f+181),U0+f]f++;requestAnimationFramQE)}Fif(D0>l%1E3)YldZ12+28,UdMtrokQUi=0;360>i;i+=+D)1>i?Ym:Yl;else -8-600UI=99+5,-I+UI+)}';g=/[^ -AEFIMPS[-}]/.exec(_);)with(_.split(g))_=join(shift());eval(_)
/*
Story time, after submitting an update to the demo I planned to make another
update for the demo (which I didn't submit in the end) so I edited the code
to do some edits etc etc. And maybe you've guessed it, stupid me didn't make
a copy of the original source of the demo and just modified the code straight
away. Therefore, I have to reverse the changes in the code but I can't seem to
restore the changes completely. So, here's the almost original source of the
demo. It's not exactly the same as the one submitted, but it's almost the same
and the differences between this and the original code should be just very
minor things.
TL;DR this is not exactly the original source of the demo I submitted.
*/
/*
a, b, c = shim
e = theme color h
f = frame number
g = theme color l
h = canvas height
i, k, K = looping variable
r() = generate seeded random number
R() = render
s = random number seed
S = random number
t[] = road data
T() = draw tree
w = canvas width
x, y, z = function variable
X, Y, Z = placeholder variable
*/
S = Math.random(),
s = f = 0,
t = [],
e = S * 360;
for(k=200;k--;)t.push([Math.sin(k*(Math.PI/180))*500-250,150 Math.cos(k/30)*50,180-k,Math.random(),k]); //[x,y,z,seed,tree type]
R()
function r(x,y,z) {
s = (s * 9301 49297) % 233280;
return s / 233280
}
function R(x,y,z) {
s = S;
c.fillStyle="hsl(" [e =.1,"90%",g=s*20 50] "%)";
c.fillRect(0,0,w = a.width, h = a.height);
for(k=2;k--;) {
c.save();
c.fillStyle = "rgba(0,0,0,.1)";
c.translate(0,k*h/5 h/10-Math.cos(f/30)*20);
c.beginPath();
c.moveTo(w,h);
c.lineTo(w,0);
for(i=15;i--;)c.lineTo(w/15*i r()*20, 30*r());
c.lineTo(-w,h);
c.fill();
c.restore();
}
for(K=199;K--;) {
k=(K (f%200))%200;
c.save();
p = 30 / (30 t[k][2]--), s = t[k][3];
Z=(h/2>230)?230:h/2;
c.translate(w/2 500*Math.sin(Math.PI/180*f)*-p,h-Z-20*Math.cos(f/30));
c.scale(p,p);
r();
c.fillStyle = "hsl(" [e,"90%",g-30 t[k][2]/13] "%)";
c.fillRect(-h*15,t[k][1],h*30,10);
c.fillStyle = "hsl(" [e,"90%",g-25 t[k][2]/13] "%)";
c.fillRect(t[k][0]-50*r(),t[k][1],500,20);
c.fillStyle = c.strokeStyle = "hsla(" [e,"90%",t[k][2]/8 15 r()*3 "%",1-(t[k][2]-150)/30] ")";
if(r()<.5)T(t[k][0]-150-2500*r(),t[k][1],t[k][4]);
if(r()<.5)T(t[k][0] 2500*r() 650,t[k][1],t[k][4]);
c.restore();
if(f%200==k)t[k]=[Math.sin((f 181)*(Math.PI/180))*500-250,150 Math.cos(k/30)*50,180,Math.random(),200 f];
}
f ;
requestAnimationFrame(R)
}
function T(x,y,z) {
if(z%1e3<500) {
c.lineWidth = r()*12 28;
c.beginPath();
c.moveTo(x,y);
X = x-20 r()*40;
Y = y - r()*40 - 280;
c.lineTo(X,Y);
X = x-20 r()*40;
Y = Y - r()*40 - 280;
c.lineTo(X,Y);
c.stroke();
c.beginPath();
for(i=0;i<360;i =r()*15 50) {
if(i<1)c.moveTo(X Math.cos(i*(Math.PI/180)) * (180 r()*70), Y Math.sin(i*(Math.PI/180)) * (180 r()*40));
else c.lineTo(X Math.cos(i*(Math.PI/180)) * (180 r()*70), Y Math.sin(i*(Math.PI/180)) * (180 r()*40));
}
c.fill()
}
else {
c.beginPath();
c.moveTo(x,y - r()*80 - 600);
X = 99 r()*50;
c.lineTo(-X x,y);
c.lineTo(X x,y);
c.fill()
}
}