summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorozh <ozh@ozh.org>2014-02-14 10:13:58 +0100
committerozh <ozh@ozh.org>2014-02-14 10:13:58 +0100
commit8bbc037eb8bcd6e36baa025b3252f9ba676e5ce6 (patch)
tree160aa03408b780447f59982bf63d4793912eb51a
parentbaa0a68dcc965833b2c9f0eb31dda045fa3d17c7 (diff)
1.0411
-rw-r--r--excanvas.compiled.js35
-rw-r--r--img/alchemylabIconOff.pngbin0 -> 313 bytes
-rw-r--r--img/antimattercondenserIconOff.pngbin0 -> 207 bytes
-rw-r--r--img/cursoriconOff.pngbin0 -> 297 bytes
-rw-r--r--img/factoryIconOff.pngbin0 -> 192 bytes
-rw-r--r--img/farmIconOff.pngbin0 -> 288 bytes
-rw-r--r--img/grandmaIconOff.pngbin0 -> 249 bytes
-rw-r--r--img/heartStorm.pngbin0 -> 65672 bytes
-rw-r--r--img/hearts.pngbin0 -> 23508 bytes
-rw-r--r--img/icons.pngbin32827 -> 40258 bytes
-rw-r--r--img/list.txt19
-rw-r--r--img/mineIconOff.pngbin0 -> 227 bytes
-rw-r--r--img/portalIconOff.pngbin0 -> 233 bytes
-rw-r--r--img/prism.pngbin0 -> 782 bytes
-rw-r--r--img/prismBackground.pngbin0 -> 701 bytes
-rw-r--r--img/prismIcon.pngbin0 -> 674 bytes
-rw-r--r--img/prismIconOff.pngbin0 -> 333 bytes
-rw-r--r--img/rainbowGrandma.pngbin0 -> 626 bytes
-rw-r--r--img/shipmentIconOff.pngbin0 -> 298 bytes
-rw-r--r--img/timemachineIconOff.pngbin0 -> 293 bytes
-rw-r--r--img/timerBars.pngbin0 -> 2306 bytes
-rw-r--r--index.html12
-rw-r--r--list.txt7
-rw-r--r--main.js507
-rw-r--r--mobile.js82
-rw-r--r--phonegap.js168
26 files changed, 460 insertions, 370 deletions
diff --git a/excanvas.compiled.js b/excanvas.compiled.js
new file mode 100644
index 0000000..a34ca1d
--- /dev/null
+++ b/excanvas.compiled.js
@@ -0,0 +1,35 @@
+// Copyright 2006 Google Inc.
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+document.createElement("canvas").getContext||(function(){var s=Math,j=s.round,F=s.sin,G=s.cos,V=s.abs,W=s.sqrt,k=10,v=k/2;function X(){return this.context_||(this.context_=new H(this))}var L=Array.prototype.slice;function Y(b,a){var c=L.call(arguments,2);return function(){return b.apply(a,c.concat(L.call(arguments)))}}var M={init:function(b){if(/MSIE/.test(navigator.userAgent)&&!window.opera){var a=b||document;a.createElement("canvas");a.attachEvent("onreadystatechange",Y(this.init_,this,a))}},init_:function(b){b.namespaces.g_vml_||
+b.namespaces.add("g_vml_","urn:schemas-microsoft-com:vml","#default#VML");b.namespaces.g_o_||b.namespaces.add("g_o_","urn:schemas-microsoft-com:office:office","#default#VML");if(!b.styleSheets.ex_canvas_){var a=b.createStyleSheet();a.owningElement.id="ex_canvas_";a.cssText="canvas{display:inline-block;overflow:hidden;text-align:left;width:300px;height:150px}g_vml_\\:*{behavior:url(#default#VML)}g_o_\\:*{behavior:url(#default#VML)}"}var c=b.getElementsByTagName("canvas"),d=0;for(;d<c.length;d++)this.initElement(c[d])},
+initElement:function(b){if(!b.getContext){b.getContext=X;b.innerHTML="";b.attachEvent("onpropertychange",Z);b.attachEvent("onresize",$);var a=b.attributes;if(a.width&&a.width.specified)b.style.width=a.width.nodeValue+"px";else b.width=b.clientWidth;if(a.height&&a.height.specified)b.style.height=a.height.nodeValue+"px";else b.height=b.clientHeight}return b}};function Z(b){var a=b.srcElement;switch(b.propertyName){case "width":a.style.width=a.attributes.width.nodeValue+"px";a.getContext().clearRect();
+break;case "height":a.style.height=a.attributes.height.nodeValue+"px";a.getContext().clearRect();break}}function $(b){var a=b.srcElement;if(a.firstChild){a.firstChild.style.width=a.clientWidth+"px";a.firstChild.style.height=a.clientHeight+"px"}}M.init();var N=[],B=0;for(;B<16;B++){var C=0;for(;C<16;C++)N[B*16+C]=B.toString(16)+C.toString(16)}function I(){return[[1,0,0],[0,1,0],[0,0,1]]}function y(b,a){var c=I(),d=0;for(;d<3;d++){var f=0;for(;f<3;f++){var h=0,g=0;for(;g<3;g++)h+=b[d][g]*a[g][f];c[d][f]=
+h}}return c}function O(b,a){a.fillStyle=b.fillStyle;a.lineCap=b.lineCap;a.lineJoin=b.lineJoin;a.lineWidth=b.lineWidth;a.miterLimit=b.miterLimit;a.shadowBlur=b.shadowBlur;a.shadowColor=b.shadowColor;a.shadowOffsetX=b.shadowOffsetX;a.shadowOffsetY=b.shadowOffsetY;a.strokeStyle=b.strokeStyle;a.globalAlpha=b.globalAlpha;a.arcScaleX_=b.arcScaleX_;a.arcScaleY_=b.arcScaleY_;a.lineScale_=b.lineScale_}function P(b){var a,c=1;b=String(b);if(b.substring(0,3)=="rgb"){var d=b.indexOf("(",3),f=b.indexOf(")",d+
+1),h=b.substring(d+1,f).split(",");a="#";var g=0;for(;g<3;g++)a+=N[Number(h[g])];if(h.length==4&&b.substr(3,1)=="a")c=h[3]}else a=b;return{color:a,alpha:c}}function aa(b){switch(b){case "butt":return"flat";case "round":return"round";case "square":default:return"square"}}function H(b){this.m_=I();this.mStack_=[];this.aStack_=[];this.currentPath_=[];this.fillStyle=this.strokeStyle="#000";this.lineWidth=1;this.lineJoin="miter";this.lineCap="butt";this.miterLimit=k*1;this.globalAlpha=1;this.canvas=b;
+var a=b.ownerDocument.createElement("div");a.style.width=b.clientWidth+"px";a.style.height=b.clientHeight+"px";a.style.overflow="hidden";a.style.position="absolute";b.appendChild(a);this.element_=a;this.lineScale_=this.arcScaleY_=this.arcScaleX_=1}var i=H.prototype;i.clearRect=function(){this.element_.innerHTML=""};i.beginPath=function(){this.currentPath_=[]};i.moveTo=function(b,a){var c=this.getCoords_(b,a);this.currentPath_.push({type:"moveTo",x:c.x,y:c.y});this.currentX_=c.x;this.currentY_=c.y};
+i.lineTo=function(b,a){var c=this.getCoords_(b,a);this.currentPath_.push({type:"lineTo",x:c.x,y:c.y});this.currentX_=c.x;this.currentY_=c.y};i.bezierCurveTo=function(b,a,c,d,f,h){var g=this.getCoords_(f,h),l=this.getCoords_(b,a),e=this.getCoords_(c,d);Q(this,l,e,g)};function Q(b,a,c,d){b.currentPath_.push({type:"bezierCurveTo",cp1x:a.x,cp1y:a.y,cp2x:c.x,cp2y:c.y,x:d.x,y:d.y});b.currentX_=d.x;b.currentY_=d.y}i.quadraticCurveTo=function(b,a,c,d){var f=this.getCoords_(b,a),h=this.getCoords_(c,d),g={x:this.currentX_+
+0.6666666666666666*(f.x-this.currentX_),y:this.currentY_+0.6666666666666666*(f.y-this.currentY_)};Q(this,g,{x:g.x+(h.x-this.currentX_)/3,y:g.y+(h.y-this.currentY_)/3},h)};i.arc=function(b,a,c,d,f,h){c*=k;var g=h?"at":"wa",l=b+G(d)*c-v,e=a+F(d)*c-v,m=b+G(f)*c-v,r=a+F(f)*c-v;if(l==m&&!h)l+=0.125;var n=this.getCoords_(b,a),o=this.getCoords_(l,e),q=this.getCoords_(m,r);this.currentPath_.push({type:g,x:n.x,y:n.y,radius:c,xStart:o.x,yStart:o.y,xEnd:q.x,yEnd:q.y})};i.rect=function(b,a,c,d){this.moveTo(b,
+a);this.lineTo(b+c,a);this.lineTo(b+c,a+d);this.lineTo(b,a+d);this.closePath()};i.strokeRect=function(b,a,c,d){var f=this.currentPath_;this.beginPath();this.moveTo(b,a);this.lineTo(b+c,a);this.lineTo(b+c,a+d);this.lineTo(b,a+d);this.closePath();this.stroke();this.currentPath_=f};i.fillRect=function(b,a,c,d){var f=this.currentPath_;this.beginPath();this.moveTo(b,a);this.lineTo(b+c,a);this.lineTo(b+c,a+d);this.lineTo(b,a+d);this.closePath();this.fill();this.currentPath_=f};i.createLinearGradient=function(b,
+a,c,d){var f=new D("gradient");f.x0_=b;f.y0_=a;f.x1_=c;f.y1_=d;return f};i.createRadialGradient=function(b,a,c,d,f,h){var g=new D("gradientradial");g.x0_=b;g.y0_=a;g.r0_=c;g.x1_=d;g.y1_=f;g.r1_=h;return g};i.drawImage=function(b){var a,c,d,f,h,g,l,e,m=b.runtimeStyle.width,r=b.runtimeStyle.height;b.runtimeStyle.width="auto";b.runtimeStyle.height="auto";var n=b.width,o=b.height;b.runtimeStyle.width=m;b.runtimeStyle.height=r;if(arguments.length==3){a=arguments[1];c=arguments[2];h=g=0;l=d=n;e=f=o}else if(arguments.length==
+5){a=arguments[1];c=arguments[2];d=arguments[3];f=arguments[4];h=g=0;l=n;e=o}else if(arguments.length==9){h=arguments[1];g=arguments[2];l=arguments[3];e=arguments[4];a=arguments[5];c=arguments[6];d=arguments[7];f=arguments[8]}else throw Error("Invalid number of arguments");var q=this.getCoords_(a,c),t=[];t.push(" <g_vml_:group",' coordsize="',k*10,",",k*10,'"',' coordorigin="0,0"',' style="width:',10,"px;height:",10,"px;position:absolute;");if(this.m_[0][0]!=1||this.m_[0][1]){var E=[];E.push("M11=",
+this.m_[0][0],",","M12=",this.m_[1][0],",","M21=",this.m_[0][1],",","M22=",this.m_[1][1],",","Dx=",j(q.x/k),",","Dy=",j(q.y/k),"");var p=q,z=this.getCoords_(a+d,c),w=this.getCoords_(a,c+f),x=this.getCoords_(a+d,c+f);p.x=s.max(p.x,z.x,w.x,x.x);p.y=s.max(p.y,z.y,w.y,x.y);t.push("padding:0 ",j(p.x/k),"px ",j(p.y/k),"px 0;filter:progid:DXImageTransform.Microsoft.Matrix(",E.join(""),", sizingmethod='clip');")}else t.push("top:",j(q.y/k),"px;left:",j(q.x/k),"px;");t.push(' ">','<g_vml_:image src="',b.src,
+'"',' style="width:',k*d,"px;"," height:",k*f,'px;"',' cropleft="',h/n,'"',' croptop="',g/o,'"',' cropright="',(n-h-l)/n,'"',' cropbottom="',(o-g-e)/o,'"'," />","</g_vml_:group>");this.element_.insertAdjacentHTML("BeforeEnd",t.join(""))};i.stroke=function(b){var a=[],c=P(b?this.fillStyle:this.strokeStyle),d=c.color,f=c.alpha*this.globalAlpha;a.push("<g_vml_:shape",' filled="',!!b,'"',' style="position:absolute;width:',10,"px;height:",10,'px;"',' coordorigin="0 0" coordsize="',k*10," ",k*10,'"',' stroked="',
+!b,'"',' path="');var h={x:null,y:null},g={x:null,y:null},l=0;for(;l<this.currentPath_.length;l++){var e=this.currentPath_[l];switch(e.type){case "moveTo":a.push(" m ",j(e.x),",",j(e.y));break;case "lineTo":a.push(" l ",j(e.x),",",j(e.y));break;case "close":a.push(" x ");e=null;break;case "bezierCurveTo":a.push(" c ",j(e.cp1x),",",j(e.cp1y),",",j(e.cp2x),",",j(e.cp2y),",",j(e.x),",",j(e.y));break;case "at":case "wa":a.push(" ",e.type," ",j(e.x-this.arcScaleX_*e.radius),",",j(e.y-this.arcScaleY_*e.radius),
+" ",j(e.x+this.arcScaleX_*e.radius),",",j(e.y+this.arcScaleY_*e.radius)," ",j(e.xStart),",",j(e.yStart)," ",j(e.xEnd),",",j(e.yEnd));break}if(e){if(h.x==null||e.x<h.x)h.x=e.x;if(g.x==null||e.x>g.x)g.x=e.x;if(h.y==null||e.y<h.y)h.y=e.y;if(g.y==null||e.y>g.y)g.y=e.y}}a.push(' ">');if(b)if(typeof this.fillStyle=="object"){var m=this.fillStyle,r=0,n={x:0,y:0},o=0,q=1;if(m.type_=="gradient"){var t=m.x1_/this.arcScaleX_,E=m.y1_/this.arcScaleY_,p=this.getCoords_(m.x0_/this.arcScaleX_,m.y0_/this.arcScaleY_),
+z=this.getCoords_(t,E);r=Math.atan2(z.x-p.x,z.y-p.y)*180/Math.PI;if(r<0)r+=360;if(r<1.0E-6)r=0}else{var p=this.getCoords_(m.x0_,m.y0_),w=g.x-h.x,x=g.y-h.y;n={x:(p.x-h.x)/w,y:(p.y-h.y)/x};w/=this.arcScaleX_*k;x/=this.arcScaleY_*k;var R=s.max(w,x);o=2*m.r0_/R;q=2*m.r1_/R-o}var u=m.colors_;u.sort(function(ba,ca){return ba.offset-ca.offset});var J=u.length,da=u[0].color,ea=u[J-1].color,fa=u[0].alpha*this.globalAlpha,ga=u[J-1].alpha*this.globalAlpha,S=[],l=0;for(;l<J;l++){var T=u[l];S.push(T.offset*q+
+o+" "+T.color)}a.push('<g_vml_:fill type="',m.type_,'"',' method="none" focus="100%"',' color="',da,'"',' color2="',ea,'"',' colors="',S.join(","),'"',' opacity="',ga,'"',' g_o_:opacity2="',fa,'"',' angle="',r,'"',' focusposition="',n.x,",",n.y,'" />')}else a.push('<g_vml_:fill color="',d,'" opacity="',f,'" />');else{var K=this.lineScale_*this.lineWidth;if(K<1)f*=K;a.push("<g_vml_:stroke",' opacity="',f,'"',' joinstyle="',this.lineJoin,'"',' miterlimit="',this.miterLimit,'"',' endcap="',aa(this.lineCap),
+'"',' weight="',K,'px"',' color="',d,'" />')}a.push("</g_vml_:shape>");this.element_.insertAdjacentHTML("beforeEnd",a.join(""))};i.fill=function(){this.stroke(true)};i.closePath=function(){this.currentPath_.push({type:"close"})};i.getCoords_=function(b,a){var c=this.m_;return{x:k*(b*c[0][0]+a*c[1][0]+c[2][0])-v,y:k*(b*c[0][1]+a*c[1][1]+c[2][1])-v}};i.save=function(){var b={};O(this,b);this.aStack_.push(b);this.mStack_.push(this.m_);this.m_=y(I(),this.m_)};i.restore=function(){O(this.aStack_.pop(),
+this);this.m_=this.mStack_.pop()};function ha(b){var a=0;for(;a<3;a++){var c=0;for(;c<2;c++)if(!isFinite(b[a][c])||isNaN(b[a][c]))return false}return true}function A(b,a,c){if(!!ha(a)){b.m_=a;if(c)b.lineScale_=W(V(a[0][0]*a[1][1]-a[0][1]*a[1][0]))}}i.translate=function(b,a){A(this,y([[1,0,0],[0,1,0],[b,a,1]],this.m_),false)};i.rotate=function(b){var a=G(b),c=F(b);A(this,y([[a,c,0],[-c,a,0],[0,0,1]],this.m_),false)};i.scale=function(b,a){this.arcScaleX_*=b;this.arcScaleY_*=a;A(this,y([[b,0,0],[0,a,
+0],[0,0,1]],this.m_),true)};i.transform=function(b,a,c,d,f,h){A(this,y([[b,a,0],[c,d,0],[f,h,1]],this.m_),true)};i.setTransform=function(b,a,c,d,f,h){A(this,[[b,a,0],[c,d,0],[f,h,1]],true)};i.clip=function(){};i.arcTo=function(){};i.createPattern=function(){return new U};function D(b){this.type_=b;this.r1_=this.y1_=this.x1_=this.r0_=this.y0_=this.x0_=0;this.colors_=[]}D.prototype.addColorStop=function(b,a){a=P(a);this.colors_.push({offset:b,color:a.color,alpha:a.alpha})};function U(){}G_vmlCanvasManager=
+M;CanvasRenderingContext2D=H;CanvasGradient=D;CanvasPattern=U})();
diff --git a/img/alchemylabIconOff.png b/img/alchemylabIconOff.png
new file mode 100644
index 0000000..8e2733b
--- /dev/null
+++ b/img/alchemylabIconOff.png
Binary files differ
diff --git a/img/antimattercondenserIconOff.png b/img/antimattercondenserIconOff.png
new file mode 100644
index 0000000..69ff0ea
--- /dev/null
+++ b/img/antimattercondenserIconOff.png
Binary files differ
diff --git a/img/cursoriconOff.png b/img/cursoriconOff.png
new file mode 100644
index 0000000..99e7c71
--- /dev/null
+++ b/img/cursoriconOff.png
Binary files differ
diff --git a/img/factoryIconOff.png b/img/factoryIconOff.png
new file mode 100644
index 0000000..7b52b8f
--- /dev/null
+++ b/img/factoryIconOff.png
Binary files differ
diff --git a/img/farmIconOff.png b/img/farmIconOff.png
new file mode 100644
index 0000000..94fa896
--- /dev/null
+++ b/img/farmIconOff.png
Binary files differ
diff --git a/img/grandmaIconOff.png b/img/grandmaIconOff.png
new file mode 100644
index 0000000..8b0900a
--- /dev/null
+++ b/img/grandmaIconOff.png
Binary files differ
diff --git a/img/heartStorm.png b/img/heartStorm.png
new file mode 100644
index 0000000..391d57a
--- /dev/null
+++ b/img/heartStorm.png
Binary files differ
diff --git a/img/hearts.png b/img/hearts.png
new file mode 100644
index 0000000..6e6a225
--- /dev/null
+++ b/img/hearts.png
Binary files differ
diff --git a/img/icons.png b/img/icons.png
index a400a36..9521a9d 100644
--- a/img/icons.png
+++ b/img/icons.png
Binary files differ
diff --git a/img/list.txt b/img/list.txt
index d105b90..676b4a0 100644
--- a/img/list.txt
+++ b/img/list.txt
@@ -2,12 +2,14 @@ alarmTurret.png
alchemylab.png
alchemylabBackground.png
alchemylabIcon.png
+alchemylabIconOff.png
alteredGrandma.png
angrySentientCookie.png
antiGrandma.png
antimattercondenser.png
antimattercondenserBackground.png
antimattercondenserIcon.png
+antimattercondenserIconOff.png
aqworldsbanner.jpg
ascendedBakingPod.png
babySentientCookie.png
@@ -15,7 +17,6 @@ bgBlue.jpg
blackGradient.png
burntSentientCookie.png
buttonTile.jpg
-caramelMilk.png
caramelWave.png
chirpy.png
chocolateMilkWave.png
@@ -28,6 +29,7 @@ crazedDoughSpurter.png
crazedKneader.png
cursor.png
cursoricon.png
+cursoriconOff.png
darkNoise.png
disgruntledCleaningLady.png
disgruntledOverseer.png
@@ -43,9 +45,11 @@ empty.png
factory.png
factoryBackground.png
factoryIcon.png
+factoryIconOff.png
farm.png
farmBackground.png
farmIcon.png
+farmIconOff.png
farmerGrandma.png
favicon.ico
frostedReindeer.png
@@ -60,10 +64,13 @@ grandmaIcon.png
grandmaIconB.png
grandmaIconC.png
grandmaIconD.png
+grandmaIconOff.png
grandmas1.jpg
grandmas2.jpg
grandmas3.jpg
grandmasGrandma.png
+heartStorm.png
+hearts.png
hpBar.png
hpmBar.png
icons.png
@@ -79,6 +86,7 @@ milkWave.png
mine.png
mineBackground.png
mineIcon.png
+mineIconOff.png
minerGrandma.png
money.png
mysteriousHero.png
@@ -90,10 +98,16 @@ perfectCookie.png
portal.png
portalBackground.png
portalIcon.png
+portalIconOff.png
portraitChip.png
portraitCrumb.png
portraitDoe.png
portraitLucky.png
+prism.png
+prismBackground.png
+prismIcon.png
+prismIconOff.png
+rainbowGrandma.png
raspberryWave.png
rawSentientCookie.png
santa.png
@@ -105,6 +119,7 @@ shine.png
shipment.png
shipmentBackground.png
shipmentIcon.png
+shipmentIconOff.png
smallCookies.png
snow.jpg
snow2.jpg
@@ -114,6 +129,8 @@ sugarBunny.png
timemachine.png
timemachineBackground.png
timemachineIcon.png
+timemachineIconOff.png
+timerBars.png
transmutedGrandma.png
upgradeFrame.png
winterFrame.png
diff --git a/img/mineIconOff.png b/img/mineIconOff.png
new file mode 100644
index 0000000..bca22a0
--- /dev/null
+++ b/img/mineIconOff.png
Binary files differ
diff --git a/img/portalIconOff.png b/img/portalIconOff.png
new file mode 100644
index 0000000..99cbe9f
--- /dev/null
+++ b/img/portalIconOff.png
Binary files differ
diff --git a/img/prism.png b/img/prism.png
new file mode 100644
index 0000000..9b7ca67
--- /dev/null
+++ b/img/prism.png
Binary files differ
diff --git a/img/prismBackground.png b/img/prismBackground.png
new file mode 100644
index 0000000..ecb4eb5
--- /dev/null
+++ b/img/prismBackground.png
Binary files differ
diff --git a/img/prismIcon.png b/img/prismIcon.png
new file mode 100644
index 0000000..d3c9f57
--- /dev/null
+++ b/img/prismIcon.png
Binary files differ
diff --git a/img/prismIconOff.png b/img/prismIconOff.png
new file mode 100644
index 0000000..934d3ec
--- /dev/null
+++ b/img/prismIconOff.png
Binary files differ
diff --git a/img/rainbowGrandma.png b/img/rainbowGrandma.png
new file mode 100644
index 0000000..6424bb8
--- /dev/null
+++ b/img/rainbowGrandma.png
Binary files differ
diff --git a/img/shipmentIconOff.png b/img/shipmentIconOff.png
new file mode 100644
index 0000000..e0d5596
--- /dev/null
+++ b/img/shipmentIconOff.png
Binary files differ
diff --git a/img/timemachineIconOff.png b/img/timemachineIconOff.png
new file mode 100644
index 0000000..25988c9
--- /dev/null
+++ b/img/timemachineIconOff.png
Binary files differ
diff --git a/img/timerBars.png b/img/timerBars.png
new file mode 100644
index 0000000..04b5910
--- /dev/null
+++ b/img/timerBars.png
Binary files differ
diff --git a/index.html b/index.html
index ed132bd..4670f7a 100644
--- a/index.html
+++ b/index.html
@@ -1,3 +1,4 @@
+
<!DOCTYPE html>
<html>
<head>
@@ -21,21 +22,19 @@ Feel free to alter this code to your liking, but please do not re-host it, do no
<script type="text/javascript">
//<![CDATA[
-try{if (!window.CloudFlare) {var CloudFlare=[{verbose:0,p:0,byc:0,owlid:"cf",bag2:1,mirage2:0,oracle:0,paths:{cloudflare:"/cdn-cgi/nexp/dok7v=02fcfa4f56/"},atok:"cd8a1d333a61e0acb09e330b8081ce01",petok:"45b52215a5393add175e8a2de4f4de5e2d78e750-1392222559-1800",zone:"dashnet.org",rocket:"0",apps:{"ga_key":{"ua":"UA-29324474-2","ga_bs":"2"},"abetterbrowser":{"ie":"8"}}}];var a=document.createElement("script"),b=document.getElementsByTagName("script")[0];a.async=!0;a.src="//ajax.cloudflare.com/cdn-cgi/nexp/dok7v=221574e73d/cloudflare.min.js";b.parentNode.insertBefore(a,b);}}catch(e){};
+try{if (!window.CloudFlare) {var CloudFlare=[{verbose:0,p:1392345132,byc:0,owlid:"cf",bag2:1,mirage2:0,oracle:0,paths:{cloudflare:"/cdn-cgi/nexp/dok8v=02fcfa4f56/"},atok:"d40641166b2975687e97008cce55fa9a",petok:"1ee8ec205f3fa8aea0d5df9bd6a4240d33462cb8-1392361439-1800",zone:"dashnet.org",rocket:"0",apps:{"ga_key":{"ua":"UA-29324474-2","ga_bs":"2"},"abetterbrowser":{"ie":"8"}}}];var a=document.createElement("script"),b=document.getElementsByTagName("script")[0];a.async=!0;a.src="//ajax.cloudflare.com/cdn-cgi/nexp/dok8v=221574e73d/cloudflare.min.js";b.parentNode.insertBefore(a,b);}}catch(e){};
//]]>
</script>
<link rel="shortcut icon" href="favicon.ico" />
<link href="http://fonts.googleapis.com/css?family=Kavoon&subset=latin,latin-ext" rel="stylesheet" type="text/css">
-<link href="style.css?v=1.5070" rel="stylesheet" type="text/css">
+<link href="style.css?v=1.51" rel="stylesheet" type="text/css">
<!--[if lt IE9]><script src="excanvas.compiled.js"></script><![endif]-->
-<script src="phonegap.js"></script><!-- only present in the mobile version -->
<script src="base64.js"></script>
<script src="ajax.js"></script>
<script src="DungeonGen.js"></script>
<script src="dungeons.js?v=1.5044"></script>
-<script src="mobile.js"></script>
-<script src="main.js?v=1.5070"></script>
+<script src="main.js?v=1.511"></script>
<script type="text/javascript">
/* <![CDATA[ */
@@ -80,6 +79,7 @@ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga
<div id="alert"></div>
<div id="particles"></div>
<div id="versionNumber" class="title"></div>
+ <div id="timers"></div>
<div id="sectionLeft" class="inset">
<canvas id="backgroundLeftCanvas" style="z-index:5;"></canvas>
@@ -120,7 +120,7 @@ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga
<div id="support" style="margin-top:130px;">
- <div id="supportComment">Sponsored links</div>
+ <div id="supportComment">Sponsored links</div>
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<!-- Cookie Clicker Rectangle -->
<ins class="adsbygoogle"
diff --git a/list.txt b/list.txt
new file mode 100644
index 0000000..ecdbc60
--- /dev/null
+++ b/list.txt
@@ -0,0 +1,7 @@
+excanvas.compiled.js
+base64.js
+ajax.js
+DungeonGen.js
+dungeons.js
+main.js
+
diff --git a/main.js b/main.js
index 9a6f888..c808b9b 100644
--- a/main.js
+++ b/main.js
@@ -16,7 +16,7 @@ function choose(arr) {return arr[Math.floor(Math.random()*arr.length)];}
realAudio=Audio;//backup real audio
Audio=function(src){
if (src.indexOf('soundjay')>-1) {Game.Popup('Sorry, no sounds hotlinked from soundjay.com.');this.play=function(){};}
- else return realAudio(src);
+ else return new realAudio(src);
};
if(!Array.prototype.indexOf) {
@@ -203,13 +203,18 @@ Loader=function()//asset-loading system
this.doneLoading=0;
this.Load=function(assets)
{
+ var assetsLoaded=[];
for (var i in assets)
{
this.loadingN++;
- var img=new Image();
- img.src=this.domain+assets[i];
- img.onload=bind(this,this.onLoad);
- this.assets[assets[i]]=img;
+ if (!assetsLoaded[assets[i]])
+ {
+ var img=new Image();
+ img.src=this.domain+assets[i];
+ img.onload=bind(this,this.onLoad);
+ this.assets[assets[i]]=img;
+ assetsLoaded[assets[i]]=1;
+ }
}
}
this.onLoad=function()
@@ -241,7 +246,7 @@ Game={};
Game.Launch=function()
{
- Game.version=1.0403;
+ Game.version=1.0411;
Game.beta=0;
Game.mobile=0;
@@ -249,7 +254,9 @@ Game.Launch=function()
'<div class="section">Updates</div>'+
'<div class="subsection">'+
'<div class="title">Now working on :</div>'+
- '<div class="listing">-technical optimization</div>'+
+ '<div class="listing">-founding a game studio</div>'+
+ '<div class="listing">-getting back to the mobile version</div>'+
+ '<div class="listing">-technical optimization <small>(game gets too slow with too many buildings on screen)</small></div>'+
'<div class="listing">-prettifying it up</div>'+
'<div class="listing">-more customization options</div>'+
@@ -258,8 +265,17 @@ Game.Launch=function()
'<div class="listing">-more dungeon stuff!</div>'+
'<div class="listing">-more buildings and upgrades!</div>'+
'<div class="listing">-revamping the prestige system!</div>'+
+ '<div class="listing">-mobile app!</div>'+
'<div class="listing"><span class="warning">Note : this game is updated fairly frequently, which often involves rebalancing. Expect to see prices and cookies/second vary wildly from one update to another!</span></div>'+
+ '</div><div class="subsection update small">'+
+ '<div class="title">14/02/2014 - lovely rainbowcalypse</div>'+
+ '<div class="listing">-new building (it\'s been a while). More to come!</div>'+
+ '<div class="listing">-you can now trigger seasonal events to your heart\'s content (upgrade unlocks at 5000 heavenly chips)</div>'+
+ '<div class="listing">-new ultra-expensive batch of seasonal cookie upgrades you\'ll love to hate</div>'+
+ '<div class="listing">-new timer bars for golden cookie buffs</div>'+
+ '<div class="listing">-buildings are now hidden when you start out and appear as they become available</div>'+
+ '<div class="listing">-technical stuff : the game is now saved through localstorage instead of browser cookies, therefore ruining a perfectly good pun</div>'+
'</div><div class="subsection update small">'+
'<div class="title">22/12/2013 - merry fixmas</div>'+
@@ -441,6 +457,53 @@ Game.Launch=function()
;
Game.ready=0;
+
+
+ /*
+ What we should load in here :
+ -heavy images
+ -images that are displayed on and off (flashing backgrounds etc)
+ -images used in <canvas> stuff
+ */
+ Game.toLoad=[
+ 'perfectCookie.png',
+ 'goldCookie.png',
+ 'wrathCookie.png',
+ 'spookyCookie.png',
+ 'icons.png',
+ 'cookieShower1.png',
+ 'cookieShower2.png',
+ 'cookieShower3.png',
+ 'milkWave.png',
+ 'chocolateMilkWave.png',
+ 'raspberryWave.png',
+ 'orangeWave.png',
+ 'caramelWave.png',
+ 'grandmas1.jpg',
+ 'grandmas2.jpg',
+ 'grandmas3.jpg',
+ 'bgBlue.jpg',
+ 'blackGradient.png',
+ 'shine.png',
+ 'shadedBorders.png',
+ 'shadedBordersRed.png',
+ 'shadedBordersGold.png',
+ 'smallCookies.png',
+ 'cursor.png',
+ 'wrinkler.png',
+ 'winterWrinkler.png',
+ 'wrinklerBits.png',
+ 'grandmaIcon.png',
+ 'grandmaIconB.png',
+ 'grandmaIconC.png',
+ 'grandmaIconD.png',
+ 'santa.png',
+ 'frostedReindeer.png',
+ 'snow2.jpg',
+ 'winterFrame.png',
+ 'hearts.png',
+ 'heartStorm.png'
+ ];
Game.Load=function()
{
@@ -449,50 +512,7 @@ Game.Launch=function()
Game.Loader=new Loader();
Game.Loader.domain='img/';
Game.Loader.loaded=Game.Init;
- /*
- What we should load in here :
- -heavy images
- -images that are displayed on and off (flashing backgrounds etc)
- -images used in <canvas> stuff
- */
- var pics=[
- 'perfectCookie.png',
- 'goldCookie.png',
- 'wrathCookie.png',
- 'spookyCookie.png',
- 'icons.png',
- 'cookieShower1.png',
- 'cookieShower2.png',
- 'cookieShower3.png',
- 'milkWave.png',
- 'chocolateMilkWave.png',
- 'raspberryWave.png',
- 'orangeWave.png',
- 'caramelWave.png',
- 'grandmas1.jpg',
- 'grandmas2.jpg',
- 'grandmas3.jpg',
- 'bgBlue.jpg',
- 'blackGradient.png',
- 'shine.png',
- 'shadedBorders.png',
- 'shadedBordersRed.png',
- 'shadedBordersGold.png',
- 'smallCookies.png',
- 'cursor.png',
- 'wrinkler.png',
- 'winterWrinkler.png',
- 'wrinklerBits.png',
- 'grandmaIcon.png',
- 'grandmaIconB.png',
- 'grandmaIconC.png',
- 'grandmaIconD.png',
- 'santa.png',
- 'frostedReindeer.png',
- 'snow2.jpg',
- 'winterFrame.png'
- ];
- Game.Loader.Load(pics);
+ Game.Loader.Load(Game.toLoad);
Game.Assets=Game.Loader.assets;
}
@@ -507,12 +527,12 @@ Game.Launch=function()
Game.drawT=0;
Game.fps=30;
- Game.season='christmas';//halloween, christmas
+ Game.baseSeason='valentines';//halloween, christmas, valentines
+ Game.season=Game.baseSeason;
if (Game.mobile==1)
{
l('wrapper').className='mobile';
- LaunchMobile();
}
Game.SaveTo='CookieClickerGame';
@@ -533,8 +553,10 @@ Game.Launch=function()
Game.cookiesPs=1;//cookies per second (to recalculate with every new purchase)
Game.cookiesReset=0;//cookies lost to resetting
Game.frenzy=0;//as long as >0, cookie production is multiplied by frenzyPower
+ Game.frenzyMax=0;//how high was our initial burst
Game.frenzyPower=1;
Game.clickFrenzy=0;//as long as >0, mouse clicks get 777x more cookies
+ Game.clickFrenzyMax=0;//how high was our initial burst
Game.cookieClicks=0;//+1 for each click on the cookie
Game.goldenClicks=0;//+1 for each golden cookie clicked (all time)
Game.goldenClicksLocal=0;//+1 for each golden cookie clicked (this game only)
@@ -559,6 +581,8 @@ Game.Launch=function()
Game.wrinklersPopped=0;
Game.santaLevel=0;
Game.reindeerClicked=0;
+ Game.seasonT=0;
+ Game.seasonUses=0;
Game.bg='';//background (grandmas and such)
Game.bgFade='';//fading to background
@@ -569,6 +593,19 @@ Game.Launch=function()
Game.fullDate=parseInt(new Date().getTime());//when we started playing (carries over with resets)
Game.lastDate=parseInt(new Date().getTime());//when we last saved the game (used to compute "cookies made since we closed the game" etc)
+ var timers=['frenzy','elderFrenzy','clot','clickFrenzy'];
+ var str='';
+ for (var i in timers)
+ {
+ str+='<div id="timer-'+timers[i]+'"></div>';
+ }
+ l('timers').innerHTML=str;
+ Game.timersEl=[];
+ for (var i in timers)
+ {
+ Game.timersEl[timers[i]]=l('timer-'+timers[i]);
+ }
+
Game.prefs=[];
Game.DefaultPrefs=function()
{
@@ -626,6 +663,9 @@ Game.Launch=function()
}
}
+ Game.useLocalStorage=1;
+ //window.localStorage.clear();//won't switch back to cookie-based if there is localStorage info
+
/*=====================================================================================
SAVE
=======================================================================================*/
@@ -680,7 +720,10 @@ Game.Launch=function()
parseFloat(Game.cookiesSucked).toString()+';'+
parseInt(Math.floor(Game.wrinklersPopped))+';'+
parseInt(Math.floor(Game.santaLevel))+';'+
- parseInt(Math.floor(Game.reindeerClicked))+
+ parseInt(Math.floor(Game.reindeerClicked))+';'+
+ parseInt(Math.floor(Game.seasonT))+';'+
+ parseInt(Math.floor(Game.seasonUses))+';'+
+ (Game.season)+';'+
'|';//cookies
for (var i in Game.Objects)//buildings
{
@@ -706,7 +749,6 @@ Game.Launch=function()
toCompress=CompressLargeBin(toCompress);
str+=toCompress;
-
if (exporting)
{
str=escape(utf8_to_b64(str)+'!END!');
@@ -714,16 +756,26 @@ Game.Launch=function()
}
else
{
- //that's right
- //we're using cookies
- //yeah I went there
- var now=new Date();//we storin dis for 5 years, people
- now.setFullYear(now.getFullYear()+5);//mmh stale cookies
- str=utf8_to_b64(str)+'!END!';
- Game.saveData=escape(str);
- if (Game.mobile==1) Game.m.writeSaveRequest();//save on mobile
- else
+ if (Game.useLocalStorage)
+ {
+ //so we used to save the game using browser cookies, which was just really neat considering the game's name
+ //we're using localstorage now, which is more efficient but not as cool
+ //a moment of silence for our fallen puns
+ str=utf8_to_b64(str)+'!END!';
+ str=escape(str);
+ window.localStorage.setItem(Game.SaveTo,str);//aaand save
+ if (!window.localStorage.getItem(Game.SaveTo)) Game.Popup('Error while saving.<br>Export your save instead!');
+ else Game.Popup('Game saved');
+ }
+ else//legacy system
{
+ //that's right
+ //we're using cookies
+ //yeah I went there
+ var now=new Date();//we storin dis for 5 years, people
+ now.setFullYear(now.getFullYear()+5);//mmh stale cookies
+ str=utf8_to_b64(str)+'!END!';
+ Game.saveData=escape(str);
str=Game.SaveTo+'='+escape(str)+'; expires='+now.toUTCString()+';';
document.cookie=str;//aaand save
if (document.cookie.indexOf(Game.SaveTo)<0) Game.Popup('Error while saving.<br>Export your save instead!');
@@ -741,8 +793,22 @@ Game.Launch=function()
if (data) str=unescape(data);
else
{
- if (Game.mobile==1) {Game.m.readSaveRequest();return;}//get saved file here
- else {if (document.cookie.indexOf(Game.SaveTo)>=0) str=unescape(document.cookie.split(Game.SaveTo+'=')[1]);}//get cookie here
+ if (Game.useLocalStorage)
+ {
+ var localStorage=window.localStorage.getItem(Game.SaveTo);
+ if (!localStorage)//no localstorage save found ? let's get the cookie one last time
+ {
+ if (document.cookie.indexOf(Game.SaveTo)>=0) str=unescape(document.cookie.split(Game.SaveTo+'=')[1]);
+ }
+ else
+ {
+ str=unescape(localStorage);
+ }
+ }
+ else//legacy system
+ {
+ if (document.cookie.indexOf(Game.SaveTo)>=0) str=unescape(document.cookie.split(Game.SaveTo+'=')[1]);//get cookie here
+ }
}
if (str!='')
@@ -801,6 +867,9 @@ Game.Launch=function()
Game.wrinklersPopped=spl[17]?parseInt(spl[17]):0;
Game.santaLevel=spl[18]?parseInt(spl[18]):0;
Game.reindeerClicked=spl[19]?parseInt(spl[19]):0;
+ Game.seasonT=spl[20]?parseInt(spl[20]):0;
+ Game.seasonUses=spl[21]?parseInt(spl[21]):0;
+ Game.season=spl[22]?spl[22]:Game.baseSeason;
spl=str[5].split(';');//buildings
Game.BuildingsOwned=0;
for (var i in Game.ObjectsById)
@@ -814,7 +883,7 @@ Game.Launch=function()
}
else
{
- me.unlocked=0;me.bought=0;me.totalCookies=0;
+ me.amount=0;me.unlocked=0;me.bought=0;me.totalCookies=0;
}
}
if (version<1.035)//old non-binary algorithm
@@ -915,6 +984,8 @@ Game.Launch=function()
Game.santaLevel=0;
Game.reindeerClicked=0;
*/
+ //recompute season trigger prices
+ Game.computeSeasonPrices();
Game.CalculateGains();
@@ -983,7 +1054,9 @@ Game.Launch=function()
Game.elderWrathD=0;
Game.frenzy=0;
Game.frenzyPower=1;
+ Game.frenzyMax=0;
Game.clickFrenzy=0;
+ Game.clickFrenzyMax=0;
Game.recalculateGains=1;
Game.storeToRebuild=1;
Game.upgradesToRebuild=1;
@@ -1020,12 +1093,18 @@ Game.Launch=function()
Game.milkType=-1;
Game.frenzy=0;
Game.frenzyPower=1;
+ Game.frenzyMax=0;
Game.clickFrenzy=0;
+ Game.clickFrenzyMax=0;
Game.pledges=0;
Game.pledgeT=0;
Game.elderWrath=0;
Game.nextResearch=0;
Game.researchT=0;
+ Game.seasonT=0;
+ Game.seasonUses=0;
+ Game.season=Game.baseSeason;
+ Game.computeSeasonPrices();
Game.startDate=parseInt(new Date().getTime());
Game.lastDate=parseInt(new Date().getTime());
@@ -1346,7 +1425,8 @@ Game.Launch=function()
if (this.time<this.minTime || this.life>0) Game.Win('Cheated cookies taste awful');
var me=l('goldenCookie');
- if ((Game.elderWrath==1 && Math.random()<0.33) || (Game.elderWrath==2 && Math.random()<0.66) || (Game.elderWrath==3))
+ me.style.backgroundPosition='0px 0px';
+ if ((Game.elderWrath==1 && Math.random()<1/3) || (Game.elderWrath==2 && Math.random()<2/3) || (Game.elderWrath==3))
{
this.wrath=1;
if (Game.season=='halloween') me.style.background='url(img/spookyCookie.png)';
@@ -1360,6 +1440,13 @@ Game.Launch=function()
//fancy visual stuff
var r=Math.floor(Math.random()*360);
if (Game.season=='halloween' && this.wrath) r=Math.floor(Math.random()*36-18);
+ if (Game.season=='valentines')
+ {
+ me.style.background='url(img/hearts.png)';
+ me.style.backgroundPosition=-(Math.floor(Math.random()*8)*96)+'px 0px';
+ r=Math.floor(Math.random()*36-18);
+ if (this.wrath) r+=180;
+ }
me.style.transform='rotate('+r+'deg)';
me.style.mozTransform='rotate('+r+'deg)';
me.style.webkitTransform='rotate('+r+'deg)';
@@ -1405,7 +1492,7 @@ Game.Launch=function()
if (this.wrath>0) list.push('clot','multiply cookies','ruin cookies');
else list.push('frenzy','multiply cookies');
if (this.wrath>0 && Math.random()<0.3) list.push('blood frenzy','chain cookie');
- else if (Math.random()<0.01 && Game.cookiesEarned>=100000) list.push('chain cookie');
+ else if (Math.random()<0.03 && Game.cookiesEarned>=100000) list.push('chain cookie');
if (Math.random()<0.1) list.push('click frenzy');
if (this.last!='' && Math.random()<0.8 && list.indexOf(this.last)!=-1) list.splice(list.indexOf(this.last),1);//80% chance to force a different one
if (Math.random()<0.0001) list.push('blab');
@@ -1446,6 +1533,7 @@ Game.Launch=function()
var time=77+77*Game.Has('Get lucky');
Game.frenzy=Game.fps*time;
Game.frenzyPower=7;
+ Game.frenzyMax=Game.frenzy;
Game.recalculateGains=1;
Game.Popup('Frenzy : cookie production x7 for '+time+' seconds!');
}
@@ -1467,6 +1555,7 @@ Game.Launch=function()
var time=6+6*Game.Has('Get lucky');
Game.frenzy=Game.fps*time;//*2;//we shouldn't need *2 but I keep getting reports of it lasting only 3 seconds
Game.frenzyPower=666;
+ Game.frenzyMax=Game.frenzy;
Game.recalculateGains=1;
Game.Popup('Elder frenzy : cookie production x666 for '+time+' seconds!');
}
@@ -1475,6 +1564,7 @@ Game.Launch=function()
var time=66+66*Game.Has('Get lucky');
Game.frenzy=Game.fps*time;
Game.frenzyPower=0.5;
+ Game.frenzyMax=Game.frenzy;
Game.recalculateGains=1;
Game.Popup('Clot : cookie production halved for '+time+' seconds!');
}
@@ -1482,6 +1572,7 @@ Game.Launch=function()
{
var time=13+13*Game.Has('Get lucky');
Game.clickFrenzy=Game.fps*time;
+ Game.clickFrenzyMax=Game.clickFrenzy;
Game.recalculateGains=1;
Game.Popup('Click frenzy! Clicking power x777 for '+time+' seconds!');
}
@@ -1636,7 +1727,7 @@ Game.Launch=function()
if (Game.Has('Santa\'s bottomless bag')) failRate*=0.9;
if (Math.random()>failRate)//christmas cookie drops
{
- cookie=choose(['Christmas tree biscuits','Snowflake biscuits','Snowman biscuits','Mistletoe biscuits','Candy cane biscuits','Bell biscuits','Present biscuits']);
+ cookie=choose(['Christmas tree biscuits','Snowflake biscuits','Snowman biscuits','Holly biscuits','Candy cane biscuits','Bell biscuits','Present biscuits']);
if (!Game.HasUnlocked(cookie) && !Game.Has(cookie))
{
Game.Unlock(cookie);
@@ -2122,10 +2213,10 @@ Game.Launch=function()
}
var milkName='plain milk';
- if (Game.milkProgress>=4.5) milkName='caramel milk';
- else if (Game.milkProgress>=3.5) milkName='orange juice';
- else if (Game.milkProgress>=2.5) milkName='raspberry milk';
- else if (Game.milkProgress>=1.5) milkName='chocolate milk';
+ if (Game.milkProgress>=4) milkName='caramel milk';
+ else if (Game.milkProgress>=3) milkName='orange juice';
+ else if (Game.milkProgress>=2) milkName='raspberry milk';
+ else if (Game.milkProgress>=1) milkName='chocolate milk';
var researchStr=Game.sayTime(Game.researchT);
var pledgeStr=Game.sayTime(Game.pledgeT);
@@ -2151,6 +2242,9 @@ Game.Launch=function()
if (Game.Has('Heavenly confectionery')) heavenlyMult+=25;
if (Game.Has('Heavenly key')) heavenlyMult+=25;
+ var seasons={'halloween':'Halloween','christmas':'Christmas','valentines':'Valentine\'s day'};
+ var seasonStr=Game.sayTime(Game.seasonT);
+
str+='<div class="section">Statistics</div>'+
'<div class="subsection">'+
'<div class="title">General</div>'+
@@ -2171,9 +2265,12 @@ Game.Launch=function()
'<div class="listing"><b>Golden cookie clicks :</b> '+Beautify(Game.goldenClicksLocal)+' (all time : '+Beautify(Game.goldenClicks)+')</div>'+//' <span class="hidden">(<b>Missed golden cookies :</b> '+Beautify(Game.missedGoldenClicks)+')</span></div>'+
'<br><div class="listing"><b>Running version :</b> '+Game.version+'</div>'+
- ((researchStr!='' || wrathStr!='' || pledgeStr!='' || santaStr!='')?(
+ ((researchStr!='' || wrathStr!='' || pledgeStr!='' || santaStr!='' || Game.season!='')?(
'</div><div class="subsection">'+
'<div class="title">Special</div>'+
+ (Game.season!=''?'<div class="listing"><b>Seasonal event :</b> '+seasons[Game.season]+
+ (seasonStr!=''?' <small>('+seasonStr+' remaining)</small>':'')+
+ '</div>':'')+
(researchStr!=''?'<div class="listing"><b>Research :</b> '+researchStr+' remaining</div>':'')+
(wrathStr!=''?'<div class="listing"><b>Grandmatriarchs status :</b> '+wrathStr+'</div>':'')+
(pledgeStr!=''?'<div class="listing"><b>Pledge :</b> '+pledgeStr+' remaining</div>':'')+
@@ -2188,7 +2285,7 @@ Game.Launch=function()
'</div><div class="subsection">'+
'<div class="title">Prestige</div>'+
'<div class="listing"><small>(Note : each heavenly chip grants you +2% CpS multiplier. You can gain more chips by resetting with a lot of cookies.)</small></div>'+
- '<div class="listing"><div class="icon" style="background-position:'+(-19*48)+'px '+(-7*48)+'px;"></div> <span style="vertical-align:100%;"><span class="title" style="font-size:22px;">'+Game.prestige['Heavenly chips']+' heavenly chip'+(Game.prestige['Heavenly chips']==1?'':'s')+'</span> at '+heavenlyMult+'% of their potential (+'+Beautify(Game.prestige['Heavenly chips']*2*heavenlyMult/100,1)+'% CpS)</span></div>'):'')+
+ '<div class="listing"><div class="icon" style="background-position:'+(-19*48)+'px '+(-7*48)+'px;"></div> <span style="vertical-align:100%;"><span class="title" style="font-size:22px;">'+Beautify(Game.prestige['Heavenly chips'])+' heavenly chip'+(Game.prestige['Heavenly chips']==1?'':'s')+'</span> at '+heavenlyMult+'% of their potential (+'+Beautify(Game.prestige['Heavenly chips']*2*heavenlyMult/100,1)+'% CpS)</span></div>'):'')+
'</div><div class="subsection">'+
'<div class="title">Upgrades unlocked</div>'+
@@ -2388,6 +2485,14 @@ Game.Launch=function()
'News : "unravelling the fabric of reality just makes these cookies so much tastier", claims scientist.'
]));
+ if (Game.Objects['Prism'].amount>0) list.push(choose([
+ 'News : new cookie-producing prisms linked to outbreak of rainbow-related viral videos.',
+ 'News : scientists warn against systematically turning light into matter - "One day, we\'ll end up with all matter and no light!"',
+ 'News : cookies now being baked at the literal speed of light thanks to new prismatic contraptions.',
+ 'News : "Can\'t you sense the prism watching us?", rambles insane local man. "No idea what he\'s talking about", shrugs cookie magnate/government official.',
+ 'News : world citizens advised "not to worry" about frequent atmospheric flashes.',
+ ]));
+
if (Game.season=='halloween' && Game.cookiesEarned>=1000) list.push(choose([
'News : strange twisting creatures amass around cookie factories, nibble at assembly lines.',
'News : ominous wrinkly monsters take massive bites out of cookie production; "this can\'t be hygienic", worries worker.',
@@ -2411,10 +2516,18 @@ Game.Launch=function()
'News : drama unfolds at North Pole as rumors crop up around Rudolph\'s red nose; "I may have an addiction or two", admits reindeer.'
]));
- if (Game.HasAchiev('Base 10')) list.push('News : cookie manufacturer completely forgoes common sense, lets OCD drive building decisions!');
+ if (Game.season=='valentines' && Game.cookiesEarned>=1000) list.push(choose([
+ 'News : organ-shaped confectioneries being traded in schools all over the world; gruesome practice undergoing investigation.',
+ 'News : heart-shaped candies overtaking sweets business, offering competition to cookie empire. "It\'s the economy, cupid!"',
+ 'News : love\'s in the air, according to weather specialists. Face masks now offered in every city to stunt airborne infection.',
+ 'News : marrying a cookie - deranged practice, or glimpse of the future?',
+ 'News : boyfriend dumped after offering his lover cookies for Valentine\'s Day, reports say. "They were off-brand", shrugs ex-girlfriend.'
+ ]));
+
+ if (Game.HasAchiev('Base 10')) list.push('News : cookie manufacturer completely forgoes common sense, lets OCD drive building decisions!');//somehow I got flak for this one
if (Game.HasAchiev('From scratch')) list.push('News : follow the tear-jerking, riches-to-rags story about a local cookie manufacturer who decided to give it all up!');
if (Game.HasAchiev('A world filled with cookies')) list.push('News : known universe now jammed with cookies! No vacancies!');
- if (Game.HasAchiev('Serendipity')) list.push('News : local cookie manufacturer becomes luckiest being alive!');
+ if (Game.Has('Serendipity')) list.push('News : local cookie manufacturer becomes luckiest being alive!');
if (Game.Has('Kitten helpers')) list.push('News : faint meowing heard around local cookie facilities; suggests new ingredient being tested.');
if (Game.Has('Kitten workers')) list.push('News : crowds of meowing kittens with little hard hats reported near local cookie facilities.');
@@ -2762,14 +2875,21 @@ Game.Launch=function()
Game.RebuildStore=function()//redraw the store from scratch
{
+ var lastLocked=0;
Game.RefreshBuildings();
var str='';
for (var i in Game.Objects)
{
var me=Game.Objects[i];
- str+='<div class="product" '+Game.getTooltip(
+ var classes='product';
+ var price=me.price;
+ if (Game.cookiesEarned>=price) {classes+=' unlocked';lastLocked=0;} else {classes+=' locked';lastLocked++;}
+ if (Game.cookies>=price) classes+=' enabled'; else classes+=' disabled';
+ if (lastLocked>1) classes+=' toggledOff';
+
+ str+='<div class="'+classes+'" '+(lastLocked==0?Game.getTooltip(
'<div style="min-width:300px;"><div style="float:right;"><span class="price">'+Beautify(Math.round(me.price))+'</span></div><div class="name">'+me.name+'</div>'+'<small>[owned : '+me.amount+'</small>]<div class="description">'+me.desc+'</div></div>'
- ,'left')+' id="product'+me.id+'"><div class="icon" id="productIcon'+me.id+'" style="background-image:url(img/'+me.icon+'.png);"></div><div class="content"><div class="title">'+me.displayName+'</div><span class="price">'+Beautify(Math.round(me.price))+'</span>'+(me.amount>0?('<div class="title owned">'+me.amount+'</div>'):'')+'</div></div>';
+ ,'left'):'')+' id="product'+me.id+'"><div class="icon off" id="productIconOff'+me.id+'" style="background-image:url(img/'+me.icon+'Off.png);"></div><div class="icon" id="productIcon'+me.id+'" style="background-image:url(img/'+me.icon+'.png);"></div><div class="content"><div class="title">'+me.displayName+'</div><span class="price">'+Beautify(Math.round(me.price))+'</span>'+(me.amount>0?('<div class="title owned">'+me.amount+'</div>'):'')+'</div></div>';
}
l('products').innerHTML=str;
for (var i in Game.Objects)
@@ -2843,6 +2963,7 @@ Game.Launch=function()
if (Game.Has('Altered grandmas')) mult++;
if (Game.Has('Grandmas\' grandmas')) mult++;
if (Game.Has('Antigrandmas')) mult++;
+ if (Game.Has('Rainbow grandmas')) mult++;
if (Game.Has('Bingo center/Research facility')) mult+=2;
if (Game.Has('Ritual rolling pins')) mult++;
if (Game.Has('Naughty list')) mult++;
@@ -2861,6 +2982,7 @@ Game.Launch=function()
if (Game.Has('Altered grandmas')) list.push('alteredGrandma');
if (Game.Has('Grandmas\' grandmas')) list.push('grandmasGrandma');
if (Game.Has('Antigrandmas')) list.push('antiGrandma');
+ if (Game.Has('Rainbow grandmas')) list.push('rainbowGrandma');
if (Game.season=='christmas') list.push('elfGrandma');
return choose(list);
},8,8,32,3,16),function(){
@@ -2885,7 +3007,7 @@ Game.Launch=function()
},Game.NewDrawFunction(0,16,16,64,2,32),function(){
if (this.amount>=1) Game.Unlock(['Cheap hoes','Fertilizer']);if (this.amount>=10) Game.Unlock('Cookie trees');if (this.amount>=50) Game.Unlock('Genetically-modified cookies');if (this.amount>=100) Game.Unlock('Gingerbread scarecrows');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Farmer grandmas');
- if (this.amount>=1) Game.Win('My first farm');if (this.amount>=50) Game.Win('Reap what you sow');if (this.amount>=100) Game.Win('Farm ill');
+ if (this.amount>=1) Game.Win('My first farm');if (this.amount>=50) Game.Win('Reap what you sow');if (this.amount>=100) Game.Win('Farm ill');if (this.amount>=150) Game.Win('Perfected agriculture');
});
new Game.Object('Factory','factory|factories|mass-produced','Produces large quantities of cookies.','factory','factoryIcon','factoryBackground',3000,function(){
@@ -2893,7 +3015,7 @@ Game.Launch=function()
},Game.NewDrawFunction(0,32,2,64,1,-22),function(){
if (this.amount>=1) Game.Unlock(['Sturdier conveyor belts','Child labor']);if (this.amount>=10) Game.Unlock('Sweatshop');if (this.amount>=50) Game.Unlock('Radium reactors');if (this.amount>=100) Game.Unlock('Recombobulators');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Worker grandmas');
- if (this.amount>=1) Game.Win('Production chain');if (this.amount>=50) Game.Win('Industrial revolution');if (this.amount>=100) Game.Win('Global warming');
+ if (this.amount>=1) Game.Win('Production chain');if (this.amount>=50) Game.Win('Industrial revolution');if (this.amount>=100) Game.Win('Global warming');if (this.amount>=150) Game.Win('Ultimate automation');
});
new Game.Object('Mine','mine|mines|mined','Mines out cookie dough and chocolate chips.','mine','mineIcon','mineBackground',10000,function(){
@@ -2901,7 +3023,7 @@ Game.Launch=function()
},Game.NewDrawFunction(0,16,16,64,2,24),function(){
if (this.amount>=1) Game.Unlock(['Sugar gas','Megadrill']);if (this.amount>=10) Game.Unlock('Ultradrill');if (this.amount>=50) Game.Unlock('Ultimadrill');if (this.amount>=100) Game.Unlock('H-bomb mining');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Miner grandmas');
- if (this.amount>=1) Game.Win('You know the drill');if (this.amount>=50) Game.Win('Excavation site');if (this.amount>=100) Game.Win('Hollow the planet');
+ if (this.amount>=1) Game.Win('You know the drill');if (this.amount>=50) Game.Win('Excavation site');if (this.amount>=100) Game.Win('Hollow the planet');if (this.amount>=150) Game.Win('Can you dig it');
});
new Game.Object('Shipment','shipment|shipments|shipped','Brings in fresh cookies from the cookie planet.','shipment','shipmentIcon','shipmentBackground',40000,function(){
@@ -2909,7 +3031,7 @@ Game.Launch=function()
},Game.NewDrawFunction(0,16,16,64),function(){
if (this.amount>=1) Game.Unlock(['Vanilla nebulae','Wormholes']);if (this.amount>=10) Game.Unlock('Frequent flyer');if (this.amount>=50) Game.Unlock('Warp drive');if (this.amount>=100) Game.Unlock('Chocolate monoliths');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Cosmic grandmas');
- if (this.amount>=1) Game.Win('Expedition');if (this.amount>=50) Game.Win('Galactic highway');if (this.amount>=100) Game.Win('Far far away');
+ if (this.amount>=1) Game.Win('Expedition');if (this.amount>=50) Game.Win('Galactic highway');if (this.amount>=100) Game.Win('Far far away');if (this.amount>=150) Game.Win('Type II civilization');
});
new Game.Object('Alchemy lab','alchemy lab|alchemy labs|transmuted','Turns gold into cookies!','alchemylab','alchemylabIcon','alchemylabBackground',200000,function(){
@@ -2917,7 +3039,7 @@ Game.Launch=function()
},Game.NewDrawFunction(0,16,16,64,2,16),function(){
if (this.amount>=1) Game.Unlock(['Antimony','Essence of dough']);if (this.amount>=10) Game.Unlock('True chocolate');if (this.amount>=50) Game.Unlock('Ambrosia');if (this.amount>=100) Game.Unlock('Aqua crustulae');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Transmuted grandmas');
- if (this.amount>=1) Game.Win('Transmutation');if (this.amount>=50) Game.Win('Transmogrification');if (this.amount>=100) Game.Win('Gold member');
+ if (this.amount>=1) Game.Win('Transmutation');if (this.amount>=50) Game.Win('Transmogrification');if (this.amount>=100) Game.Win('Gold member');if (this.amount>=150) Game.Win('Gild wars');
});
new Game.Object('Portal','portal|portals|retrieved','Opens a door to the Cookieverse.','portal','portalIcon','portalBackground',1666666,function(){
@@ -2925,23 +3047,30 @@ Game.Launch=function()
},Game.NewDrawFunction(0,32,32,64,2),function(){
if (this.amount>=1) Game.Unlock(['Ancient tablet','Insane oatling workers']);if (this.amount>=10) Game.Unlock('Soul bond');if (this.amount>=50) Game.Unlock('Sanity dance');if (this.amount>=100) Game.Unlock('Brane transplant');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Altered grandmas');
- if (this.amount>=1) Game.Win('A whole new world');if (this.amount>=50) Game.Win('Now you\'re thinking');if (this.amount>=100) Game.Win('Dimensional shift');
+ if (this.amount>=1) Game.Win('A whole new world');if (this.amount>=50) Game.Win('Now you\'re thinking');if (this.amount>=100) Game.Win('Dimensional shift');if (this.amount>=150) Game.Win('Brain-split');
});
new Game.Object('Time machine','time machine|time machines|recovered','Brings cookies from the past, before they were even eaten.','timemachine','timemachineIcon','timemachineBackground',123456789,function(){
return Game.ComputeCps(98765,Game.Has('Flux capacitors')*9876,Game.Has('Time paradox resolver')+Game.Has('Quantum conundrum')+Game.Has('Causality enforcer')+Game.Has('Yestermorrow comparators'));
},Game.NewDrawFunction(0,32,32,64,1),function(){
if (this.amount>=1) Game.Unlock(['Flux capacitors','Time paradox resolver']);if (this.amount>=10) Game.Unlock('Quantum conundrum');if (this.amount>=50) Game.Unlock('Causality enforcer');if (this.amount>=100) Game.Unlock('Yestermorrow comparators');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Grandmas\' grandmas');
- if (this.amount>=1) Game.Win('Time warp');if (this.amount>=50) Game.Win('Alternate timeline');if (this.amount>=100) Game.Win('Rewriting history');
+ if (this.amount>=1) Game.Win('Time warp');if (this.amount>=50) Game.Win('Alternate timeline');if (this.amount>=100) Game.Win('Rewriting history');if (this.amount>=150) Game.Win('Time duke');
});
new Game.Object('Antimatter condenser','antimatter condenser|antimatter condensers|condensed','Condenses the antimatter in the universe into cookies.','antimattercondenser','antimattercondenserIcon','antimattercondenserBackground',3999999999,function(){
return Game.ComputeCps(999999,Game.Has('Sugar bosons')*99999,Game.Has('String theory')+Game.Has('Large macaron collider')+Game.Has('Big bang bake')+Game.Has('Reverse cyclotrons'));
},Game.NewDrawFunction(0,0,64,64,1),function(){
if (this.amount>=1) Game.Unlock(['Sugar bosons','String theory']);if (this.amount>=10) Game.Unlock('Large macaron collider');if (this.amount>=50) Game.Unlock('Big bang bake');if (this.amount>=100) Game.Unlock('Reverse cyclotrons');
if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Antigrandmas');
- if (this.amount>=1) Game.Win('Antibatter');if (this.amount>=50) Game.Win('Quirky quarks');if (this.amount>=100) Game.Win('It does matter!');
+ if (this.amount>=1) Game.Win('Antibatter');if (this.amount>=50) Game.Win('Quirky quarks');if (this.amount>=100) Game.Win('It does matter!');if (this.amount>=150) Game.Win('Molecular maestro');
});
Game.Objects['Antimatter condenser'].displayName='<span style="font-size:65%;">Antimatter condenser</span>';//shrink the name since it's so large
+ new Game.Object('Prism','prism|prisms|converted','Converts light itself into cookies.','prism','prismIcon','prismBackground',50000000000,function(){
+ return Game.ComputeCps(10000000,Game.Has('Gem polish')*1000000,Game.Has('9th color')+Game.Has('Chocolate light')+Game.Has('Grainbow')+Game.Has('Pure cosmic light'));
+ },Game.NewDrawFunction(0,16,4,64,1,20),function(){
+ if (this.amount>=1) Game.Unlock(['Gem polish','9th color']);if (this.amount>=10) Game.Unlock('Chocolate light');if (this.amount>=50) Game.Unlock('Grainbow');if (this.amount>=100) Game.Unlock('Pure cosmic light');
+ if (this.amount>=Game.SpecialGrandmaUnlock && Game.Objects['Grandma'].amount>0) Game.Unlock('Rainbow grandmas');
+ if (this.amount>=1) Game.Win('Lone photon');if (this.amount>=50) Game.Win('Dazzling glimmer');if (this.amount>=100) Game.Win('Blinding flash');if (this.amount>=150) Game.Win('Unending glow');
+ });
/*=====================================================================================
UPGRADES
@@ -3426,7 +3555,7 @@ Game.Launch=function()
new Game.Upgrade('Christmas tree biscuits','Cookie production multiplier <b>+20%</b>.<q>Whose pine is it anyway?</q>',252525252525,[12,10]);
new Game.Upgrade('Snowflake biscuits','Cookie production multiplier <b>+20%</b>.<q>Mass-produced to be unique in every way.</q>',252525252525,[13,10]);
new Game.Upgrade('Snowman biscuits','Cookie production multiplier <b>+20%</b>.<q>It\'s frosted. Doubly so.</q>',252525252525,[14,10]);
- new Game.Upgrade('Mistletoe biscuits','Cookie production multiplier <b>+20%</b>.<q>An acceptable smooching catalyst. Botanically, this is a smellier variant of the mistlefinger.</q>',252525252525,[15,10]);
+ new Game.Upgrade('Holly biscuits','Cookie production multiplier <b>+20%</b>.<q>You don\'t smooch under these ones. That would be the mistletoe (which, botanically, is a smellier variant of the mistlefinger).</q>',252525252525,[15,10]);
new Game.Upgrade('Candy cane biscuits','Cookie production multiplier <b>+20%</b>.<q>It\'s two treats in one!<br>(Further inspection reveals the frosting does not actually taste like peppermint, but like mundane sugary frosting.)</q>',252525252525,[16,10]);
new Game.Upgrade('Bell biscuits','Cookie production multiplier <b>+20%</b>.<q>What do these even have to do with christmas? Who cares, ring them in!</q>',252525252525,[17,10]);
new Game.Upgrade('Present biscuits','Cookie production multiplier <b>+20%</b>.<q>The prequel to future biscuits. Watch out!</q>',252525252525,[18,10]);
@@ -3458,7 +3587,7 @@ Game.Launch=function()
new Game.Upgrade('Naughty list','Grandmas are <b>twice</b> as productive.<q>This list contains every unholy deed perpetuated by grandmakind.<br>He won\'t be checking this one twice.<br>Once. Once is enough.</q>',2525,[15,9]);
new Game.Upgrade('Santa\'s bottomless bag','Random drops are <b>10% more common</b>.<q>This is one bottom you can\'t check out.</q>',2525,[19,9]);
new Game.Upgrade('Santa\'s helpers','Clicking is <b>10% more powerful</b>.<q>Some choose to help hamburger; some choose to help you.<br>To each their own, I guess.</q>',2525,[19,9]);
- new Game.Upgrade('Santa\'s legacy','Cookie production multiplier <b>+10% per Santa\'s levels</b>.<q>In the north pole, you gotta get the gnomes first. Then when you get the gnomes, you start making the toys. Then when you get the toys... then you get the cookies.</q>',2525,[19,9]);
+ new Game.Upgrade('Santa\'s legacy','Cookie production multiplier <b>+10% per Santa\'s levels</b>.<q>In the north pole, you gotta get the elves first. Then when you get the elves, you start making the toys. Then when you get the toys... then you get the cookies.</q>',2525,[19,9]);
new Game.Upgrade('Santa\'s milk and cookies','Milk is <b>5% more powerful</b>.<q>Part of Santa\'s dreadfully unbalanced diet.</q>',2525,[19,9]);
order=40000;
@@ -3466,7 +3595,60 @@ Game.Launch=function()
Game.Upgrades['Reindeer season'].hide=3;Game.Upgrades['Reindeer season'].debug=1;
order=25000;
- new Game.Upgrade('Santa\'s dominion','Cookie production multiplier <b>+50%</b>.<br>All buildings are <b>1% cheaper</b>.<br>All upgrades are <b>2% cheaper</b>.<q>My name is Claus, king of kings;<br>Look on my toys, ye Mighty, and despair!</q>',2525252525252525,[19,10]);
+ new Game.Upgrade('Santa\'s dominion','Cookie production multiplier <b>+50%</b>.<br>All buildings are <b>1% cheaper</b>.<br>All upgrades are <b>2% cheaper</b>.<q>My name is Claus, king of kings;<br>Look on my toys, ye Mighty, and despair!</q>',2525252525252525,[19,10],function(){Game.RefreshBuildings();});
+
+ order=10300;
+ type='cookie';power=25;
+ new Game.Upgrade('Pure heart biscuits','Cookie production multiplier <b>+25%</b>.<q>Melty white chocolate<br>that says "I *like* like you".</q>',9999999999999999,[19,3]);
+ new Game.Upgrade('Ardent heart biscuits','Cookie production multiplier <b>+25%</b>.<q>A red hot cherry biscuit that will nudge the target of your affection in interesting directions.</q>',9999999999999999,[20,3]);
+ new Game.Upgrade('Sour heart biscuits','Cookie production multiplier <b>+25%</b>.<q>A bitter lime biscuit for the lonely and the heart-broken.</q>',9999999999999999,[20,4]);
+ new Game.Upgrade('Weeping heart biscuits','Cookie production multiplier <b>+25%</b>.<q>An ice-cold blueberry biscuit, symbol of a mending heart.</q>',9999999999999999,[21,3]);
+ new Game.Upgrade('Golden heart biscuits','Cookie production multiplier <b>+25%</b>.<q>A beautiful biscuit to symbolize kindness, true love, and sincerity.</q>',9999999999999999,[21,4]);
+ new Game.Upgrade('Eternal heart biscuits','Cookie production multiplier <b>+25%</b>.<q>Silver icing for a very special someone you\'ve liked for a long, long time.</q>',9999999999999999,[19,4]);
+ type='';power=0;
+
+ order=1100;
+ new Game.Upgrade('Gem polish','Prisms gain <b>+1,000,000</b> base CpS.<q>Get rid of the grime and let more light in.<br>Truly, truly outrageous.</q>',Game.Objects['Prism'].basePrice*tier1,[14,0]);
+ new Game.Upgrade('9th color','Prisms are <b>twice</b> as efficient.<q>Delve into untouched optical depths where even the mantis shrimp hasn\'t set an eye!</q>',Game.Objects['Prism'].basePrice*tier2,[14,0]);
+ new Game.Upgrade('Chocolate light','Prisms are <b>twice</b> as efficient.<q>Bask into its cocoalescence.<br>(Warning : may cause various interesting albeit deadly skin conditions.)</q>',Game.Objects['Prism'].basePrice*tier3,[14,1]);
+ new Game.Upgrade('Grainbow','Prisms are <b>twice</b> as efficient.<q>Remember the different grains using the handy Roy G. Biv mnemonic : R is for rice, O is for oats... uh, B for barley?...</q>',Game.Objects['Prism'].basePrice*tier4,[14,2]);
+ new Game.Upgrade('Pure cosmic light','Prisms are <b>twice</b> as efficient.<q>Your prisms now receive pristine, unadulterated photons from the other end of the universe.</q>',Game.Objects['Prism'].basePrice*tier5,[14,13]);
+
+ order=250;
+ new Game.Upgrade('Rainbow grandmas','Grandmas are <b>twice</b> as efficient.<q>A luminous grandma to sparkle into cookies.</q>',Game.Objects['Prism'].basePrice*tier2,[10,9],function(){Game.Objects['Grandma'].drawFunction();});
+
+ order=24000;
+ Game.seasonTriggerBasePrice=33333333333;
+ Game.computeSeasonPrices=function()
+ {
+ for (var i in Game.seasonTriggers)
+ {
+ Game.Upgrades[Game.seasonTriggers[i]].basePrice=Game.seasonTriggerBasePrice*Math.pow(10,Game.seasonUses);
+ }
+ }
+ new Game.Upgrade('Season switcher','Allows you to <b>trigger seasonal events</b> at will, for a price.<q>There will always be time.</q>',3333333333333,[16,6],function(){for (var i in Game.seasonTriggers){Game.Unlock(Game.seasonTriggers[i]);}});
+ new Game.Upgrade('Festive biscuit','Triggers <b>Christmas season</b> for the next 24 hours.<br>Triggering another season will cancel this one.<q>\'Twas the night before Christmas- or was it?</q>',Game.seasonTriggerBasePrice,[12,10]);Game.Upgrades['Festive biscuit'].season='christmas';
+ new Game.Upgrade('Ghostly biscuit','Triggers <b>Halloween season</b> for the next 24 hours.<br>Triggering another season will cancel this one.<q>spooky scary skeletons<br>will wake you with a boo</q>',Game.seasonTriggerBasePrice,[13,8]);Game.Upgrades['Ghostly biscuit'].season='halloween';
+ new Game.Upgrade('Lovesick biscuit','Triggers <b>Valentine\'s Day season</b> for the next 24 hours.<br>Triggering another season will cancel this one.<q>Romance never goes out of fashion.</q>',Game.seasonTriggerBasePrice,[20,3]);Game.Upgrades['Lovesick biscuit'].season='valentines';
+ Game.seasonTriggers=['Festive biscuit','Ghostly biscuit','Lovesick biscuit'];
+ for (var i in Game.seasonTriggers)
+ {
+ var me=Game.Upgrades[Game.seasonTriggers[i]];
+ me.hide=3;
+ me.buyFunction=function()
+ {
+ Game.seasonUses+=1;
+ Game.computeSeasonPrices();
+ Game.Lock(this.name);
+ for (var i in Game.seasonTriggers)
+ {
+ var me=Game.Upgrades[Game.seasonTriggers[i]];
+ if (me.name!=this.name) Game.Unlock(me.name);
+ }
+ if (this.season) Game.season=this.season;
+ Game.seasonT=Game.fps*60*60*24;
+ }
+ }
/*
//I really should release these someday
@@ -3482,6 +3664,7 @@ Game.Launch=function()
new Game.Upgrade('Black background','Unlocks the <b>black background</b>, available in the menu.',120000000000,[3,8]);
*/
+
//new Game.Upgrade('Golden switch','Unlocks the <b>Golden switch</b>, available in the menu.<br>When active, the Golden switch grants you a passive CpS boost, but prevents golden cookies from spawning.',77777777777,[10,1]);
/*=====================================================================================
@@ -3751,7 +3934,38 @@ Game.Launch=function()
new Game.Achievement('Sleigh of hand','Pop <b>50 reindeer</b>.',[12,9],2);
new Game.Achievement('Reindeer sleigher','Pop <b>200 reindeer</b>.',[12,9],2);
+ order=1200;
+ new Game.Achievement('Perfected agriculture','Have <b>150</b> farms.',[2,13]);
+ order=1300;
+ new Game.Achievement('Ultimate automation','Have <b>150</b> factories.',[4,13]);
+ order=1400;
+ new Game.Achievement('Can you dig it','Have <b>150</b> mines.',[3,13]);
+ order=1500;
+ new Game.Achievement('Type II civilization','Have <b>150</b> shipments.',[5,13]);
+ order=1600;
+ new Game.Achievement('Gild wars','Have <b>150</b> alchemy labs.',[6,13]);
+ order=1700;
+ new Game.Achievement('Brain-split','Have <b>150</b> portals.',[7,13]);
+ order=1800;
+ new Game.Achievement('Time duke','Have <b>150</b> time machines.',[8,13]);
+ order=1900;
+ new Game.Achievement('Molecular maestro','Have <b>150</b> antimatter condensers.',[13,13]);
+
+ order=2000;
+ new Game.Achievement('Lone photon','Have <b>1</b> prism.',[14,0]);
+ new Game.Achievement('Dazzling glimmer','Have <b>50</b> prisms.',[14,1]);
+ new Game.Achievement('Blinding flash','Have <b>100</b> prisms.',[14,2]);
+ new Game.Achievement('Unending glow','Have <b>150</b> prisms.',[14,13]);
+
+ order=5000;
+ new Game.Achievement('Lord of Constructs','Own <b>1500</b> buildings.<q>He saw the vast plains stretching ahead of him, and he said : let there be civilization.</q>',[6,6],2);
+ order=6000;
+ new Game.Achievement('Lord of Progress','Purchase <b>150</b> upgrades.<q>One can always do better. But should you?</q>',[9,2],2);
+ order=7000;
+ new Game.Achievement('Bicentennial','Have at least <b>200 of everything</b>.<q>You crazy person.</q>',[9,6],2);
+ order=22300;
+ new Game.Achievement('Lovely cookies','Unlock <b>every Valentine-themed cookie</b>.',[20,3],2);
Game.RuinTheFun=function()
{
@@ -3922,17 +4136,20 @@ Game.Launch=function()
if (me.sucked>0.5)
{
Game.Popup('Exploded a wrinkler : found '+Beautify(me.sucked)+' cookies!');
- //if (Math.random()<(Game.HasAchiev('Spooky cookies')?0.2:0.05))//halloween cookie drops
- var failRate=0.95;
- if (Game.HasAchiev('Spooky cookies')) failRate=0.8;
- if (Game.Has('Santa\'s bottomless bag')) failRate*=0.9;
- if (Math.random()>failRate)//halloween cookie drops
+ if (Game.season=='halloween')
{
- var cookie=choose(['Skull cookies','Ghost cookies','Bat cookies','Slime cookies','Pumpkin cookies','Eyeball cookies','Spider cookies']);
- if (!Game.HasUnlocked(cookie) && !Game.Has(cookie))
+ //if (Math.random()<(Game.HasAchiev('Spooky cookies')?0.2:0.05))//halloween cookie drops
+ var failRate=0.95;
+ if (Game.HasAchiev('Spooky cookies')) failRate=0.8;
+ if (Game.Has('Santa\'s bottomless bag')) failRate*=0.9;
+ if (Math.random()>failRate)//halloween cookie drops
{
- Game.Unlock(cookie);
- Game.Popup('Found : '+cookie+'!');
+ var cookie=choose(['Skull cookies','Ghost cookies','Bat cookies','Slime cookies','Pumpkin cookies','Eyeball cookies','Spider cookies']);
+ if (!Game.HasUnlocked(cookie) && !Game.Has(cookie))
+ {
+ Game.Unlock(cookie);
+ Game.Popup('Found : '+cookie+'!');
+ }
}
}
}
@@ -4191,6 +4408,14 @@ Game.Launch=function()
Game.LeftBackground.globalCompositeOperation='source-over';
Game.LeftBackground.globalAlpha=1;
}
+ //hearts
+ if (Game.season=='valentines')
+ {
+ var y=(Math.floor(Game.T*2.5)%512);
+ Game.LeftBackground.globalAlpha=1;
+ Game.LeftBackground.fillPattern(Game.Assets['heartStorm.png'],0,-512+y,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height+512,512,512);
+ Game.LeftBackground.globalAlpha=1;
+ }
Game.particlesDraw(0);
Game.LeftBackground.globalAlpha=1;
@@ -4276,6 +4501,7 @@ Game.Launch=function()
{
var x=Math.floor((Game.T*2+Math.sin(Game.T*0.1)*2+Math.sin(Game.T*0.03)*2-(Game.milkH-Game.milkHd)*2000+480*2)%480);
var y=(((Game.milkHd)*Game.LeftBackground.canvas.height)*(1+0.05*(Math.sin(Game.T*0.017)/2+0.5)));
+ /*
var m1o=1;
var m2o=0;
var m1i=0;
@@ -4296,7 +4522,18 @@ Game.Launch=function()
Game.LeftBackground.globalAlpha=m2o*0.9;
Game.LeftBackground.fillPattern(Game.Assets[pic2+'.png'],-480+x,Game.LeftBackground.canvas.height-y,Game.LeftBackground.canvas.width+480,1,480,480);
}
+ */
+ var pic=0;
+ if (Game.milkProgress<1) {pic=0;}
+ else if (Game.milkProgress<2) {pic=1;}
+ else if (Game.milkProgress<3) {pic=2;}
+ else if (Game.milkProgress<4) {pic=3;}
+ else if (Game.milkProgress<5) {pic=4;}
+ else {pic=4;}
+ pic=Game.MilkPics[pic];
Game.LeftBackground.globalAlpha=0.9;
+ Game.LeftBackground.fillPattern(Game.Assets[pic+'.png'],-480+x,Game.LeftBackground.canvas.height-y,Game.LeftBackground.canvas.width+480,1,480,480);
+
Game.LeftBackground.fillStyle='#000';
Game.LeftBackground.fillRect(0,Game.LeftBackground.canvas.height-y+480,Game.LeftBackground.canvas.width,Math.max(0,(y-480)));
Game.LeftBackground.globalAlpha=1;
@@ -4314,6 +4551,13 @@ Game.Launch=function()
else if (Game.frenzy>0) borders='shadedBordersRed.png';
Game.LeftBackground.drawImage(Game.Assets[borders],0,0,Game.LeftBackground.canvas.width,Game.LeftBackground.canvas.height);
+ if (Game.frenzy>0 && Game.frenzyPower>=100) {Game.timersEl['elderFrenzy'].style.width=((Game.frenzy/Game.frenzyMax)*100)+'%';Game.timersEl['elderFrenzy'].style.display='block';}
+ else if (Game.frenzy>0 && Game.frenzyPower>1) {Game.timersEl['frenzy'].style.width=((Game.frenzy/Game.frenzyMax)*100)+'%';Game.timersEl['frenzy'].style.display='block';}
+ else if (Game.frenzy>0 && Game.frenzyPower<1) {Game.timersEl['clot'].style.width=((Game.frenzy/Game.frenzyMax)*100)+'%';Game.timersEl['clot'].style.display='block';}
+ if (Game.clickFrenzy>0) {Game.timersEl['clickFrenzy'].style.width=((1-Game.clickFrenzy/Game.clickFrenzyMax)*100)+'%';Game.timersEl['clickFrenzy'].style.display='block';}
+
+ if (Game.frenzy==0) {Game.timersEl['frenzy'].style.display='none';Game.timersEl['elderFrenzy'].style.display='none';Game.timersEl['clot'].style.display='none';}
+ if (Game.clickFrenzy==0) {Game.timersEl['clickFrenzy'].style.display='none';}
};
@@ -4327,7 +4571,7 @@ Game.Launch=function()
INITIALIZATION END; GAME READY TO LAUNCH
=======================================================================================*/
- if (!Game.mobile) Game.LoadSave();
+ Game.LoadSave();
Game.ready=1;
l('javascriptError').innerHTML='';
@@ -4381,6 +4625,18 @@ Game.Launch=function()
Game.nextResearch=0;
Game.researchT=-1;
}
+ //handle seasons
+ if (Game.seasonT>0)
+ {
+ Game.seasonT--;
+ }
+ if (Game.seasonT==0 && Game.season!='' && Game.season!=Game.baseSeason)
+ {
+ var seasons={'halloween':'Halloween is over!','christmas':'Christmas is over!','valentines':'Valentine\'s day is over!'};
+ Game.Popup(seasons[Game.season]);
+ Game.season=Game.baseSeason;
+ Game.seasonT=-1;
+ }
//handle cookies
if (Game.recalculateGains) Game.CalculateGains();
@@ -4458,13 +4714,23 @@ Game.Launch=function()
if (Game.prestige['Heavenly chips']>=100) Game.Unlock('Loreols');
if (Game.prestige['Heavenly chips']>=500) Game.Unlock('Jaffa cakes');
if (Game.prestige['Heavenly chips']>=2000) Game.Unlock('Grease\'s cups');
+
+ if (Game.prestige['Heavenly chips']>=5000) Game.Unlock('Season switcher');
}
if (Game.cookiesEarned>=99999999999999)
{
Game.Unlock(['Gingerbread men','Gingerbread trees']);
+ if (Game.season=='valentines')
+ {
+ Game.Unlock('Pure heart biscuits');
+ if (Game.Has('Pure heart biscuits')) Game.Unlock('Ardent heart biscuits');
+ if (Game.Has('Ardent heart biscuits')) Game.Unlock('Sour heart biscuits');
+ if (Game.Has('Sour heart biscuits')) Game.Unlock('Weeping heart biscuits');
+ if (Game.Has('Weeping heart biscuits')) Game.Unlock('Golden heart biscuits');
+ if (Game.Has('Golden heart biscuits')) Game.Unlock('Eternal heart biscuits');
+ }
}
-
-
+ if (Game.Has('Eternal heart biscuits')) Game.Win('Lovely cookies');
if (Game.prestige['Heavenly chips']>0)
{
@@ -4486,6 +4752,7 @@ Game.Launch=function()
var mathematician=1;
var base10=1;
var centennial=1;
+ var bicentennial=1;
for (var i in Game.Objects)
{
buildingsOwned+=Game.Objects[i].amount;
@@ -4493,11 +4760,13 @@ Game.Launch=function()
if (!Game.HasAchiev('Mathematician')) {if (Game.Objects[i].amount<Math.min(128,Math.pow(2,(Game.ObjectsById.length-Game.Objects[i].id)-1))) mathematician=0;}
if (!Game.HasAchiev('Base 10')) {if (Game.Objects[i].amount<(Game.ObjectsById.length-Game.Objects[i].id)*10) base10=0;}
if (!Game.HasAchiev('Centennial')) {if (Game.Objects[i].amount<100) centennial=0;}
+ if (!Game.HasAchiev('Bicentennial')) {if (Game.Objects[i].amount<200) bicentennial=0;}
}
if (oneOfEach==1) Game.Win('One with everything');
if (mathematician==1) Game.Win('Mathematician');
if (base10==1) Game.Win('Base 10');
if (centennial==1) Game.Win('Centennial');
+ if (bicentennial==1) Game.Win('Bicentennial');
if (Game.cookiesEarned>=1000000 && Game.cookieClicks<=15) Game.Win('Neverclick');
if (Game.cookiesEarned>=1000000 && Game.cookieClicks<=0) Game.Win('True Neverclick');
if (Game.handmadeCookies>=1000) {Game.Win('Clicktastic');Game.Unlock('Plastic mouse');}
@@ -4512,8 +4781,8 @@ Game.Launch=function()
if (Game.wrinklersPopped>=50) Game.Win('Wrinklesquisher');
if (Game.wrinklersPopped>=200) Game.Win('Moistburster');
- if (Game.cookiesEarned>=25) Game.Unlock('A festive hat');
- if (Game.Has('Christmas tree biscuits') && Game.Has('Snowflake biscuits') && Game.Has('Snowman biscuits') && Game.Has('Mistletoe biscuits') && Game.Has('Candy cane biscuits') && Game.Has('Bell biscuits') && Game.Has('Present biscuits')) Game.Win('Let it snow');
+ if (Game.cookiesEarned>=25 && Game.season=='christmas') Game.Unlock('A festive hat');
+ if (Game.Has('Christmas tree biscuits') && Game.Has('Snowflake biscuits') && Game.Has('Snowman biscuits') && Game.Has('Holly biscuits') && Game.Has('Candy cane biscuits') && Game.Has('Bell biscuits') && Game.Has('Present biscuits')) Game.Win('Let it snow');
if (Game.reindeerClicked>=1) Game.Win('Oh deer');
if (Game.reindeerClicked>=50) Game.Win('Sleigh of hand');
@@ -4522,9 +4791,11 @@ Game.Launch=function()
if (buildingsOwned>=100) Game.Win('Builder');
if (buildingsOwned>=400) Game.Win('Architect');
if (buildingsOwned>=800) Game.Win('Engineer');
+ if (buildingsOwned>=1500) Game.Win('Lord of Constructs');
if (Game.UpgradesOwned>=20) Game.Win('Enhancer');
if (Game.UpgradesOwned>=50) Game.Win('Augmenter');
if (Game.UpgradesOwned>=100) Game.Win('Upgrader');
+ if (Game.UpgradesOwned>=150) Game.Win('Lord of Progress');
if (Game.UpgradesOwned==0 && Game.cookiesEarned>=1000000000) Game.Win('Hardcore');
@@ -4539,6 +4810,7 @@ Game.Launch=function()
if (Game.Has('Altered grandmas')) grandmas++;
if (Game.Has('Grandmas\' grandmas')) grandmas++;
if (Game.Has('Antigrandmas')) grandmas++;
+ if (Game.Has('Rainbow grandmas')) grandmas++;
if (!Game.HasAchiev('Elder') && grandmas>=7) Game.Win('Elder');
if (Game.Objects['Grandma'].amount>=6 && !Game.Has('Bingo center/Research facility') && Game.HasAchiev('Elder')) Game.Unlock('Bingo center/Research facility');
if (Game.pledges>0) Game.Win('Elder nap');
@@ -4596,15 +4868,24 @@ Game.Launch=function()
Game.TickerDraw();
Game.tooltip.update();
- for (var i in Game.Objects)
+ if (Game.T%10==0)
{
- var me=Game.Objects[i];
-
- //make products full-opacity if we can buy them
- if (Game.cookies>=me.getPrice()) l('product'+me.id).className='product enabled'; else l('product'+me.id).className='product disabled';
-
- //update object info
- if (l('rowInfo'+me.id) && Game.T%5==0) l('rowInfoContent'+me.id).innerHTML='&bull; '+me.amount+' '+(me.amount==1?me.single:me.plural)+'<br>&bull; producing '+Beautify(me.storedTotalCps,1)+' '+(me.storedTotalCps==1?'cookie':'cookies')+' per second<br>&bull; total : '+Beautify(me.totalCookies)+' '+(Math.floor(me.totalCookies)==1?'cookie':'cookies')+' '+me.actionName;
+ var lastLocked=0;
+ for (var i in Game.Objects)
+ {
+ var me=Game.Objects[i];
+
+ //make products full-opacity if we can buy them
+ var classes='product';
+ var price=me.price;
+ if (Game.cookiesEarned>=price) {classes+=' unlocked';lastLocked=0;} else {classes+=' locked';lastLocked++;}
+ if (Game.cookies>=price) classes+=' enabled'; else classes+=' disabled';
+ if (lastLocked>1) classes+=' toggledOff';
+ l('product'+me.id).className=classes;
+
+ //update object info
+ if (l('rowInfo'+me.id) && Game.T%5==0) l('rowInfoContent'+me.id).innerHTML='&bull; '+me.amount+' '+(me.amount==1?me.single:me.plural)+'<br>&bull; producing '+Beautify(me.storedTotalCps,1)+' '+(me.storedTotalCps==1?'cookie':'cookies')+' per second<br>&bull; total : '+Beautify(me.totalCookies)+' '+(Math.floor(me.totalCookies)==1?'cookie':'cookies')+' '+me.actionName;
+ }
}
//make upgrades full-opacity if we can buy them
diff --git a/mobile.js b/mobile.js
deleted file mode 100644
index 3d0f5d6..0000000
--- a/mobile.js
+++ /dev/null
@@ -1,82 +0,0 @@
-var LaunchMobile=function()
-{
- Game.m={fileSystem:{}};//handle for every thing mobile
-
- //docs for this stuff : http://docs.phonegap.com/en/3.0.0/cordova_file_file.md.html
-
- Game.m.readSaveRequest=function()
- {
- Debug('Load save request');
- Game.m.fileSystem.root.getFile(Game.SaveTo+'.txt',{create:true,exclusive: false},Game.m.readFileEntry,Game.m.fail);
- }
- Game.m.readSaveResponse=function(response)
- {
- Debug('Load save response');
- Game.LoadSave(unescape(response));
- }
- Game.m.writeSaveRequest=function()
- {
- Debug('Write save request');
- Game.m.fileSystem.root.getFile(Game.SaveTo+'.txt',{create:true,exclusive: false},Game.m.writeFileEntry,Game.m.fail);
- }
-
-
- Game.m.onDeviceReady=function()
- {
- Debug('Ready');
- window.requestFileSystem(LocalFileSystem.PERSISTENT,0,Game.m.gotFileSystem,Game.m.fail);//ask for the file system
- }
-
- Game.m.gotFileSystem=function(fileSystem)
- {
- Debug('Got file system');
- Game.m.fileSystem=fileSystem;//did we get the file system? Good, save it
- Game.LoadSave();//load the save for good measure
- }
-
- Game.m.readFileEntry=function(fileEntry)
- {
- Debug('Read file entry');
- fileEntry.file(Game.m.readFile,Game.m.fail);//did we get the requested file entry? That's just super, get ready to read it
- }
- Game.m.readFile=function(file)
- {
- Debug('Read file');
- var reader=new FileReader();//we got the file we wanted? Radical. Let's read it now
- reader.onloadend=function(evt)
- {
- Game.m.readSaveResponse(evt.target.result);
- //console.log(evt.target.result);
- };
- reader.readAsText(file);
- }
-
-
-
- Game.m.writeFileEntry=function(fileEntry)
- {
- Debug('Write file entry');
- fileEntry.createWriter(Game.m.writeFile,Game.m.fail);//did we get the requested file entry? Joy and butterflies, now we can write to it
- }
- Game.m.writeFile=function(writer)
- {
- Debug('Write file');
- writer.onwriteend=function(evt)//why this plugin isn't using unquestionably superior camel-case is beyond me
- {
- };
- writer.write(Game.saveData);//well oh my goodness I think we're done here
- }
-
-
-
- Game.m.fail=function(evt)//well I guess something went wrong
- {
- Debug('Failed');
- console.log(evt.target.error.code);
- Game.Popup(evt.target.error.code);
- }
-
- //Wait for device API libraries to load
- Debug('Readying mobile');
- document.addEventListener('deviceready',Game.m.onDeviceReady,false);
-} \ No newline at end of file
diff --git a/phonegap.js b/phonegap.js
deleted file mode 100644
index d04c424..0000000
--- a/phonegap.js
+++ /dev/null
@@ -1,168 +0,0 @@
-<head><title>Aw noes ! 404 !
-</title>
-<script type="text/javascript">
-//<![CDATA[
-try{if (!window.CloudFlare) {var CloudFlare=[{verbose:0,p:0,byc:0,owlid:"cf",bag2:1,mirage2:0,oracle:0,paths:{cloudflare:"/cdn-cgi/nexp/dok7v=02fcfa4f56/"},atok:"ec5a7430fd37e315c91cf9f91346d5f7",petok:"4de9598806cc2932a84c02da74f6b481b6e4d759-1392325356-1800",zone:"dashnet.org",rocket:"0",apps:{"ga_key":{"ua":"UA-29324474-2","ga_bs":"2"},"abetterbrowser":{"ie":"8"}}}];var a=document.createElement("script"),b=document.getElementsByTagName("script")[0];a.async=!0;a.src="//ajax.cloudflare.com/cdn-cgi/nexp/dok7v=221574e73d/cloudflare.min.js";b.parentNode.insertBefore(a,b);}}catch(e){};
-//]]>
-</script>
-<link rel="stylesheet" type="text/css" href="/style.css" />
-<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
-<script type="text/javascript">
-/* <![CDATA[ */
-var _gaq = _gaq || [];
-_gaq.push(['_setAccount', 'UA-29324474-2']);
-_gaq.push(['_trackPageview']);
-
-(function() {
-var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
-ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
-var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
-})();
-
-(function(b){(function(a){"__CF"in b&&"DJS"in b.__CF?b.__CF.DJS.push(a):"addEventListener"in b?b.addEventListener("load",a,!1):b.attachEvent("onload",a)})(function(){"FB"in b&&"Event"in FB&&"subscribe"in FB.Event&&(FB.Event.subscribe("edge.create",function(a){_gaq.push(["_trackSocial","facebook","like",a])}),FB.Event.subscribe("edge.remove",function(a){_gaq.push(["_trackSocial","facebook","unlike",a])}),FB.Event.subscribe("message.send",function(a){_gaq.push(["_trackSocial","facebook","send",a])}));"twttr"in b&&"events"in twttr&&"bind"in twttr.events&&twttr.events.bind("tweet",function(a){if(a){var b;if(a.target&&a.target.nodeName=="IFRAME")a:{if(a=a.target.src){a=a.split("#")[0].match(/[^?=&]+=([^&]*)?/g);b=0;for(var c;c=a[b];++b)if(c.indexOf("url")===0){b=unescape(c.split("=")[1]);break a}}b=void 0}_gaq.push(["_trackSocial","twitter","tweet",b])}})})})(window);
-/* ]]> */
-</script>
-</head>
-<body>
-
-<script>
-
-var History=new Array();
-var Back=false;
-
-String.prototype.contains = function(it) { return this.indexOf(it) != -1; };
-
-function GoBack()
-{
-Back=true;
-if (History.length>1) Show(History[History.length-2]);
-}
-
-var Nodes=new Array();
-
-function Node(name,text,links,background)
-{
-this.name=name;
-this.text=text;
-this.links=links.split("|");
-this.background=background ? background : "";
-
-for (var i in this.links)
-{
-this.links[i]=this.links[i].split("/");
-}
-
-Nodes[this.name]=this;
-}
-
-Node.prototype.show=function()
-{
-var txt="";
-if (this.background!="") document.getElementById('bg').style.backgroundImage="url("+this.background+")";
-else document.getElementById('bg').style.backgroundImage="none";
-
-if (Back==false) History.push(this.name); else History.pop();
-Back=false;
-txt+=this.text;
-txt+='<div class="choices">';
-for (var i in this.links)
-{
-if (this.links[i][2]=='web') txt+='<a class="choice" href="'+this.links[i][1]+'">'+this.links[i][0]+'</a>';
-else if (Nodes[this.links[i][1]]) txt+='<a class="choice" href="javascript:Show(\''+this.links[i][1]+'\')">'+this.links[i][0]+'</a>';
-else txt+='<a class="choice" style="opacity:0.5;" href="javascript:Show(\''+this.links[i][1]+'\')">'+this.links[i][0]+'</a>';
-}
-if (History.length>1) txt+='<br><br><a class="back" href="javascript:GoBack();">< back</a>';
-txt+='</div>';
-
-document.getElementById("text").innerHTML=txt;
-//document.getElementById("currentNode").innerHTML=this.name;
-}
-
-function Show(what)
-{
-Nodes[what].show();
-}
-
-
-new Node(
-"main",
-"<span style='font-size:200%;'>404</span><br>aw noes :(<br>you have broken our interwebs !<br>it's okay though, you can still go",
-"there/index.php/web|or there/story.php/web"
-);
-
-
-function Input(what)
-{
-if (Nodes[what]) Nodes[what].show();
-}
-
-var Links=new Array();
-var NodesN=0;
-for (var i in Nodes)
-{
-for (var i2 in Nodes[i].links)
-{Links.push(Nodes[i].links[i2][1]);}
-NodesN++;
-}
-
-var txt="";
-for (var i in Links)
-{
-if (!Nodes[Links[i]]) txt+=Links[i]+' / ';
-}
-
-
-//document.write('<div style="font-size:8pt;opacity:0.5;">'+(NodesN)+' nodes. Missing : '+txt+'</div>');
-
-</script>
-
-<table class="main"><tr><td id="bg">
-<table class="main"><tr><td style="background-color:rgba(0,0,0,0.5);vertical-align:middle;text-align:center;">
-<div class="bordercolor" id="bordercolor">
-<div id="text" class="text">
-</div>
-</div>
-<div style="position:absolute;bottom:0px;left:0px;opacity:0.5;padding:4px;font-size:8pt;text-align:left;">(c) Orteil 2011<br>proudly hosted by <a href="http://dashnet.org">dashnet.org</a></div>
-</td></tr></table>
-</td></tr></table>
-
-<script>
-Nodes["main"].show();
-
-function hsvToRgb(h, s, v){
- var r, g, b;
-
- var i = Math.floor(h * 6);
- var f = h * 6 - i;
- var p = v * (1 - s);
- var q = v * (1 - f * s);
- var t = v * (1 - (1 - f) * s);
-
- switch(i % 6){
- case 0: r = v, g = t, b = p; break;
- case 1: r = q, g = v, b = p; break;
- case 2: r = p, g = v, b = t; break;
- case 3: r = p, g = q, b = v; break;
- case 4: r = t, g = p, b = v; break;
- case 5: r = v, g = p, b = q; break;
- }
-
- return [r * 255, g * 255, b * 255];
-}
-
-
-var t=0;
-function Rainbow()
-{
-var Col=hsvToRgb((t%100)/100,1,1);
-document.getElementById("bordercolor").style.backgroundColor="rgb("+Math.floor(Col[0])+","+Math.floor(Col[1])+","+Math.floor(Col[2])+")";
-//document.getElementById("text").innerHTML="rgb("+Math.floor(Col[0])+","+Math.floor(Col[1])+","+Math.floor(Col[2])+")";
-t++;
-setTimeout("Rainbow();",1000/10);
-}
-
-Rainbow();
-
-</script>
-
-</body> \ No newline at end of file