Frame 1
function otherOnEnterFrame() {
q = (q + 1) % 360;
rect(3, 0, 0, 1280, 720, 0 + ((((4294967295 * random(2)) * random(2)) * random(2)) * random(2)));
writeln(lay3, lg, "[ Do Not Be Alarmed ]", random(5), (400 * Math.sin(q * pi180)) + 480, (320 * Math.cos(q * pi180)) + 356);
}
function rect(l, x, y, w, h, c) {
bmp[l].fillRect(new flash.geom.Rectangle(x, y, w, h), c);
}
function write(wlayer, wsize, wchr, wcolor, wherex, wherey) {
bmp[wlayer].copyPixels(alphamap, new flash.geom.Rectangle((ord(wchr) - 32) * (8 + (wsize * 8)), (wcolor * 16) + (wsize * 80), 8 + (wsize * 8), 16), new flash.geom.Point(wherex, wherey), null, null, true);
}
function writeln(wlay, wsiz, wstr, wwc, wwx, wwy) {
x2 = 0;
while (x2 < length(wstr)) {
write(wlay, wsiz, wstr.charAt(x2), wwc, wwx + (x2 * (8 + (wsiz * 8))), wwy);
x2++;
}
}
function convert(amt) {
mult = 1;
finalamt = "";
x = 0;
while (x < 10) {
if (x == 2) {
finalamt = "." + finalamt;
}
if ((x == 5) || (x == 8)) {
if (amt >= mult) {
finalamt = "," + finalamt;
} else {
finalamt = " " + finalamt;
}
}
if ((x <= 2) || (amt >= mult)) {
finalamt = (int(amt / mult) % 10) + finalamt;
} else {
finalamt = " " + finalamt;
}
mult = mult * 10;
x++;
}
return(finalamt);
}
var alphamap = flash.display.BitmapData.loadBitmap("alphamap.png");
var oldmanmap = flash.display.BitmapData.loadBitmap("oldman.gif");
focusRect = false;
tabEnabled = false;
_root.createEmptyMovieClip("bh", 10);
layers = 4;
lay0 = 0;
lay1 = 1;
lay2 = 2;
lay3 = 3;
sm = 0;
lg = 1;
bmp = new Array();
x = 0;
while (x < layers) {
bmp[x] = new flash.display.BitmapData(1280, 720, true, 0);
bh.attachBitmap(bmp[x], x);
x++;
}
q = 0;
rect(lay0, 0, 0, 1280, 720, 4278190080);
this.desiredFrameRate = 60;
this.callFunctionInt = setInterval(this, "otherOnEnterFrame", 1000 / this.desiredFrameRate);
this.onMouseDown = function () {
};
writeln(lay2, sm, _root._url, 0, 0, 0);
var jsonFetcher = new LoadVars();
jsonFetcher.onLoad = function (success) {
if (!success) {
trace("Error connecting to server.");
}
};
jsonFetcher.onData = function (thedata) {
try {
p = 1;
while (p < 22) {
writeln(lay1, sm, thedata.substr(p * 160, 160), 1, 0, 16 * p);
p++;
}
} catch(ex) {
trace((((((ex.name + ":") + ex.message) + ":") + ex.at) + ":") + ex.text);
}
};
jsonFetcher.load("http://a.4cdn.org/boards.json");
var xFetcher = new LoadVars();
xFetcher.onLoad = function (success) {
if (!success) {
trace("Error connecting to server.");
}
};
xFetcher.onData = function (thedata) {
try {
p = 22;
while (p < 45) {
writeln(lay1, sm, thedata.substr(p * 160, 160), 2, 0, 16 * p);
p++;
}
} catch(ex) {
trace((((((ex.name + ":") + ex.message) + ":") + ex.at) + ":") + ex.text);
}
};
xFetcher.load("http://boards.4chan.org/b/index.rss");
pi180 = (Math.PI/180);
song = new Sound();
song.attachSound("music");
song.start(0, 9999);
x = 0;
while (x < 53) {
y = 0;
while (y < 45) {
r = ((x * x) + (y * y)) % 256;
writeln(lay0, sm, r.toString(16), 4, 24 * x, y * 16);
y++;
}
x++;
}
bmp[2].copyPixels(oldmanmap, new flash.geom.Rectangle(0, 0, 329, 389), new flash.geom.Point(475, 155));