Frame 2
var theMenu = new ContextMenu();
theMenu.hideBuiltInItems();
_root.menu = theMenu;
var i1 = new ContextMenuItem("", exit);
theMenu.customItems[0] = i1;
Frame 3
_global.okay = 0;
_global.ext = 0;
stop();
Frame 4
stop();
var theMenu = new ContextMenu();
theMenu.hideBuiltInItems();
_root.menu = theMenu;
var i1 = new ContextMenuItem("", exit);
theMenu.customItems[0] = i1;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:21};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
char = {xtile:-2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
btn = 0;
local_data = SharedObject.getLocal("user_data");
_global.score = local_data.data.score2;
if (local_data.data.score2 > 1) {
} else {
local_data.data.score2 = 1;
local_data.flush();
}
if (_global.okay == 1) {
_global.okay = 0;
}
Instance of Symbol 227 MovieClip in Frame 4
onClipEvent (enterFrame) {
play();
}
Instance of Symbol 240 MovieClip in Frame 4
onClipEvent (enterFrame) {
if ((_global.score < 21) || (_global.ext == 0)) {
this._x = -1000;
}
}
Instance of Symbol 247 MovieClip "ogi" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "ogo" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 274 MovieClip "kkk2" in Frame 4
onClipEvent (mouseDown) {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
startDrag (this);
dragging = 1;
_root.sys.drag = 1;
}
}
onClipEvent (mouseUp) {
if (dragging) {
stopDrag();
X = this._x;
Y = this._y;
if (_root.selected == "normal") {
this._x = Math.round(X / _root.gridSpacing) * _root.gridSpacing;
this._y = Math.round(Y / _root.gridSpacing) * _root.gridSpacing;
}
if (_root.selected == "rand") {
smallestX = 1000;
smallestY = 1000;
i = 0;
while (i < _root.numLines) {
difX = Math.round(Math.abs(gridX[i] - X));
difY = Math.round(Math.abs(gridY[i] - Y));
diffX[difX] = i;
diffY[difY] = i;
smallestX = Math.min(smallestX, difX);
smallestY = Math.min(smallestY, difY);
i++;
}
this._x = gridX[diffX[smallestX]];
this._y = gridY[diffY[smallestY]];
}
dragging = 0;
_root.sys.drag = 0;
}
}
onClipEvent (enterFrame) {
if (this.hitTest(_root.lock)) {
this._x = -1000;
_root.secret = 1;
}
}
Instance of Symbol 247 MovieClip "che" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (fin == 0) {
this._x = _root.char.clip._x;
this._y = _root.char.clip._y;
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
_root.secret = 1;
fin = 3;
this._x = 10000;
}
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la02" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la03" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la04" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la05" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la06" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la07" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la08" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la09" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la10" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la11" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la12" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la13" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la14" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la15" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la16" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la17" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la18" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la19" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la20" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la21" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la22" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la23" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la24" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la25" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la01" in Frame 4
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 271 MovieClip in Frame 4
onClipEvent (enterFrame) {
_root.gad._x = this._x;
_root.gad._y = this._y;
}
Instance of Symbol 277 MovieClip "tele2" in Frame 4
onClipEvent (enterFrame) {
_x = _root.tele._x;
_y = _root.tele._y;
}
Frame 5
stop();
btn = 0;
lvlz = 0;
Instance of Symbol 403 MovieClip "gad" in Frame 5
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 6
play();
lygis = "level 01";
aha = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0], [0, 0, 0, 0, 0, 5, 7, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1], [0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0], [0, 0, 0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0], [0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0], [0, 0, 0, 0, 0, 0, 5, 4, 4, 74, 4, 1, 4, 7, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 3, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 3, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 6
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la01" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la02" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la03" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la04" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la05" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la06" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la07" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la08" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la09" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la10" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la11" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la12" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la13" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la14" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la15" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la16" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la17" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la18" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la19" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la20" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la21" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la22" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la23" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la24" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la25" in Frame 6
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 6
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 7
if (local_data.data.score2 < 2) {
local_data.data.score2 = 2;
local_data.flush();
}
lygis = "level 02";
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 9, 0, 0], [0, 0, 0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0], [0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 1, 0, 31, 0, 0, 31, 0], [0, 0, 0, 6, 4, 4, 8, 0, 0, 0, 1, 0, 30, 0, 0, 30, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 0, 26, 27, 28, 29, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile26 = {walkable:true, frame:26};
game.tile27 = {walkable:true, frame:27};
game.tile28 = {walkable:true, frame:28};
game.tile29 = {walkable:true, frame:29};
game.tile30 = {walkable:true, frame:30};
game.tile31 = {walkable:true, frame:31};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 7
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart * 2;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip "la01" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la03" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la04" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la05" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la06" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la07" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la08" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la09" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la10" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la11" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la12" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la13" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la14" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la15" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la16" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la17" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la18" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la19" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la20" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la21" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la22" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la23" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la24" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la25" in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 7
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 7
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 8
if (local_data.data.score2 < 3) {
local_data.data.score2 = 3;
local_data.flush();
}
secret = 0;
lygis = "level 03";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 1, 0, 3, 0, 3, 0, 1, 0, 0, 0, 0, 0], [0, 0, 0, 6, 4, 1, 4, 8, 9, 5, 4, 1, 4, 4, 7, 0, 0], [0, 0, 0, 3, 0, 1, 0, 0, 10, 0, 0, 1, 0, 0, 3, 0, 0], [0, 0, 0, 3, 0, 1, 2, 1, 1, 1, 1, 1, 0, 0, 3, 0, 0], [0, 6, 4, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [0, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 74, 4], [4, 8, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0], [0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0], [0, 1, 0, 0, 0, 0, 32, 33, 34, 35, 0, 0, 0, 0, 0, 1, 0], [1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:75, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile32 = {walkable:true, frame:32};
game.tile33 = {walkable:true, frame:33};
game.tile34 = {walkable:true, frame:34};
game.tile35 = {walkable:true, frame:35};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:8, ytile:8, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 8
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 8
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 256;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 8
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 9
if (local_data.data.score2 < 4) {
local_data.data.score2 = 4;
local_data.flush();
}
lygis = "level 04";
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 1], [1, 4, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 1], [1, 0, 3, 0, 0, 36, 37, 38, 39, 40, 41, 0, 0, 0, 0, 0, 1], [1, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 73, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1], [1, 4, 8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1], [99, 0, 0, 9, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 99], [99, 0, 0, 10, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 99], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile99 = {walkable:true, frame:2};
game.tile36 = {walkable:true, frame:36};
game.tile37 = {walkable:true, frame:37};
game.tile38 = {walkable:true, frame:38};
game.tile39 = {walkable:true, frame:39};
game.tile40 = {walkable:true, frame:40};
game.tile41 = {walkable:true, frame:41};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:14, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 9
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip "la01" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la03" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la04" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la05" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la06" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la07" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la08" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la09" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la10" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la11" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la12" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la13" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la14" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la15" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la16" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la17" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la18" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la19" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la20" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la21" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la22" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la23" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la24" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "la25" in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 9
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "ogo" in Frame 9
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip)) {
_parent.char.xtile = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 9
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 10
if (local_data.data.score2 < 5) {
local_data.data.score2 = 5;
local_data.flush();
}
secret = 0;
lygis = "level 05";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 0, 0, 0, 0, 0, 0, 73, 0, 0, 0, 1, 1, 1, 44], [1, 1, 42, 1, 1, 1, 1, 1, 4, 8, 0, 0, 1, 1, 1, 1, 44], [1, 1, 43, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 15, 13, 13, 44], [1, 1, 43, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 14, 13, 13, 44], [1, 1, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile42 = {walkable:true, frame:42};
game.tile43 = {walkable:false, frame:43};
game.tile44 = {walkable:true, frame:44};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:8, ytile:11, speed:6, jumpstart:20, gravity:1.9, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 10
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 10
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "sex" in Frame 10
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.secret = 1;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 10
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Instance of Symbol 247 MovieClip "ogo" in Frame 10
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip)) {
_parent.char.xtile = 0;
}
}
Frame 11
if (local_data.data.score2 < 6) {
local_data.data.score2 = 6;
local_data.flush();
}
secret = 0;
lygis = "level 06";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 3, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 3, 0, 0, 0, 1, 1, 46, 1, 1, 0, 0, 0, 3, 0, 0], [4, 74, 8, 0, 12, 0, 1, 1, 1, 1, 1, 0, 0, 0, 3, 0, 0], [0, 0, 0, 0, 11, 0, 1, 1, 46, 1, 1, 0, 0, 0, 3, 0, 0], [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 5, 4, 4], [0, 0, 0, 0, 1, 1, 1, 1, 46, 1, 1, 1, 1, 0, 0, 0, 0], [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 45, 1, 1, 0, 0, 0, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile45 = {walkable:true, frame:45};
game.tile46 = {walkable:false, frame:46};
game.tile47 = {walkable:true, frame:47};
game.tile48 = {walkable:true, frame:48};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:15, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 11
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 11
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 128;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 11
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 12
hita = 0;
hitb = 0;
hitc = 0;
hitd = 0;
secret = 0;
lygis = "level 07";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1], [1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1], [1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1], [1, 1, 1, 1, 1, 4, 4, 1, 1, 1, 4, 4, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 12, 0, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 11, 0, 1, 1, 1, 1, 1], [1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1], [1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1], [1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1], [1, 1, 1, 1, 1, 0, 30, 0, 0, 0, 30, 0, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 0, 47, 48, 48, 48, 49, 0, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile47 = {walkable:true, frame:47};
game.tile48 = {walkable:true, frame:48};
game.tile49 = {walkable:true, frame:49};
game.tile50 = {walkable:true, frame:50};
game.tile30 = {walkable:true, frame:30};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:5, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 7) {
local_data.data.score2 = 7;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 12
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 12
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if ((((_root.hita == 1) && (_root.hitb == 1)) && (_root.hitc == 1)) && (_root.hitd == 1)) {
_root.secret = 1;
}
if (_root.secret == 1) {
this._x = 320;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 12
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
if (_root.hita == 1) {
_root.hitb = 1;
}
if (_root.hitc == 1) {
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
}
}
}
Instance of Symbol 247 MovieClip in Frame 12
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
if (_root.hitc == 1) {
_root.hitd = 1;
}
if (_root.hita == 0) {
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
}
}
}
Instance of Symbol 247 MovieClip in Frame 12
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hita = 1;
if (_root.hitb == 1) {
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
}
}
}
Instance of Symbol 247 MovieClip in Frame 12
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 320;
}
if (this.hitTest(_parent.char.clip)) {
if (_root.hitb == 1) {
_root.hitc = 1;
}
if (_root.hitd == 1) {
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
}
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 12
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 13
if (local_data.data.score2 < 8) {
local_data.data.score2 = 8;
local_data.flush();
}
secret = 0;
lygis = "level 08";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [9, 0, 0, 0, 5, 7, 0, 6, 4, 4, 4, 4, 4, 7, 0, 0, 0], [10, 0, 0, 0, 0, 5, 4, 8, 0, 0, 0, 0, 0, 3, 0, 0, 0], [1, 17, 17, 52, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 5, 74, 4, 4], [0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0], [0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0, 1, 0, 1, 0, 0], [0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0], [0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile17 = {walkable:false, frame:18};
game.tile52 = {walkable:false, frame:52};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:10, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 13
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 13
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 13
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 14
if (local_data.data.score2 < 9) {
local_data.data.score2 = 9;
local_data.flush();
}
secret = 0;
lygis = "level 09";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 0, 3, 0, 0, 0, 0, 53, 0, 0, 1, 1, 1, 1], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4], [4, 4, 4, 4, 4, 3, 4, 4, 4, 74, 4, 4, 4, 4, 4, 8, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1], [12, 0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0], [11, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile53 = {walkable:true, frame:53};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:9, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 14
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_global.ext == 1) {
_root.secret = 1;
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 14
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 0;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 14
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 15
secret = 0;
timer = 150;
lygis = "level 10";
function exit() {
_root.secret = 1;
}
var theMenu = new ContextMenu();
theMenu.hideBuiltInItems();
_root.menu = theMenu;
var i1 = new ContextMenuItem("", exit);
theMenu.customItems[0] = i1;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 5, 4], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 51, 0, 0, 12, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 51, 0, 0, 11, 0, 0], [0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 6, 4, 4], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile22 = {walkable:true, frame:22};
game.tile23 = {walkable:true, frame:23};
game.tile50 = {walkable:true, frame:50};
game.tile51 = {walkable:true, frame:51};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:5, ytile:5, speed:6, jumpstart:20, gravity:1.9, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 10) {
local_data.data.score2 = 10;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 15
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
_root.timer = _root.timer - 1;
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
_root.timer = 150;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
_root.timer = 150;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
_root.timer = 150;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
if (_root.timer < 0) {
_root.secret = 1;
}
}
Instance of Symbol 247 MovieClip in Frame 15
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 448;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 15
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 16
aha = 0;
lygis = "level 11";
secret = 0;
stop();
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4, 4, 8, 0, 0], [0, 0, 0, 0, 0, 6, 4, 4, 4, 4, 4, 8, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 12, 0, 6, 4, 8, 0, 0, 0, 54, 0, 0, 0, 0, 0, 0, 0], [0, 11, 0, 3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1], [0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 1, 0, 0, 9, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 73, 0, 0, 1, 0, 0, 10, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile54 = {walkable:true, frame:54};
game.tile16 = {walkable:false, frame:14};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:13, ytile:5, speed:6, jumpstart:20, gravity:1.9, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 11) {
local_data.data.score2 = 11;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 16
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(16)) {
_root.secret = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 16
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 16
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 17
secret = 0;
aha = 1;
lygis = "level 12";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 0, 0, 5, 4, 7, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 1, 0, 0, 6, 8, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 9, 0, 0], [0, 0, 0, 0, 0, 0, 0, 3, 1, 1, 1, 0, 0, 0, 55, 0, 0], [0, 0, 0, 0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 1, 1, 1, 1], [0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile55 = {walkable:true, frame:55};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:2, ytile:11, speed:6, jumpstart:20, gravity:1.9, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 12) {
local_data.data.score2 = 12;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 17
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 17
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 442;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 274 MovieClip "kkk2" in Frame 17
onClipEvent (mouseDown) {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
startDrag (this);
dragging = 1;
_root.sys.drag = 1;
}
}
onClipEvent (mouseUp) {
if (dragging) {
stopDrag();
X = this._x;
Y = this._y;
if (_root.selected == "normal") {
this._x = Math.round(X / _root.gridSpacing) * _root.gridSpacing;
this._y = Math.round(Y / _root.gridSpacing) * _root.gridSpacing;
}
if (_root.selected == "rand") {
smallestX = 1000;
smallestY = 1000;
i = 0;
while (i < _root.numLines) {
difX = Math.round(Math.abs(gridX[i] - X));
difY = Math.round(Math.abs(gridY[i] - Y));
diffX[difX] = i;
diffY[difY] = i;
smallestX = Math.min(smallestX, difX);
smallestY = Math.min(smallestY, difY);
i++;
}
this._x = gridX[diffX[smallestX]];
this._y = gridY[diffY[smallestY]];
}
dragging = 0;
_root.sys.drag = 0;
}
}
onClipEvent (enterFrame) {
if (this.hitTest(_root.lock)) {
this._x = -1000;
_root.secret = 1;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 17
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 18
aha = 1;
secreta = 0;
_root.gad._x = 0;
lygis = "level 13";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 56, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 56, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0], [0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:19};
game.tile12 = {walkable:true, frame:20};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile56 = {walkable:true, frame:56};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:14, ytile:2, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 13) {
local_data.data.score2 = 13;
local_data.flush();
}
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 18
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip "mmm" in Frame 18
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secreta == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
onClipEvent (load) {
var aca = new Date();
aaa = aca.getSeconds();
aa = aca.getMinutes();
a = aca.getHours();
hoursDelta = Math.floor((aa / 61) * 15);
minutesDelta = Math.round((seconds / 60) * 6);
if ((!hoursDelta) == 0) {
this._rotation = (-(hr * 15)) - hoursDelta;
}
if (a > 12) {
hr = a - 12;
} else {
hr = a + 12;
}
}
onClipEvent (enterFrame) {
var aca = new Date();
aaa = aca.getSeconds();
aa = aca.getMinutes();
a = aca.getHours();
hoursDelta = Math.floor((aa / 61) * 15);
minutesDelta = Math.round((seconds / 60) * 6);
if ((!hoursDelta) == 0) {
if ((a == 0) && (aa <= 31)) {
_root.secret = 1;
}
}
if (a > 12) {
hr = a - 12;
} else {
hr = a + 12;
}
}
onClipEvent (load) {
var aca2 = new Date();
b = aca2.getHours();
this.gotoAndStop(hr);
if (b > 12) {
hr = b - 12;
} else {
hr = b + 12;
}
}
onClipEvent (enterFrame) {
var aca2 = new Date();
b = aca2.getHours();
this.gotoAndStop(hr);
if (b > 12) {
hr = b - 12;
} else {
hr = b + 12;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 18
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 19
aha = 0;
secret = 0;
lygis = "level 14";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[1, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 1], [1, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 5, 74, 4, 1], [1, 0, 0, 0, 3, 0, 0, 0, 0, 0, 57, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0, 0, 0, 12, 0, 1], [1, 0, 0, 0, 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 11, 0, 1], [1, 0, 0, 0, 3, 0, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 1], [1, 4, 74, 4, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 1], [1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 1], [1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile57 = {walkable:true, frame:57};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 14) {
local_data.data.score2 = 14;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 19
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 19
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_global.okay == 1) {
_root.secret = 1;
}
if (_root.secret == 1) {
this._x = 448;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 19
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 20
secret = 0;
lygis = "level 15";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 1, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 5, 4, 7, 0, 0, 1, 0, 5, 4, 4, 74, 4, 4, 4], [0, 0, 0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0], [0, 9, 0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0], [0, 10, 0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile24 = {walkable:true, frame:24};
game.tile25 = {walkable:true, frame:25};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:14, ytile:7, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 15) {
local_data.data.score2 = 15;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 20
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 20
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 21
tw = 0;
fo = 0;
fi = 0;
_root.tele._x = -100;
_root.tele2._x = -100;
secret = 0;
lygis = "level 16";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 74, 4], [0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11], [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 58, 0, 0, 0, 0, 0, 0], [4, 4, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], [0, 0, 3, 0, 1, 0, 0, 3, 0, 0, 0, 1, 0, 0, 0, 0, 0], [0, 0, 3, 0, 1, 0, 0, 73, 0, 0, 0, 1, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 0, 0, 3, 0, 0, 0, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile58 = {walkable:true, frame:58};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 16) {
local_data.data.score2 = 16;
local_data.flush();
}
_root.gad.hra._x = -1000;
_root.gad.hrb._x = -1000;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 21
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 21
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 512;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 411 MovieClip "asd" in Frame 21
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 512;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 413 MovieClip "asdf" in Frame 21
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 512;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 415 MovieClip in Frame 21
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 512;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 21
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 22
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
secret = 0;
lygis = "level 17";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0], [0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 5, 4, 74, 4, 4, 4], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 59, 0, 0, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 0, 3, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0], [0, 0, 6, 4, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 4], [0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0], [0, 0, 5, 7, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1], [0, 12, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0], [0, 11, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile59 = {walkable:true, frame:59};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:5, ytile:6, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 17) {
local_data.data.score2 = 17;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 22
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 22
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if ((((_root.hita == 1) && (_root.hitb == 1)) && (_root.hitc == 1)) && (_root.hitd == 1)) {
_root.secret = 1;
}
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 22
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.hita = 1;
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 22
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.hitb = 1;
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 22
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.hitc = 1;
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 22
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.hitd = 1;
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 22
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 23
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
secret = 0;
lygis = "level 18";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 12, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 0], [0, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 61, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 62, 0, 0, 0, 0, 0, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile60 = {walkable:true, frame:60};
game.tile61 = {walkable:true, frame:61};
game.tile62 = {walkable:true, frame:62};
char = {xtile:12, ytile:2, speed:5, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 18) {
local_data.data.score2 = 18;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 23
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 128;
}
if ((((_root.hita == 1) && (_root.hitb == 1)) && (_root.hitc == 1)) && (_root.hitd == 1)) {
_root.secret = 1;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
if (((_root.hitb == 0) && (_root.hitc == 0)) && (_root.hitd == 0)) {
_root.hita = 1;
} else {
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
}
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hitb = 1;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (_root.hitb == 0)) {
_root.hita = 0;
_root.hitc = 0;
_root.hitd = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (_root.hitc == 0)) {
_root.hita = 0;
_root.hitb = 0;
_root.hitd = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (_root.hitd == 0)) {
_root.hita = 0;
_root.hitc = 0;
_root.hitb = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hitc = 1;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (_root.hitd == 0)) {
_root.hita = 0;
_root.hitc = 0;
_root.hitb = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (_root.hitc == 0)) {
_root.hita = 0;
_root.hitb = 0;
_root.hitd = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hitd = 1;
}
}
Instance of Symbol 247 MovieClip in Frame 23
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
if (((_root.hitb == 0) && (_root.hitc == 0)) && (_root.hitd == 0)) {
_root.hita = 1;
} else {
_root.hita = 0;
_root.hitb = 0;
_root.hitc = 0;
_root.hitd = 0;
}
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 23
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 24
secret = 0;
lygis = "level 19";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 3, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 3, 0], [0, 0, 63, 0, 0, 0, 0, 0, 64, 0, 0, 3, 0, 0, 0, 5, 4], [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 5, 74, 4, 7, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 73, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [0, 0, 3, 0, 0, 0, 12, 0, 0, 0, 0, 1, 0, 0, 3, 0, 0], [0, 0, 3, 0, 0, 0, 11, 0, 0, 0, 0, 1, 0, 0, 5, 7, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 3, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile63 = {walkable:true, frame:63};
game.tile64 = {walkable:true, frame:64};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:5, ytile:5, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 19) {
local_data.data.score2 = 19;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 24
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 24
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 192;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip "che" in Frame 24
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (fin == 0) {
this._x = _root.char.clip._x - 16;
this._y = _root.char.clip._y - 26;
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
_root.secret = 1;
fin = 3;
this._x = 10000;
}
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 24
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 25
secretz = 0;
hita = 0;
hitb = 0;
lygis = "level 20";
secret = 0;
secreth = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 5, 4, 4], [1, 1, 1, 1, 1, 1, 0, 0, 3, 1, 1, 1, 1, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 1, 1, 1, 1], [0, 0, 0, 0, 0, 6, 4, 74, 8, 0, 0, 0, 0, 0, 0, 1, 1], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 30, 30, 0, 0, 0, 0, 0], [1, 1, 1, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1], [0, 0, 0, 9, 0, 3, 0, 0, 0, 0, 0, 65, 0, 0, 0, 0, 0], [0, 0, 0, 55, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile55 = {walkable:true, frame:55};
game.tile30 = {walkable:true, frame:30};
game.tile65 = {walkable:true, frame:65};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 20) {
local_data.data.score2 = 20;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 25
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip "lock" in Frame 25
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 96;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 25
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hita = 1;
}
}
Instance of Symbol 247 MovieClip "miau" in Frame 25
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (_root.hita == 1)) {
_root.hitb = 1;
}
if (((_root.hita + _root.hitb) == 2) && (fin == 1)) {
_root.cam.shk = 10;
JumpSound = new Sound();
JumpSound.attachSound("quake");
JumpSound.start();
_root.secret = 1;
_root.secreth = 1;
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 25
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hita = 0;
_root.hitb = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 25
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hita = 0;
_root.hitb = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 25
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hita = 0;
_root.hitb = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 25
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.hita = 0;
_root.hitb = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 25
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Instance of Symbol 424 MovieClip "cam" in Frame 25
onClipEvent (load) {
shake = 0;
shk = 0;
}
onClipEvent (enterFrame) {
shk = shk - 1;
if (shk < 0) {
shk = 0;
shake = 0;
_x = 272;
_y = 208;
}
if (shk > 0) {
shake = 1;
}
randx = 264 + random(16);
randy = 200 + random(16);
if (shake == 1) {
_x = randx;
_y = randy;
}
}
Frame 26
aha = 0;
_root.gad._x = 0;
ab = 0;
ac = 0;
ad = 0;
ae = 0;
lygis = "level 21";
secret = 0;
secretz = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 1], [1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 1], [1, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4, 1], [1, 0, 0, 5, 4, 4, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 3, 0, 0, 0, 66, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 12, 0, 1], [1, 0, 0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, 11, 0, 1], [1, 1, 1, 1, 1, 0, 3, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 1, 3, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile66 = {walkable:true, frame:66};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:10, ytile:10, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 21) {
local_data.data.score2 = 21;
local_data.flush();
}
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 26
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 26
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 450;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 271 MovieClip "kkk" in Frame 26
onClipEvent (enterFrame) {
if ((((_root.ab + _root.ac) + _root.ad) + _root.ae) == 4) {
_root.secret = 1;
} else {
_root.secret = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 26
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 27
secret = 0;
secretz = 0;
tim = 130;
lygis = "level 22";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 0, 3, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 1], [0, 0, 0, 3, 0, 0, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 74, 4, 8, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 30, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0], [0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0], [0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile72 = {walkable:true, frame:72};
game.tile30 = {walkable:true, frame:30};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:7, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 22) {
local_data.data.score2 = 22;
local_data.flush();
}
_root.gad._x = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 27
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 27
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 224;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 27
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.tim < 0) {
_root.secret = 1;
_root.secretz = 1;
}
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip)) {
_root.tim = _root.tim - 1;
} else {
_root.tim = 120;
}
}
Instance of Symbol 271 MovieClip "kkk" in Frame 27
/* no clip actions */
Instance of Symbol 403 MovieClip "gad" in Frame 27
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 28
lygis = "level 23";
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1], [1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1], [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1], [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:21};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile18 = {walkable:true, frame:19};
char = {xtile:13, ytile:6, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.gad._x = 0;
if (local_data.data.score2 < 23) {
local_data.data.score2 = 23;
local_data.flush();
}
Instance of Symbol 429 MovieClip in Frame 28
onClipEvent (mouseDown) {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
startDrag (this, false, -64, 0, 0, 0);
dragging = 1;
_root.sys.drag = 1;
}
}
onClipEvent (mouseUp) {
stopDrag();
}
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 28
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 28
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 29
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 6, 4, 4, 74, 4, 4, 4, 4, 7, 0, 0, 0], [0, 0, 68, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 5, 4, 4, 4], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 67, 0, 0, 1, 1, 0, 0, 12, 0], [0, 0, 0, 0, 6, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1], [0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 3, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile67 = {walkable:true, frame:67};
game.tile68 = {walkable:true, frame:68};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:2, ytile:11, speed:6, jumpstart:20, gravity:1.9, jump:false};
buildMap(myMap1);
fall(char);
stop();
_root.secret = 0;
_root.gad._x = 0;
function exit() {
_root.secret = 1;
}
stop();
var theMenu = new ContextMenu();
theMenu.hideBuiltInItems();
_root.menu = theMenu;
var i1 = new ContextMenuItem(":::Secret Exit:::", exit);
theMenu.customItems[0] = i1;
if (local_data.data.score2 < 24) {
local_data.data.score2 = 24;
local_data.flush();
}
lygis = "level 24";
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 29
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 29
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 474;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 29
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileH);
}
Frame 30
aha = 0;
_root.gad._x = 0;
var theMenu = new ContextMenu();
theMenu.hideBuiltInItems();
_root.menu = theMenu;
var i1 = new ContextMenuItem("", exit);
theMenu.customItems[0] = i1;
secret = 0;
lygis = "level 25";
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 70, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [4, 7, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 71, 0], [0, 3, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0], [1, 3, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1], [0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0], [0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 0], [1, 1, 1, 0, 70, 0, 0, 0, 0, 0, 0, 0, 70, 0, 1, 1, 1], [0, 3, 0, 0, 0, 0, 0, 0, 0, 69, 0, 0, 0, 0, 6, 8, 0], [0, 73, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1], [0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 71, 0, 0, 0, 3, 0, 0], [0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile69 = {walkable:true, frame:69};
game.tile70 = {walkable:true, frame:70};
game.tile71 = {walkable:true, frame:71};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:8, ytile:11, speed:6, jumpstart:20, gravity:1.9, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 25) {
local_data.data.score2 = 25;
local_data.flush();
}
aha = 0;
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 30
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip "mmm" in Frame 30
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 480;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
onClipEvent (load) {
var time = new Date();
hours = time.getHours();
}
onClipEvent (enterFrame) {
var time = new Date();
hours = time.getHours();
if (hours == 0) {
_root.secret = 1;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 30
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 31
_root.gotoAndStop(35);
_root.gad._x = 0;
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 31
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38)) {
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 31
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 31
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 32
secret = 0;
timer = 150;
function exit() {
_root.secret = 1;
}
var theMenu = new ContextMenu();
theMenu.hideBuiltInItems();
_root.menu = theMenu;
var i1 = new ContextMenuItem("", exit);
theMenu.customItems[0] = i1;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 3, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 50, 0, 0, 1, 5, 4], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 51, 0, 0, 1, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 51, 0, 0, 1, 0, 0], [0, 0, 0, 0, 73, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 0, 0, 1, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 6, 4, 4], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1], [0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile22 = {walkable:true, frame:22};
game.tile23 = {walkable:true, frame:23};
game.tile50 = {walkable:true, frame:50};
game.tile51 = {walkable:true, frame:51};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:5, ytile:5, speed:6, jumpstart:20, gravity:1.9, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 10) {
local_data.data.score2 = 10;
local_data.flush();
}
_root.gad._x = 0;
lygis = "level 10";
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 32
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
_root.timer = _root.timer - 1;
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
_root.timer = 150;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
_root.timer = 150;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
_root.timer = 150;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
if (_root.timer < 0) {
_root.secret = 1;
}
}
Instance of Symbol 247 MovieClip in Frame 32
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(159);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 32
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 33
_root.gad._x = 0;
secret = 0;
_root.gad.hra._x = -1000;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 3, 0, 0, 0, 0, 1, 0, 3, 0, 0, 0, 0, 0, 0], [0, 0, 0, 5, 4, 7, 0, 0, 1, 0, 5, 4, 4, 74, 4, 4, 4], [0, 0, 0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0], [0, 9, 0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0], [0, 10, 0, 0, 0, 3, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
game.tile24 = {walkable:true, frame:24};
game.tile25 = {walkable:true, frame:25};
game.tile73 = {walkable:true, frame:73};
game.tile74 = {walkable:true, frame:74};
char = {xtile:6, ytile:7, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
if (local_data.data.score2 < 15) {
local_data.data.score2 = 15;
local_data.flush();
}
lygis = "level 15";
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 33
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 33
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 33
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 34
_root.gotoAndStop(21);
_root.gad._x = 0;
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 34
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38)) {
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 34
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 34
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 35
klasas = 0;
lygis = "THE END";
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:21};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
char = {xtile:-2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 35
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38)) {
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 451 MovieClip "gad" in Frame 35
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 36
_root.gotoAndStop(32);
_root.gad._x = 0;
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 36
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38)) {
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 36
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 36
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Frame 37
secret = 0;
function buildMap(map) {
_root.attachMovie("empty", "tiles", 1);
game.clip = _root.tiles;
var _local6 = map[0].length;
var _local7 = map.length;
var _local4 = 0;
while (_local4 < _local7) {
var _local3 = 0;
while (_local3 < _local6) {
var _local2 = (("t_" + _local4) + "_") + _local3;
game[_local2] = game["tile" + map[_local4][_local3]];
game.clip.attachMovie("tile", _local2, (_local4 * 100) + (_local3 * 2));
game.clip[_local2]._x = _local3 * game.tileW;
game.clip[_local2]._y = _local4 * game.tileH;
game.clip[_local2].gotoAndStop(game[_local2].frame);
_local3++;
}
_local4++;
}
game.clip.attachMovie("char", "char", 10000);
char.clip = game.clip.char;
char.x = (char.xtile * game.tileW) + (game.tileW / 2);
char.y = (char.ytile * game.tileW) + (game.tileW / 2);
char.width = char.clip._width / 2;
char.height = char.clip._height / 2;
char.clip._x = char.x;
char.clip._y = char.y;
}
function getMyCorners(x, y, ob) {
ob.downY = Math.floor(((y + ob.height) - 1) / game.tileH);
ob.upY = Math.floor((y - ob.height) / game.tileH);
ob.leftX = Math.floor((x - ob.width) / game.tileW);
ob.rightX = Math.floor(((x + ob.width) - 1) / game.tileW);
ob.upleft = game[(("t_" + ob.upY) + "_") + ob.leftX].walkable;
ob.downleft = game[(("t_" + ob.downY) + "_") + ob.leftX].walkable;
ob.upright = game[(("t_" + ob.upY) + "_") + ob.rightX].walkable;
ob.downright = game[(("t_" + ob.downY) + "_") + ob.rightX].walkable;
}
function lookCloud(ob) {
var _local2 = game[(("t_" + ob.downY) + "_") + ob.leftX].cloud;
var _local4 = game[(("t_" + ob.downY) + "_") + ob.rightX].cloud;
var _local3 = game[(("t_" + ob.upY) + "_") + ob.leftX].cloud;
var _local5 = game[(("t_" + ob.upY) + "_") + ob.rightX].cloud;
if ((_local2 or _local4) and (!(_local3 or _local5))) {
return(true);
}
return(false);
}
function walk(dirx, diry, ob, speed) {
getMyCorners(ob.x, ob.y + (speed * diry), ob);
if (diry == -1) {
if (ob.upleft and ob.upright) {
ob.y = ob.y + (speed * diry);
} else {
ob.y = (ob.ytile * game.tileH) + ob.height;
if (ob.jump) {
ob.jumpspeed = 0;
}
}
}
if (diry == 1) {
if (ob.downleft and ob.downright) {
if (ob.jump and lookCloud(ob)) {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
} else {
ob.y = ob.y + (speed * diry);
char.clip.gotoAndPlay("jumpd");
}
} else {
ob.y = ((ob.ytile + 1) * game.tileH) - ob.height;
if (ob.jump) {
ob.jump = false;
}
}
}
getMyCorners(ob.x + (speed * dirx), ob.y, ob);
if (dirx == -1) {
char.clip._xscale = -100;
char.clip.gotoAndStop("walk");
char.clip.gotoAndPlay("walk");
if (ob.downleft and ob.upleft) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = (ob.xtile * game.tileW) + ob.width;
}
}
if (dirx == 1) {
char.clip._xscale = 100;
char.clip.gotoAndPlay("walk");
if (ob.upright and ob.downright) {
ob.x = ob.x + (speed * dirx);
fall(ob);
} else {
ob.x = ((ob.xtile + 1) * game.tileW) - ob.width;
}
}
ob.clip._x = ob.x;
ob.clip._y = ob.y;
ob.xtile = Math.floor(ob.clip._x / game.tileW);
ob.ytile = Math.floor(ob.clip._y / game.tileH);
}
function jump(ob) {
ob.jumpspeed = ob.jumpspeed - ob.gravity;
if (ob.jumpspeed > 0) {
char.clip.gotoAndPlay("jump");
walk(0, -1, ob, ob.jumpspeed);
} else if (ob.jumpspeed < 0) {
walk(0, 1, ob, -ob.jumpspeed);
}
}
function fall(ob) {
if (!ob.jump) {
getMyCorners(ob.x, ob.y, ob);
if ((ob.downleft and ob.downright) and (!lookCloud(ob))) {
ob.jumpspeed = 0;
ob.jump = true;
}
}
}
myMap1 = [[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
myMapz = [[1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]];
game = {tileW:32, tileH:32};
game.tile0 = {walkable:true, frame:1};
game.tile1 = {walkable:false, frame:2};
game.tile2 = {walkable:true, frame:3, cloud:true};
game.tile3 = {walkable:true, frame:4};
game.tile4 = {walkable:true, frame:5};
game.tile5 = {walkable:true, frame:6};
game.tile6 = {walkable:true, frame:7};
game.tile7 = {walkable:true, frame:8};
game.tile8 = {walkable:true, frame:9};
game.tile9 = {walkable:true, frame:10};
game.tile10 = {walkable:true, frame:11};
game.tile11 = {walkable:true, frame:12};
game.tile12 = {walkable:true, frame:13};
game.tile13 = {walkable:true, frame:14};
game.tile14 = {walkable:true, frame:15};
game.tile15 = {walkable:true, frame:16};
game.tile16 = {walkable:true, frame:17};
char = {xtile:2, ytile:11, speed:6, jumpstart:21, gravity:2, jump:false};
buildMap(myMap1);
fall(char);
stop();
Instance of Symbol 151 MovieClip [empty] "controller" in Frame 37
onClipEvent (load) {
stand = 0;
}
onClipEvent (enterFrame) {
var dirx = 0;
var diry = 0;
if (Key.isDown(38)) {
}
if (Key.isDown(40)) {
}
if (Key.isDown(37)) {
dirx = -1;
stand = 1;
}
if (Key.isDown(39)) {
dirx = 1;
stand = 1;
}
if ((!Key.isDown(37)) && (!Key.isDown(39))) {
stand = 0;
}
if (Key.isDown(32) and (!_root.char.jump)) {
_root.char.jump = true;
_root.char.jumpspeed = _root.char.jumpstart;
}
if ((dirx != 0) or (diry != 0)) {
_root.walk(dirx, diry, _root.char, _root.char.speed);
}
if (_root.char.jump) {
_root.jump(_root.char);
_root.char.gotoAndStop("jump");
}
}
Instance of Symbol 247 MovieClip in Frame 37
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_parent.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 247 MovieClip in Frame 37
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip)) {
_parent.char.xtile = 19;
}
}
Instance of Symbol 247 MovieClip in Frame 37
onClipEvent (enterFrame) {
if (this.hitTest(_parent.char.clip)) {
_parent.char.xtile = 1;
}
}
Instance of Symbol 403 MovieClip "gad" in Frame 37
onClipEvent (enterFrame) {
this.swapDepths(_root.game.tileW);
}
Symbol 24 MovieClip Frame 1
stop();
Symbol 24 MovieClip Frame 2
stop();
Symbol 26 MovieClip Frame 1
stop();
Symbol 26 MovieClip Frame 2
stop();
Symbol 28 MovieClip Frame 1
stop();
Symbol 28 MovieClip Frame 2
stop();
Symbol 30 MovieClip Frame 1
stop();
Symbol 30 MovieClip Frame 2
stop();
Symbol 31 MovieClip Frame 1
stop();
Symbol 31 MovieClip Frame 2
stop();
Symbol 36 Button
on (press) {
score = score + 10;
}
Symbol 38 MovieClip Frame 1
stop();
score = 0;
Symbol 38 MovieClip Frame 2
stop();
_root.secret = 1;
Symbol 39 MovieClip Frame 1
stop();
Symbol 71 MovieClip Frame 1
stop();
Symbol 71 MovieClip Frame 2
stop();
Symbol 90 MovieClip Frame 1
stop();
Symbol 90 MovieClip Frame 50
stop();
Symbol 110 MovieClip Frame 2
stop();
Symbol 110 MovieClip Frame 3
stop();
Instance of Symbol 24 MovieClip in Symbol 130 MovieClip [tile] Frame 12
onClipEvent (enterFrame) {
if (_root.secret == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 26 MovieClip in Symbol 130 MovieClip [tile] Frame 13
onClipEvent (enterFrame) {
if (_root.secret == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 28 MovieClip in Symbol 130 MovieClip [tile] Frame 14
onClipEvent (enterFrame) {
if (_root.secret == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 30 MovieClip in Symbol 130 MovieClip [tile] Frame 15
onClipEvent (enterFrame) {
if (_root.secret == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 31 MovieClip in Symbol 130 MovieClip [tile] Frame 16
onClipEvent (enterFrame) {
if (_root.secret == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 38 MovieClip "bbb" in Symbol 130 MovieClip [tile] Frame 17
onClipEvent (load) {
}
onClipEvent (enterFrame) {
this.score = this.score - 1;
if (this.score < 0) {
this.score = 0;
}
if (score > 80) {
this.gotoAndStop(2);
}
}
Instance of Symbol 39 MovieClip in Symbol 130 MovieClip [tile] Frame 18
onClipEvent (enterFrame) {
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
this.gotoAndStop(2);
}
}
Instance of Symbol 24 MovieClip in Symbol 130 MovieClip [tile] Frame 19
onClipEvent (enterFrame) {
if (_root.secreta == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 26 MovieClip in Symbol 130 MovieClip [tile] Frame 20
onClipEvent (enterFrame) {
if (_root.secreta == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 71 MovieClip in Symbol 130 MovieClip [tile] Frame 44
onClipEvent (enterFrame) {
if (_root.secret == 1) {
gotoAndStop (2);
}
}
Instance of Symbol 39 MovieClip in Symbol 130 MovieClip [tile] Frame 52
onClipEvent (enterFrame) {
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
this.gotoAndStop(2);
}
}
Instance of Symbol 90 MovieClip in Symbol 130 MovieClip [tile] Frame 55
onClipEvent (load) {
ups = 0;
}
onClipEvent (enterFrame) {
if ((_root.secret == 1) && (ups == 0)) {
this.play();
ups = 1;
}
}
Instance of Symbol 39 MovieClip in Symbol 130 MovieClip [tile] Frame 56
onClipEvent (enterFrame) {
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
this.gotoAndStop(2);
}
}
Instance of Symbol 110 MovieClip in Symbol 130 MovieClip [tile] Frame 64
onClipEvent (enterFrame) {
if (_root.che.fin == 0) {
if (Math.sqrt(((_root.che._y - _root.mice._y) * (_root.che._y - _root.mice._y)) + ((_root.che._x - _root.mice._x) * (_root.che._x - _root.mice._x))) < 100) {
this.gotoAndStop(3);
} else {
this.gotoAndStop(2);
}
}
}
Instance of Symbol 39 MovieClip in Symbol 130 MovieClip [tile] Frame 68
onClipEvent (enterFrame) {
if (this.hitTest(_root._xmouse, _root._ymouse, true)) {
this.gotoAndStop(2);
}
}
Instance of Symbol 128 MovieClip in Symbol 130 MovieClip [tile] Frame 73
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Symbol 133 MovieClip Frame 1
stop();
Symbol 136 MovieClip Frame 1
JumpSound = new Sound();
JumpSound.attachSound("jumpSound");
JumpSound.start();
Symbol 136 MovieClip Frame 9
gotoAndPlay ("loop");
Symbol 139 MovieClip Frame 9
gotoAndPlay ("loop");
Symbol 149 MovieClip Frame 16
gotoAndPlay (1);
Symbol 150 MovieClip [char] Frame 1
stop();
Symbol 150 MovieClip [char] Frame 4
stop();
Symbol 150 MovieClip [char] Frame 7
stop();
Symbol 150 MovieClip [char] Frame 10
stop();
Symbol 165 MovieClip Frame 1
stop();
Instance of Symbol 157 MovieClip "bar1" in Symbol 165 MovieClip Frame 1
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Symbol 165 MovieClip Frame 2
stop();
Symbol 167 Button
on (release) {
getURL ("http://www.gamesbutler.com", "_blank");
}
Symbol 171 Button
on (release) {
play();
}
Symbol 172 MovieClip Frame 13
stop();
Symbol 172 MovieClip Frame 18
stop();
_parent.play();
Symbol 190 MovieClip Frame 53
stop();
Symbol 196 MovieClip Frame 15
stop();
Symbol 198 MovieClip Frame 15
stop();
Symbol 199 MovieClip Frame 1
_root.stop();
Symbol 199 MovieClip Frame 24
stop();
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 29
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 31
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 33
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 35
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 37
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 39
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Symbol 199 MovieClip Frame 40
stop();
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 41
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 43
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 45
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 47
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 49
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 51
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 53
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 55
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 57
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 59
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 61
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 63
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 65
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 67
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 69
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 71
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 73
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 75
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 77
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 79
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 81
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 83
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 85
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 87
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 89
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 91
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 93
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 95
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 97
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 99
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 101
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 103
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 105
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 107
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 109
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 111
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 113
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 115
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 117
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 119
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 121
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 123
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 125
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 127
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 129
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 131
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 133
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 135
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 137
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 139
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 141
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 143
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 145
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 147
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 149
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 151
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 153
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 155
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 157
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 159
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 161
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 163
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 165
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 167
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 169
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 171
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 173
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 175
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 177
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 179
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 181
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 183
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 185
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 187
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 189
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 191
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 193
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 195
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 197
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 199
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 201
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 203
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 205
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 207
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 209
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 211
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 213
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 215
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 217
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 219
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 221
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 223
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 225
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Instance of Symbol 157 MovieClip "bar1" in Symbol 199 MovieClip Frame 227
onClipEvent (load) {
function startMovie() {
gotoAndStop (2);
_root.preloader.play();
}
loadingComplete = false;
}
onClipEvent (enterFrame) {
loaded = _root.getBytesLoaded() / _root.getBytesTotal();
this._xscale = 100 * loaded;
if (!loadingComplete) {
if (loaded == 1) {
loadingComplete = true;
}
} else {
startMovie();
}
}
Symbol 199 MovieClip Frame 228
_root.play();
Symbol 223 MovieClip Frame 112
_root.nextFrame();
Symbol 231 Button
on (release) {
if (_root.btn == 0) {
_root.gads.gotoAndPlay(27);
_root.btn = 1;
}
}
Symbol 233 Button
on (release) {
getURL ("http://www.gamesbutler.com/", _blank);
}
Symbol 235 Button
on (release) {
getURL ("http://www.gamesbutler.com/game/3657/Secret_Exit_Walkthrough/", _blank);
if (_global.score > 13) {
getURL ("http://www.gamesbutler.com/game/3657/Secret_Exit_Walkthrough/", _blank);
_global.okay = 1;
}
}
Symbol 237 Button
on (release) {
gotoAndStop (2);
}
Symbol 240 MovieClip Frame 1
stop();
Symbol 240 MovieClip Frame 2
stop();
Symbol 242 Button
on (press) {
gotoAndStop (2);
}
Symbol 245 Button
on (rollOut, dragOut) {
gotoAndStop (1);
}
Symbol 246 MovieClip Frame 1
stop();
Symbol 246 MovieClip Frame 2
stop();
Symbol 253 MovieClip Frame 26
stop();
Symbol 253 MovieClip Frame 27
play();
Symbol 253 MovieClip Frame 43
_root.nextFrame();
Symbol 253 MovieClip Frame 71
stop();
Symbol 253 MovieClip Frame 72
play();
Symbol 253 MovieClip Frame 87
stopAllSounds();
Symbol 253 MovieClip Frame 88
_parent.gad._y = 0;
_parent.gad.gotoAndPlay(1);
if (_root.lvl == 0) {
_global.ext = 0;
_root.gotoAndStop(3);
}
if (_root.lvl == 1) {
_global.ext = 0;
_root.gotoAndStop(5);
}
if (_root.lvl == 2) {
_global.ext = 0;
_root.gotoAndStop(6);
}
if (_root.lvl == 3) {
_global.ext = 0;
_root.gotoAndStop(7);
}
if (_root.lvl == 4) {
_global.ext = 0;
_root.gotoAndStop(8);
}
if (_root.lvl == 5) {
_global.ext = 0;
_root.gotoAndStop(9);
}
if (_root.lvl == 6) {
_global.ext = 0;
_root.gotoAndStop(10);
}
if (_root.lvl == 7) {
_global.ext = 0;
_root.gotoAndStop(11);
}
if (_root.lvl == 8) {
_global.ext = 0;
_root.gotoAndStop(12);
}
if (_root.lvl == 9) {
_global.ext = 0;
_root.gotoAndStop(13);
}
if (_root.lvl == 10) {
_root.gotoAndStop(14);
}
if (_root.lvl == 11) {
_global.ext = 0;
_root.gotoAndStop(15);
}
if (_root.lvl == 12) {
_global.ext = 0;
_root.gotoAndStop(16);
}
if (_root.lvl == 13) {
_global.ext = 0;
_root.gotoAndStop(17);
}
if (_root.lvl == 14) {
_global.ext = 0;
_root.gotoAndStop(18);
}
if (_root.lvl == 15) {
_global.ext = 0;
_root.gotoAndStop(19);
}
if (_root.lvl == 16) {
_global.ext = 0;
_root.gotoAndStop(20);
}
if (_root.lvl == 17) {
_global.ext = 0;
_root.gotoAndStop(21);
}
if (_root.lvl == 18) {
_global.ext = 0;
_root.gotoAndStop(22);
}
if (_root.lvl == 19) {
_global.ext = 0;
_root.gotoAndStop(23);
}
if (_root.lvl == 20) {
_global.ext = 0;
_root.gotoAndStop(24);
}
if (_root.lvl == 21) {
_global.ext = 0;
_root.gotoAndStop(25);
}
if (_root.lvl == 22) {
_global.ext = 0;
_root.gotoAndStop(26);
}
if (_root.lvl == 23) {
_global.ext = 0;
_root.gotoAndStop(27);
}
if (_root.lvl == 24) {
_global.ext = 0;
_root.gotoAndStop(28);
}
if (_root.lvl == 25) {
_global.ext = 0;
_root.gotoAndStop(29);
}
if (_root.lvl == 26) {
_global.ext = 0;
_root.gotoAndStop(30);
}
if (_root.lvl == 27) {
_global.ext = 0;
_root.gotoAndStop(36);
}
if (_root.lvl == 28) {
_global.ext = 0;
_root.gotoAndStop(32);
}
if (_root.lvl == 29) {
_global.ext = 0;
_root.gotoAndStop(33);
}
if (_root.lvl == 30) {
_global.ext = 0;
_root.gotoAndStop(34);
}
Symbol 253 MovieClip Frame 89
play();
Symbol 253 MovieClip Frame 105
_root.gotoAndStop(4);
this.gotoAndPlay(1);
Symbol 253 MovieClip Frame 208
_root.nextFrame();
Symbol 257 Button
on (press) {
nextFrame();
}
Symbol 267 MovieClip Frame 1
stop();
Symbol 267 MovieClip Frame 7
_root.ab = 1;
Symbol 267 MovieClip Frame 8
_root.ab = 0;
Symbol 267 MovieClip Frame 11
gotoAndStop (1);
Symbol 268 MovieClip Frame 1
stop();
Symbol 268 MovieClip Frame 9
_root.ac = 1;
Symbol 268 MovieClip Frame 10
_root.ac = 0;
Symbol 268 MovieClip Frame 11
gotoAndStop (1);
Symbol 269 MovieClip Frame 1
stop();
Symbol 269 MovieClip Frame 7
_root.ad = 1;
Symbol 269 MovieClip Frame 8
_root.ad = 0;
Symbol 269 MovieClip Frame 11
gotoAndStop (1);
Symbol 270 MovieClip Frame 1
stop();
Symbol 270 MovieClip Frame 5
_root.ae = 1;
Symbol 270 MovieClip Frame 6
_root.ae = 0;
Symbol 270 MovieClip Frame 11
gotoAndStop (1);
Symbol 271 MovieClip Frame 1
stop();
Symbol 283 Button
on (release) {
if (_root.btn == 0) {
_root.gads.gotoAndPlay(89);
_root.btn = 1;
}
}
Symbol 287 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 3;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 290 Button
on (release) {
if (hit == 0) {
_root.lvl = 2;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
hit = 1;
}
}
Symbol 292 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 4;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 295 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 5;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 298 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 6;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 301 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 8;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 304 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 9;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 307 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 10;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 310 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
if (_global.score >= 15) {
_root.lvl = 27;
} else {
_root.lvl = 11;
}
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 313 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 13;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 316 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 14;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 319 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 15;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 322 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 16;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 325 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 18;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 328 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 19;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 331 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 20;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 334 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 21;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 337 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 23;
_root.gad.pff._xscale = 100;
_root.gad.pff._yscale = 100;
_root.gad.pff.sss = 0;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 340 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 24;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 343 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 25;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 346 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 26;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 349 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 7;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 352 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 12;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 355 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 17;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 358 Button
on (release) {
if ((_parent.hit == 0) && (_alpha == 100)) {
_parent.hit = 1;
_root.lvl = 22;
_root.gads.gotoAndPlay(72);
gotoAndStop (2);
}
}
Symbol 360 MovieClip Frame 1
hit = 0;
if (_root.lvl > 1) {
} else {
_root.lvl = 1;
}
_root.lvl = sharedobject.getLocal("game");
setProperty(_root.lvl, _x , _root.lvl.data.lvl);
Instance of Symbol 288 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 1) {
_x = 50;
}
}
Instance of Symbol 293 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 2) {
_x = 100;
}
}
Instance of Symbol 296 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 3) {
_x = 150;
}
}
Instance of Symbol 299 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 4) {
_x = 200;
}
}
Instance of Symbol 302 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 6) {
_x = 50;
}
}
Instance of Symbol 305 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 7) {
_x = 100;
}
}
Instance of Symbol 308 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 8) {
_x = 150;
}
}
Instance of Symbol 311 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 9) {
_x = 200;
}
}
Instance of Symbol 314 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 11) {
_x = 50;
}
}
Instance of Symbol 317 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 12) {
_x = 100;
}
}
Instance of Symbol 320 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 13) {
_x = 150;
}
}
Instance of Symbol 323 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 14) {
_x = 200;
}
}
Instance of Symbol 326 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 16) {
_x = 50;
}
}
Instance of Symbol 329 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 17) {
_x = 100;
}
}
Instance of Symbol 332 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 18) {
_x = 150;
}
}
Instance of Symbol 335 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 19) {
_x = 200;
}
}
Instance of Symbol 338 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 21) {
_x = 50;
}
}
Instance of Symbol 341 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 22) {
_x = 100;
}
}
Instance of Symbol 344 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 23) {
_x = 150;
}
}
Instance of Symbol 347 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 24) {
_x = 200;
}
}
Instance of Symbol 350 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 5) {
_x = 0;
}
}
Instance of Symbol 353 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 10) {
_x = 0;
}
}
Instance of Symbol 356 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 15) {
_x = 0;
}
}
Instance of Symbol 359 MovieClip in Symbol 360 MovieClip Frame 1
onClipEvent (enterFrame) {
if (_global.score > 20) {
_x = 0;
}
}
Symbol 366 MovieClip Frame 1
stop();
Symbol 366 MovieClip Frame 12
stop();
Symbol 392 Button
on (press) {
if (_root.secreta == 0.5) {
_root.secreta = 1;
} else {
_root.secreta = 0.1;
}
_quality = "low";
}
Symbol 393 Button
on (press) {
_quality = "medium";
if (_root.secreta == 0) {
_root.secreta = 0.5;
} else {
_root.secreta = 0.1;
}
}
Symbol 394 Button
on (press) {
_root.secreta = 0;
_quality = "high";
}
Symbol 395 Button
on (release) {
_global.ext = 1;
_parent.gotoAndPlay(161);
}
Symbol 396 Button
on (release) {
JumpSound = new Sound();
JumpSound.attachSound("jumpSound");
JumpSound.setVolume(0);
nextFrame();
_global.mute = 1;
}
Symbol 397 Button
on (release) {
JumpSound = new Sound();
JumpSound.attachSound("jumpSound");
JumpSound.setVolume(100);
prevFrame();
_global.mute = 0;
}
Symbol 398 MovieClip Frame 1
if (_global.mute == 1) {
gotoAndStop (3);
} else {
gotoAndStop (2);
}
Symbol 398 MovieClip Frame 2
stop();
Symbol 398 MovieClip Frame 3
stop();
Instance of Symbol 274 MovieClip in Symbol 403 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.kkk2._x;
_y = _root.kkk2._y;
if (this.hitTest(_root.lock)) {
_parent.loks.play();
this._x = -1000;
_root.secret = 1;
}
if (!(_root.aha === 1)) {
_x = -1000;
}
}
Instance of Symbol 271 MovieClip in Symbol 403 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.kkk._x;
_y = _root.kkk._y;
}
Instance of Symbol 363 MovieClip in Symbol 403 MovieClip Frame 1
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
_x = _root.che._x;
_y = _root.che._y;
}
Instance of Symbol 365 MovieClip in Symbol 403 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.ogi._x;
_y = _root.ogi._y;
}
Instance of Symbol 365 MovieClip in Symbol 403 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.ogo._x;
_y = _root.ogo._y;
}
Instance of Symbol 366 MovieClip in Symbol 403 MovieClip Frame 1
onClipEvent (load) {
aaa = 0;
}
onClipEvent (enterFrame) {
_x = _root.kkk8._x;
_y = _root.kkk8._y;
if ((_root.secreth == 1) && (aaa == 0)) {
aaa = 1;
this.play();
}
}
Instance of Symbol 281 MovieClip "pff" in Symbol 403 MovieClip Frame 1
onClipEvent (load) {
argh = 0;
gotoAndStop (1);
}
onClipEvent (enterFrame) {
_x = _root.ugh._x;
_y = _root.ugh._y;
sss = 1;
fff = 0.3;
}
onClipEvent (enterFrame) {
if (_root.secretz == 0) {
x = _root.char.clip._x - this._x;
y = _root.char.clip._y - this._y;
r = Math.sqrt((x * x) + (y * y));
theta = Math.asin(y / r);
if (_root.char.clip._x < this._x) {
this._rotation = 180 - (theta / 0.0175);
} else if (_root.char.clip._x > this._x) {
this._rotation = theta / 0.0175;
}
} else {
argh = argh + fff;
_rotation = (_rotation + (5 + argh));
_xscale = (_xscale - sss);
_yscale = (_yscale - sss);
}
if (_xscale < 0) {
_xscale = 0;
_yscale = 0;
sss = 0;
}
}
Instance of Symbol 370 MovieClip in Symbol 403 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.la01._x;
_y = _root.la01._y;
}
Instance of Symbol 277 MovieClip "hrb" in Symbol 403 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.tele._x;
_y = _root.tele._y;
}
Instance of Symbol 372 MovieClip "hra" in Symbol 403 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.tele2._x;
_y = _root.tele2._y;
}
Symbol 403 MovieClip Frame 26
stop();
Symbol 403 MovieClip Frame 160
_parent.gad._x = 0;
_root.nextFrame();
gotoAndPlay (1);
Instance of Symbol 274 MovieClip in Symbol 403 MovieClip Frame 161
onClipEvent (mouseDown) {
if (this.hitTest(_root._xmouse, _root._ymouse)) {
startDrag (this);
dragging = 1;
_root.sys.drag = 1;
}
}
onClipEvent (mouseUp) {
if (dragging) {
stopDrag();
X = this._x;
Y = this._y;
if (_root.selected == "normal") {
this._x = Math.round(X / _root.gridSpacing) * _root.gridSpacing;
this._y = Math.round(Y / _root.gridSpacing) * _root.gridSpacing;
}
if (_root.selected == "rand") {
smallestX = 1000;
smallestY = 1000;
i = 0;
while (i < _root.numLines) {
difX = Math.round(Math.abs(gridX[i] - X));
difY = Math.round(Math.abs(gridY[i] - Y));
diffX[difX] = i;
diffY[difY] = i;
smallestX = Math.min(smallestX, difX);
smallestY = Math.min(smallestY, difY);
i++;
}
this._x = gridX[diffX[smallestX]];
this._y = gridY[diffY[smallestY]];
}
dragging = 0;
_root.sys.drag = 0;
}
}
onClipEvent (enterFrame) {
_x = _root.kkk2._x;
_y = _root.kkk2._y;
if (this.hitTest(_root.lock)) {
this._x = -1000;
_root.secret = 1;
}
if (!(_root.aha === 1)) {
_x = -1000;
}
}
Instance of Symbol 271 MovieClip in Symbol 403 MovieClip Frame 161
onClipEvent (enterFrame) {
_x = _root.kkk._x;
_y = _root.kkk._y;
if (this.myInput == "wywh") {
_root.secret = 1;
}
}
Symbol 403 MovieClip Frame 176
stopAllSounds();
Symbol 403 MovieClip Frame 177
_root.gotoAndStop(4);
Symbol 411 MovieClip Frame 1
stop();
Instance of Symbol 247 MovieClip in Symbol 411 MovieClip Frame 1
onClipEvent (enterFrame) {
if (Key.isDown(53)) {
_parent.gotoAndStop(2);
}
}
Symbol 411 MovieClip Frame 2
stop();
_root.to = 1;
Symbol 413 MovieClip Frame 1
stop();
Instance of Symbol 247 MovieClip in Symbol 413 MovieClip Frame 1
onClipEvent (enterFrame) {
if (Key.isDown(52)) {
if (_root.to == 1) {
_parent.gotoAndStop(2);
}
}
}
Symbol 413 MovieClip Frame 2
stop();
_root.fo = 1;
Symbol 415 MovieClip Frame 1
stop();
Instance of Symbol 247 MovieClip in Symbol 415 MovieClip Frame 1
onClipEvent (enterFrame) {
if (Key.isDown(50)) {
if (_root.fo == 1) {
_parent.gotoAndStop(2);
}
}
}
Symbol 415 MovieClip Frame 2
stop();
_root.fi = 1;
_root.secret = 1;
Symbol 424 MovieClip Frame 1
function camControl() {
parentColor.setTransform(camColor.getTransform());
var _local4 = sX / this._width;
var _local3 = sY / this._height;
_parent._x = cX - (this._x * _local4);
_parent._y = cY - (this._y * _local3);
_parent._xscale = 100 * _local4;
_parent._yscale = 100 * _local3;
}
function resetStage() {
var _local2 = {ra:100, rb:0, ga:100, gb:0, ba:100, bb:0, aa:100, ab:0};
parentColor.setTransform(_local2);
_parent._xscale = 100;
_parent._yscale = 100;
_parent._x = 0;
_parent._y = 0;
}
parentColor.setTransform(camColor.getTransform());
this._visible = false;
var oldMode = Stage.scaleMode;
Stage.scaleMode = "exactFit";
var cX = (Stage.width / 2);
var cY = (Stage.height / 2);
var sX = Stage.width;
var sY = Stage.height;
Stage.scaleMode = oldMode;
var camColor = new Color(this);
var parentColor = new Color(_parent);
this.onEnterFrame = camControl;
camControl();
this.onUnload = resetStage;
Instance of Symbol 247 MovieClip in Symbol 429 MovieClip Frame 1
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
if (_root.secret == 1) {
this._x = 32;
}
if (this.hitTest(_root.char.clip) && (fin == 1)) {
_root.gad.gotoAndPlay(27);
fin = 0;
}
}
Instance of Symbol 128 MovieClip in Symbol 429 MovieClip Frame 1
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Instance of Symbol 128 MovieClip in Symbol 429 MovieClip Frame 1
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Instance of Symbol 128 MovieClip in Symbol 437 MovieClip Frame 1
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Instance of Symbol 128 MovieClip in Symbol 437 MovieClip Frame 1
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Instance of Symbol 128 MovieClip in Symbol 437 MovieClip Frame 1
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Instance of Symbol 128 MovieClip in Symbol 437 MovieClip Frame 1
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Instance of Symbol 128 MovieClip in Symbol 437 MovieClip Frame 1
onClipEvent (load) {
kebab = random(8000);
}
onClipEvent (enterFrame) {
_rotation = (_rotation + (-4 + (kebab / 1000)));
}
Instance of Symbol 437 MovieClip in Symbol 445 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = (_x - 0.3);
}
Symbol 449 MovieClip Frame 17
stop();
Symbol 449 MovieClip Frame 33
stopAllSounds();
Symbol 449 MovieClip Frame 34
_root.gotoAndStop(4);
Symbol 450 Button
on (release) {
if (_root.klasas == 0) {
_global.ext = 1;
_root.klasas = 1;
ssss.gotoAndPlay(18);
}
}
Instance of Symbol 274 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.kkk2._x;
_y = _root.kkk2._y;
if (this.hitTest(_root.lock)) {
_parent.loks.play();
this._x = -1000;
_root.secret = 1;
}
if (!(_root.aha === 1)) {
_x = -1000;
}
}
Instance of Symbol 271 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.kkk._x;
_y = _root.kkk._y;
}
Instance of Symbol 363 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (load) {
fin = 1;
}
onClipEvent (enterFrame) {
_x = _root.che._x;
_y = _root.che._y;
}
Instance of Symbol 365 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.ogi._x;
_y = _root.ogi._y;
}
Instance of Symbol 365 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.ogo._x;
_y = _root.ogo._y;
}
Instance of Symbol 366 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (load) {
aaa = 0;
}
onClipEvent (enterFrame) {
_x = _root.kkk8._x;
_y = _root.kkk8._y;
if ((_root.secreth == 1) && (aaa == 0)) {
aaa = 1;
this.play();
}
}
Instance of Symbol 281 MovieClip "pff" in Symbol 451 MovieClip Frame 1
onClipEvent (load) {
argh = 0;
gotoAndStop (1);
}
onClipEvent (enterFrame) {
_x = _root.ugh._x;
_y = _root.ugh._y;
sss = 1;
fff = 0.3;
}
onClipEvent (enterFrame) {
if (_root.secretz == 0) {
x = _root.char.clip._x - this._x;
y = _root.char.clip._y - this._y;
r = Math.sqrt((x * x) + (y * y));
theta = Math.asin(y / r);
if (_root.char.clip._x < this._x) {
this._rotation = 180 - (theta / 0.0175);
} else if (_root.char.clip._x > this._x) {
this._rotation = theta / 0.0175;
}
} else {
argh = argh + fff;
_rotation = (_rotation + (5 + argh));
_xscale = (_xscale - sss);
_yscale = (_yscale - sss);
}
if (_xscale < 0) {
_xscale = 0;
_yscale = 0;
sss = 0;
}
}
Instance of Symbol 370 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.la01._x;
_y = _root.la01._y;
}
Instance of Symbol 277 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.tele._x;
_y = _root.tele._y;
}
Instance of Symbol 372 MovieClip in Symbol 451 MovieClip Frame 1
onClipEvent (enterFrame) {
_x = _root.tele2._x;
_y = _root.tele2._y;
}
Symbol 451 MovieClip Frame 17
stop();