Frame 1
_root._xscale = 117;
_root._yscale = 120;
Frame 2
stop();
this.onEnterFrame = function () {
var _local2 = (this.getBytesLoaded() / this.getBytesTotal()) * 100;
frame = int(_local2);
loadBar.gotoAndStop(frame / 2);
if (_local2 == 100) {
gotoAndPlay (4);
delete this.onEnterFrame;
}
};
Frame 4
function defineLayouts() {
ly11 = [[[0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 2], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [8, 0], [8, 0]], [[8, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 3], [0, 3]], [[0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0]]];
ly12 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 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]]];
ly13 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 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, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
ly14 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 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, 1], [0, 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, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
ly15 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 4], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
layout1 = [ly11, ly12, ly13, ly14, ly15];
ly21 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
ly22 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
ly23 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 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, 1], [0, 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, 1], [0, 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, 1], [0, 1], [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, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 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]]];
ly24 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
ly25 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
layout2 = [ly21, ly22, ly23, ly24, ly25];
ly31 = [[[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0]]];
ly32 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 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]]];
ly33 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 1], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 1], [0, 1], [0, 1], [0, 1], [0, 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, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
ly34 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 0], [0, 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], [0, 1], [0, 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, 1], [0, 1], [0, 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, 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, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
ly35 = [[[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 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], [0, 0], [0, 0], [0, 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], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]], [[0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0], [0, 0]]];
layout3 = [ly31, ly32, ly33, ly34, ly35];
layouts = [0, layout1, layout2, layout3];
}
function createTileList() {
delete tiles;
tiles = {};
tiles.types = new Array("ball", "bamboo", "char", "season", "wind", "flower", "dragon");
tiles.ball = new Array(1, 4, 4, 4, 4, 4, 4, 4, 4, 4);
tiles.bamboo = new Array(1, 4, 4, 4, 4, 4, 4, 4, 4, 4);
tiles.char = new Array(1, 4, 4, 4, 4, 4, 4, 4, 4, 4);
tiles.season = new Array(1, 1, 1, 1, 1);
tiles.wind = new Array(1, 4, 4, 4, 4);
tiles.flower = new Array(1, 1, 1, 1, 1);
tiles.dragon = new Array(1, 4, 4, 4);
tiles.count = 0;
delete tiles2;
tiles2 = {};
tiles2.types = new Array("ball", "bamboo", "char", "season", "wind", "flower", "dragon");
tiles2.ball = new Array(1, 4, 4, 4, 4, 4, 4, 4, 4, 4);
tiles2.bamboo = new Array(1, 4, 4, 4, 4, 4, 4, 4, 4, 4);
tiles2.char = new Array(1, 4, 4, 4, 4, 4, 4, 4, 4, 4);
tiles2.season = new Array(1, 1, 1, 1, 1);
tiles2.wind = new Array(1, 4, 4, 4, 4);
tiles2.flower = new Array(1, 1, 1, 1, 1);
tiles2.dragon = new Array(1, 4, 4, 4);
}
function copyTiles() {
var _local3 = 0;
var _local2 = 0;
while (_local2 < tiles.types.length) {
var _local1 = 0;
while (_local1 < tiles[tiles.types[_local2]].length) {
if (_local1 > 0) {
_local3 = _local3 + tiles2[tiles2.types[_local2]][_local1];
}
tiles[tiles.types[_local2]][_local1] = tiles2[tiles2.types[_local2]][_local1];
_local1++;
}
if (_local3 == 0) {
tiles2[tiles.types[_local2]][0] = 0;
tiles[tiles.types[_local2]][0] = 0;
}
_local3 = 0;
_local2++;
}
}
function createTileList2() {
delete tiles;
tiles = {};
tiles.types = new Array("ball", "bamboo", "char", "season", "wind", "flower", "dragon");
tiles.ball = new Array(1, 0, 0, 2, 0, 0, 2, 0, 0, 0);
tiles.bamboo = new Array(1, 0, 0, 0, 2, 0, 0, 0, 2, 0);
tiles.char = new Array(1, 2, 0, 0, 0, 2, 0, 0, 0, 0);
tiles.season = new Array(1, 1, 1, 1, 1);
tiles.wind = new Array(1, 0, 2, 0, 0);
tiles.flower = new Array(0, 0, 0, 0, 0);
tiles.dragon = new Array(1, 2, 0, 2);
tiles.count = 61;
}
function createBoard() {
board.removeMovieClip();
_root.createEmptyMovieClip("board", 5);
_root.board._x = 23;
_root.board._y = 30;
var _local19 = layouts[game.layout];
var _local20 = _local19.length;
var _local9 = 0;
var _local10 = _local20 - 1;
var _local21 = 0;
shrinker = 87;
cellWidth = 41 * (shrinker / 100);
cellHeight = 50 * (shrinker / 100);
var _local17 = 7 * (shrinker / 100);
var _local16 = 6 * (shrinker / 100);
if (!rRT) {
var _local18 = 0;
while (_local18 < _local20) {
_root["b" + _local18] = _local19[_local18];
_local18++;
}
} else {
var _local13 = 0;
while (_local13 < 5) {
var _local11 = 0;
while (_local11 < 8) {
var _local8 = 0;
while (_local8 < 15) {
if (_root["b" + _local13][_local11][_local8][0] == 6) {
_root["b" + _local13][_local11][_local8][1] = 0;
}
if (_root["b" + _local13][_local11][_local8][0] != 8) {
_root["b" + _local13][_local11][_local8][0] = 0;
}
_local8++;
}
_local11++;
}
_local13++;
}
}
var _local25 = {ra:"90", rb:"30", ga:"90", gb:"0", ba:"90", bb:"0", aa:"100", ab:"0"};
var _local26 = {ra:"85", rb:"0", ga:"85", gb:"0", ba:"85", bb:"0", aa:"100", ab:"0"};
var _local24 = {ra:"90", rb:"0", ga:"90", gb:"30", ba:"90", bb:"0", aa:"100", ab:"0"};
var _local23 = {ra:"90", rb:"0", ga:"90", gb:"0", ba:"90", bb:"30", aa:"100", ab:"0"};
var _local22 = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
var _local27 = [_local26, _local25, _local24, _local23, _local22];
while (_local21 == 0) {
var _local12 = chooseTile();
if (_local12 == 0) {
return(undefined);
}
var _local7 = findSpots(_local9);
var _local3 = findSpots(_local10);
if (_local7 == 0) {
_local9++;
_local7 = findSpots(_local9);
}
if (_local3 == 0) {
while (_local3 == 0) {
_local10--;
_local3 = findSpots(_local10);
}
}
var _local15 = ["b" + _local9];
var _local14 = ["b" + _local10];
var _local6 = random(_local7.length);
var _local5 = random(_local3.length);
if (_local9 == _local10) {
while (_local5 == _local6) {
_local5 = random(_local3.length);
}
}
var _local4 = [(("t" + _local7[_local6].y) + _local7[_local6].x) + _local9];
var _local2 = [(("t" + _local3[_local5].y) + _local3[_local5].x) + _local10];
depth = ((120 * _local9) + ((11 * _local7[_local6].y) + (10 * _local7[_local6].x))) + 2000;
depth0 = ((120 * _local10) + ((11 * _local3[_local5].y) + (10 * _local3[_local5].x))) + 2000;
if (_local12[0] == "ball") {
board.attachMovie("ballT", _local4, depth);
board.attachMovie("ballT", _local2, depth0);
} else if (_local12[0] == "bamboo") {
board.attachMovie("bambooT", _local4, depth);
board.attachMovie("bambooT", _local2, depth0);
} else if (_local12[0] == "char") {
board.attachMovie("charT", _local4, depth);
board.attachMovie("charT", _local2, depth0);
} else if (_local12[0] == "season") {
board.attachMovie("seasonT", _local4, depth);
board.attachMovie("seasonT", _local2, depth0);
} else if (_local12[0] == "dragon") {
board.attachMovie("dragonT", _local4, depth);
board.attachMovie("dragonT", _local2, depth0);
} else if (_local12[0] == "flower") {
board.attachMovie("flowerT", _local4, depth);
board.attachMovie("flowerT", _local2, depth0);
} else if (_local12[0] == "wind") {
board.attachMovie("windT", _local4, depth);
board.attachMovie("windT", _local2, depth0);
}
_root.board[_local4].gotoAndStop(_local12[1]);
_root.board[_local2].gotoAndStop(_local12[2]);
_root.board[_local4]._xscale = (_root.board[_local2]._xscale = shrinker);
_root.board[_local4]._yscale = (_root.board[_local2]._yscale = shrinker);
_root.board[_local4].name = _local4;
_root.board[_local4].typeT = (_root.board[_local2].typeT = _local12[0]);
_root.board[_local4].kind = _local12[1];
_root.board[_local4].clicked = (_root.board[_local2].clicked = false);
_root.board[_local4].ref = _local15;
_root.board[_local4].ref1 = ["r" + _local9];
_root.board[_local4].y = _local7[_local6].y;
_root.board[_local4].x = _local7[_local6].x;
_root.board[_local4].tt = _root[_local15][_local7[_local6].y][_local7[_local6].x][1];
_root.board[_local4].lay = _local9;
_root.board[_local2].name = _local2;
_root.board[_local2].kind = _local12[2];
_root.board[_local2].ref = _local14;
_root.board[_local2].ref1 = ["r" + _local10];
_root.board[_local2].y = _local3[_local5].y;
_root.board[_local2].x = _local3[_local5].x;
_root.board[_local2].tt = _root[_local14][_local3[_local5].y][_local3[_local5].x][1];
_root.board[_local2].lay = _local10;
if (_root[_local15][_local7[_local6].y][_local7[_local6].x][1] == 1) {
_root.board[_local4]._x = cellWidth * _local7[_local6].x;
_root.board[_local4]._y = cellHeight * _local7[_local6].y;
if (_local9 != 0) {
_root.board[_local4]._x = _root.board[_local4]._x - (_local16 * _local9);
_root.board[_local4]._y = _root.board[_local4]._y - (_local17 * _local9);
}
_root[_local15][_local7[_local6].y][_local7[_local6].x][0] = 9;
}
if (_root[_local15][_local7[_local6].y][_local7[_local6].x][1] == 2) {
_root.board[_local4]._x = cellWidth * _local7[_local6].x;
_root.board[_local4]._y = (cellHeight * _local7[_local6].y) + (cellHeight / 2);
if (_local9 != 0) {
_root.board[_local4]._x = _root.board[_local4]._x - (_local16 * _local9);
_root.board[_local4]._y = _root.board[_local4]._y - (_local17 * _local9);
}
_root[_local15][_local7[_local6].y][_local7[_local6].x][0] = 9;
}
if (_root[_local15][_local7[_local6].y][_local7[_local6].x][1] == 3) {
_root.board[_local4]._x = cellWidth * _local7[_local6].x;
_root.board[_local4]._y = (cellHeight * _local7[_local6].y) - (cellHeight / 2);
if (_local9 != 0) {
_root.board[_local4]._x = _root.board[_local4]._x - (_local16 * _local9);
_root.board[_local4]._y = _root.board[_local4]._y - (_local17 * _local9);
}
_root[_local15][_local7[_local6].y][_local7[_local6].x][0] = 9;
}
if (_root[_local14][_local3[_local5].y][_local3[_local5].x][1] == 1) {
_root.board[_local2]._x = cellWidth * _local3[_local5].x;
_root.board[_local2]._y = cellHeight * _local3[_local5].y;
if (_local9 != _local10) {
_root.board[_local2]._x = _root.board[_local2]._x - (_local16 * _local10);
_root.board[_local2]._y = _root.board[_local2]._y - (_local17 * _local10);
}
_root[_local14][_local3[_local5].y][_local3[_local5].x][0] = 9;
}
if (_root[_local14][_local3[_local5].y][_local3[_local5].x][1] == 2) {
_root.board[_local2]._x = cellWidth * _local3[_local5].x;
_root.board[_local2]._y = (cellHeight * _local3[_local5].y) + (cellHeight / 2);
if (_local9 != _local10) {
_root.board[_local2]._x = _root.board[_local2]._x - (_local16 * _local10);
_root.board[_local2]._y = _root.board[_local2]._y - (_local17 * _local10);
}
_root[_local14][_local3[_local5].y][_local3[_local5].x][0] = 9;
}
if (_root[_local14][_local3[_local5].y][_local3[_local5].x][1] == 3) {
_root.board[_local2]._x = cellWidth * _local3[_local5].x;
_root.board[_local2]._y = (cellHeight * _local3[_local5].y) - (cellHeight / 2);
_root[_local14][_local3[_local5].y][_local3[_local5].x][0] = 9;
}
if (_root[_local14][_local3[_local5].y][_local3[_local5].x][1] == 4) {
_root.board[_local2]._x = (cellWidth * _local3[_local5].x) + (cellWidth / 2);
_root.board[_local2]._y = (cellHeight * _local3[_local5].y) + (cellHeight / 2);
if (_local9 != _local10) {
_root.board[_local2]._x = _root.board[_local2]._x - (_local16 * _local10);
_root.board[_local2]._y = _root.board[_local2]._y - (_local17 * _local10);
}
_root[_local14][_local3[_local5].y][_local3[_local5].x][0] = 9;
}
}
}
function findSpots(layer) {
var _local4 = 0;
var _local6 = [];
var _local5 = ["b" + layer];
var _local3 = 0;
while (_local3 < _root[_local5].length) {
var _local2 = 0;
while (_local2 < _root[_local5][0].length) {
if ((_root[_local5][_local3][_local2][1] > 0) && (_root[_local5][_local3][_local2][0] != 9)) {
_local6[_local4] = {};
_local6[_local4].x = _local2;
_local6[_local4].y = _local3;
_local4++;
}
_local2++;
}
_local3++;
}
if (_local4 == 0) {
return(0);
}
return(_local6);
}
function chooseTile() {
var _local5 = [];
var _local1 = 0;
if (tiles.ball[0] == 1) {
_local5[_local1] = 0;
_local1++;
}
if (tiles.bamboo[0] == 1) {
_local5[_local1] = 1;
_local1++;
}
if (tiles.char[0] == 1) {
_local5[_local1] = 2;
_local1++;
}
if (tiles.season[0] == 1) {
_local5[_local1] = 3;
_local1++;
}
if (tiles.wind[0] == 1) {
_local5[_local1] = 4;
_local1++;
}
if (tiles.flower[0] == 1) {
_local5[_local1] = 5;
_local1++;
}
if (tiles.dragon[0] == 1) {
_local5[_local1] = 6;
_local1++;
}
if (_local1 == 0) {
return(0);
}
var _local7 = 0;
var _local4 = [];
_local7 = random(_local5.length);
n = tiles.types[_local5[_local7]];
switch (n) {
case "season" :
_local1 = 1;
var _local2 = [];
var _local3 = 1;
while (_local3 < tiles.season.length) {
if (tiles.season[_local3] > 0) {
_local2[_local1] = _local3;
_local1++;
}
_local3++;
}
_local1 = random(_local2.length);
if (_local1 == 0) {
_local1++;
}
tiles.season[_local2[_local1]] = tiles.season[_local2[_local1]] - 1;
var _local6 = _local1 + 1;
if (_local6 == 0) {
_local6++;
}
if (_local6 > (_local2.length - 1)) {
_local6 = 1;
}
tiles.season[_local2[_local6]] = tiles.season[_local2[_local6]] - 1;
if (_local2.length == 3) {
tiles.season[0] = 0;
}
_local4[0] = "season";
_local4[1] = _local2[_local1];
_local4[2] = _local2[_local6];
season++;
break;
case "flower" :
_local1 = 1;
_local2 = [];
_local3 = 1;
while (_local3 < tiles.flower.length) {
if (tiles.flower[_local3] > 0) {
_local2[_local1] = _local3;
_local1++;
}
_local3++;
}
_local1 = random(_local2.length);
if (_local1 == 0) {
_local1++;
}
tiles.flower[_local2[_local1]] = tiles.flower[_local2[_local1]] - 1;
_local6 = _local1 + 1;
if (_local6 == 0) {
_local6++;
}
if (_local6 > (_local2.length - 1)) {
_local6 = 1;
}
tiles.flower[_local2[_local6]] = tiles.flower[_local2[_local6]] - 1;
if (_local2.length == 3) {
tiles.flower[0] = 0;
}
_local4[0] = "flower";
_local4[1] = _local2[_local1];
_local4[2] = _local2[_local6];
flower++;
break;
default :
_local1 = 1;
_local2 = [];
_local3 = 1;
while (_local3 < tiles[n].length) {
if (tiles[n][_local3] > 0) {
_local2[_local1] = _local3;
_local1++;
}
_local3++;
}
_local1 = random(_local2.length);
if (_local1 == 0) {
_local1++;
}
tiles[n][_local2[_local1]] = tiles[n][_local2[_local1]] - 2;
if (tiles[n][_local2[_local1]] <= 0) {
if (_local2.length == 2) {
tiles[n][0] = 0;
}
}
_local4[0] = n;
_local4[1] = _local2[_local1];
_local4[2] = _local2[_local1];
}
return(_local4);
}
function checkMatch() {
var _local7 = _root.board[game.selections[1].name].ref;
var _local5 = _root.board[game.selections[1].name].x;
var _local3 = _root.board[game.selections[1].name].y;
var _local6 = _root.board[game.selections[2].name].ref;
var _local4 = _root.board[game.selections[2].name].x;
var _local2 = _root.board[game.selections[2].name].y;
if (game.selections[1].typeT == game.selections[2].typeT) {
if ((game.selections[1].typeT == "flower") || (game.selections[1].typeT == "season")) {
if ((_root.board[game.selections[1].name].tt == 2) || (_root.board[game.selections[1].name].tt == 3)) {
if (_root[_local7][_local3 - 1][_local5][0] == 8) {
_root[_local7][_local3 - 1][_local5][0] = 0;
}
if (_root[_local7][_local3 + 1][_local5][0] == 8) {
_root[_local7][_local3 + 1][_local5][0] = 0;
}
}
if ((_root.board[game.selections[2].name].tt == 2) || (_root.board[game.selections[2].name].tt == 3)) {
if (_root[_local6][_local2 - 1][_local4][0] == 8) {
_root[_local6][_local2 - 1][_local4][0] = 0;
}
if (_root[_local6][_local2 + 1][_local4][0] == 8) {
_root[_local6][_local2 + 1][_local4][0] = 0;
}
}
if (game.selections[1].typeT == "season") {
sea.start();
} else {
wind.start();
}
_root[_local7][_local3][_local5][0] = 6;
_root[_local6][_local2][_local4][0] = 6;
tiles2[game.selections[1].typeT][game.selections[1].kind] = tiles2[game.selections[1].typeT][game.selections[1].kind] - 1;
tiles2[game.selections[2].typeT][game.selections[2].kind] = tiles2[game.selections[2].typeT][game.selections[2].kind] - 1;
_root.board.attachMovie("fireWork", "f1", 9017);
_root.board.attachMovie("fireWork", "f2", 9018);
_root.board.f1._x = _local5 * cellWidth;
_root.board.f1._y = _local3 * cellHeight;
_root.board.f2._x = _local4 * cellWidth;
_root.board.f2._y = _local2 * cellHeight;
if (hint.fHint) {
if ((_root.board[hint.t1.name].name == _root.board[game.selections[1].name].name) || (_root.board[hint.t1.name].name == _root.board[game.selections[2].name].name)) {
hint.fHint = false;
}
if ((_root.board[hint.t2.name].name == _root.board[game.selections[1].name].name) || (_root.board[hint.t2.name].name == _root.board[game.selections[2].name].name)) {
hint.fHint = false;
}
}
_root.board[game.selections[1].name].removeMovieClip();
_root.board[game.selections[2].name].removeMovieClip();
game.selections[0] = 1;
updateScore();
} else if (game.selections[1].kind == game.selections[2].kind) {
if ((_root.board[game.selections[1].name].tt == 2) || (_root.board[game.selections[1].name].tt == 3)) {
if (_root[_local7][_local3 - 1][_local5][0] == 8) {
_root[_local7][_local3 - 1][_local5][0] = 0;
}
if (_root[_local7][_local3 + 1][_local5][0] == 8) {
_root[_local7][_local3 + 1][_local5][0] = 0;
}
}
if ((_root.board[game.selections[2].name].tt == 2) || (_root.board[game.selections[2].name].tt == 3)) {
if (_root[_local6][_local2 - 1][_local4][0] == 8) {
_root[_local6][_local2 - 1][_local4][0] = 0;
}
if (_root[_local6][_local2 + 1][_local4][0] == 8) {
_root[_local6][_local2 + 1][_local4][0] = 0;
}
}
match.start();
tiles2[game.selections[1].typeT][game.selections[1].kind] = tiles2[game.selections[1].typeT][game.selections[1].kind] - 2;
_root[_local7][_local3][_local5][0] = 6;
_root[_local6][_local2][_local4][0] = 6;
_root.board.attachMovie("fireWork", "f1", 9017);
_root.board.attachMovie("fireWork", "f2", 9018);
_root.board.f1._x = _local5 * cellWidth;
_root.board.f1._y = _local3 * cellHeight;
_root.board.f2._x = _local4 * cellWidth;
_root.board.f2._y = _local2 * cellHeight;
if (hint.fHint) {
if ((_root.board[hint.t1.name].name == _root.board[game.selections[1].name].name) || (_root.board[hint.t1.name].name == _root.board[game.selections[2].name].name)) {
hint.fHint = false;
}
if ((_root.board[hint.t2.name].name == _root.board[game.selections[1].name].name) || (_root.board[hint.t2.name].name == _root.board[game.selections[2].name].name)) {
hint.fHint = false;
}
}
_root.board[game.selections[1].name].removeMovieClip();
_root.board[game.selections[2].name].removeMovieClip();
game.selections[0] = 1;
updateScore();
}
}
var _local9 = new Color(_root.board[game.selections[1].name]);
var _local8 = new Object();
_local8 = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
_local9.setTransform(_local8);
_local9 = new Color(_root.board[game.selections[2].name]);
_local8 = new Object();
_local8 = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
_local9.setTransform(_local8);
_root.board[game.selections[1].name].clicked = false;
_root.board[game.selections[2].name].clicked = false;
game.selections[0] = 1;
}
function startTimer() {
timer.minute = 40;
timer.second = 0;
timer.timeInt = setInterval(updateTime, 1000);
timer.bonus = 60;
}
function updateTime() {
timer.second--;
if (timer.second < 0) {
if (timer.minute == 0) {
gotoAndPlay (12);
}
timer.minute--;
timer.second = 59;
}
timer.bonus--;
if (timer.bonus < 0) {
timer.bonus = 0;
}
if (timer.second < 10) {
statBar.time.text = (timer.minute + ":0") + timer.second;
} else {
statBar.time.text = (timer.minute + ":") + timer.second;
}
}
function updateScore() {
game.score = game.score + (50 + timer.bonus);
timer.bonus = 60;
statBar.score.text = game.score;
tiles.count++;
if (tiles.count == 72) {
gotoAndPlay (11);
}
}
function findHint() {
if (hint.fAT) {
hint.m = [];
var _local12 = 0;
var _local4 = 0;
var _local9 = hint.t1.sLayer;
while (_local9 > -1) {
var _local6 = ["b" + _local9];
var _local3 = 0;
while (_local3 < 8) {
var _local2 = 0;
while (_local2 < 15) {
var _local8 = _root[_local6][_local3][_local2][0];
if ((_local8 == 0) || (_local8 == 6)) {
_local12++;
}
if ((_local8 != 0) && (_local8 != 6)) {
if (((_root[_local6][_local3][_local2 - 1][0] != 9) && (_root[_local6][_local3][_local2 - 1][0] != 8)) || ((_root[_local6][_local3][_local2 + 1][0] != 9) && (_root[_local6][_local3][_local2 + 1][0] != 8))) {
var _local11 = ["b" + (_local9 + 1)];
if (((_local9 == 4) || (_root[_local11][_local3][_local2][0] == 0)) || (_root[_local11][_local3][_local2][0] == 6)) {
if ((game.layout == 1) && (_root[_local6] == _root.b3)) {
if (_root.b4[3][6][0] != 9) {
var _local10 = [(("t" + _local3) + _local2) + _local9];
hint.m[_local4] = {};
hint.m[_local4].name = _local10;
hint.m[_local4].typeT = _root.board[_local10].typeT;
hint.m[_local4].kind = _root.board[_local10].kind;
_local4++;
}
} else {
var _local10 = [(("t" + _local3) + _local2) + _local9];
hint.m[_local4] = {};
hint.m[_local4].name = _local10;
hint.m[_local4].typeT = _root.board[_local10].typeT;
hint.m[_local4].kind = _root.board[_local10].kind;
_local4++;
}
}
}
}
_local2++;
}
_local3++;
}
if (_local12 == 120) {
hint.t1.sLayer--;
}
_local12 = 0;
_local9--;
}
hint.fAT = false;
hint.jma = true;
return(undefined);
}
var _local7 = 0;
while (_local7 < hint.m.length) {
if (_root.board[hint.m[_local7].name]._name != undefined) {
var _local5 = 0;
while (_local5 < hint.m.length) {
if (hint.m[_local5].name != hint.m[_local7].name) {
if (_root.board[hint.m[_local5].name]._name != undefined) {
if (hint.m[_local5].typeT == hint.m[_local7].typeT) {
if ((hint.m[_local5].typeT != "flower") && (hint.m[_local5].typeT != "season")) {
if (hint.m[_local5].kind == hint.m[_local7].kind) {
hint.fHint = true;
hint.t1.name = hint.m[_local5].name;
hint.t1.index = _local5;
hint.t2.name = hint.m[_local7].name;
hint.t2.index = _local7;
hint.jma = false;
return(undefined);
}
} else if (hint.m[_local5].typeT == hint.m[_local7].typeT) {
hint.fHint = true;
hint.t1.name = hint.m[_local5].name;
hint.t1.index = _local5;
hint.t2.name = hint.m[_local7].name;
hint.t2.index = _local7;
hint.jma = false;
return(undefined);
}
}
}
}
_local5++;
}
}
_local7++;
}
if (!hint.fHint) {
if (hint.jma) {
hint.fHint = true;
timer.newInt = setInterval(placeNM, 6500);
return(undefined);
}
hint.fAT = true;
}
}
function placeNM() {
clearInterval(timer.newInt);
if (_root.mm._x == undefined) {
_root.click.start();
_root.attachMovie("noMatch", "confirm2", 10095);
_root.confirm2._x = 275;
_root.confirm2._y = 200;
}
}
function tileFunc() {
}
game = {};
game.score = 0;
game.layout = 0;
game.layout++;
game.selections = [];
game.selections[0] = 1;
game.selections[1] = {};
game.selections[2] = {};
game.js = true;
game.paused = false;
hint = {};
hint.fHint = false;
hint.fAT = true;
hint.t1 = {};
hint.t1.sLayer = 4;
hint.t2 = {};
hint.m = [];
timer = {};
tileFunc.prototype = new MovieClip();
tileFunc.prototype.onRollOver = function () {
if (!game.paused) {
var _local2 = new Color(this);
myColorTransform = new Object();
var myColorTransform = {ra:"50", rb:"244", ga:"40", gb:"112", ba:"12", bb:"90", aa:"100", ab:"0"};
_local2.setTransform(myColorTransform);
}
};
tileFunc.prototype.onReleaseOutside = function () {
if (!this.clicked) {
var _local2 = new Color(this);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
_local2.setTransform(myColorTransform);
}
};
tileFunc.prototype.onRollOut = function () {
if (!this.clicked) {
var _local2 = new Color(this);
myColorTransform = new Object();
myColorTransform = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
_local2.setTransform(myColorTransform);
}
};
tileFunc.prototype.onRelease = function () {
if (!game.paused) {
if (game.layout == 1) {
if (_root[this.ref] == _root.b3) {
if (_root.b4[3][6][0] == 9) {
return(undefined);
}
}
}
var _local3 = _root.game.selections[0];
if (_root.game.selections[_local3 - 1].name != this.name) {
if ((_root[this.ref][this.y][this.x - 1][0] != 9) || (_root[this.ref][this.y][this.x + 1][0] != 9)) {
if ((_root[this.ref][this.y][this.x - 1][0] != 8) || (_root[this.ref][this.y][this.x + 1][0] != 9)) {
if ((_root[this.ref][this.y][this.x - 1][0] != 9) || (_root[this.ref][this.y][this.x + 1][0] != 8)) {
var _local5 = this.lay + 1;
if (((_root["b" + _local5][this.y][this.x][0] == 0) || (this.lay == 4)) || (_root["b" + _local5][this.y][this.x][0] == 6)) {
click.start();
_root.game.selections[_local3].name = this.name;
_root.game.selections[_local3].typeT = this.typeT;
_root.game.selections[_local3].kind = this.kind;
_root.game.selections[0]++;
this.clicked = true;
if (_root.game.selections[0] == 3) {
_root.checkMatch();
}
}
}
}
}
return(undefined);
}
_root.game.selections[_local3 - 1].name = "";
_root.game.selections[0]--;
var _local6 = new Color(this);
var _local4 = new Object();
_local4 = {ra:"100", rb:"0", ga:"100", gb:"0", ba:"100", bb:"0", aa:"100", ab:"0"};
_local6.setTransform(_local4);
this.clicked = false;
}
};
Object.registerClass("ballT", tileFunc);
Object.registerClass("bambooT", tileFunc);
Object.registerClass("charT", tileFunc);
Object.registerClass("dragonT", tileFunc);
Object.registerClass("seasonT", tileFunc);
Object.registerClass("windT", tileFunc);
Object.registerClass("flowerT", tileFunc);
click = new Sound();
click.attachSound("click");
match = new Sound();
match.attachSound("match");
sea = new Sound();
sea.attachSound("sea");
wind = new Sound();
wind.attachSound("wind");
rRT = false;
defineLayouts();
if (sound == null) {
var sound = new Sound();
sound.attachSound("musingame");
sound.start(0, 9999999);
}
Frame 5
start.onRelease = function () {
gotoAndPlay (8);
};
ins.onRelease = function () {
gotoAndStop (6);
};
_root.onEnterFrame = function () {
};
stop();
Frame 6
back.onRelease = function () {
gotoAndPlay (5);
};
stop();
Frame 7
stop();
Frame 8
endG.removeMovieClip();
Frame 9
function changeFrames() {
gotoAndPlay (8);
}
endG.swapDepths(25000);
endG.onRelease = function () {
trace(game.score);
clearInterval(timer.timeInt);
statBar.removeMovieClip();
back.removeMovieClip();
board.removeMovieClip();
confirm2.removeMovieClip();
bm.removeMovieClip();
confirm.removeMovieClip();
gotoAndPlay (12);
this.removeMovieClip();
trace(game.score);
};
hint.m = [];
Key.addListener(keyListener);
if (!rRT) {
createTileList();
}
copyTiles();
createBoard();
if (game.js) {
startTimer();
game.js = false;
} else {
timer.timeInt = setInterval(updateTime, 1000);
}
_root.attachMovie("statBar", "statBar", 9001);
statBar._x = 240;
statBar._y = 378;
statBar.score.text = game.score;
if (timer.second < 10) {
statBar.time.text = (timer.minute + ":0") + timer.second;
} else {
statBar.time.text = (timer.minute + ":") + timer.second;
}
_root.onEnterFrame = function () {
if (Key.isDown(1) && (!statBar.pauses.hitTest(_xmouse, _ymouse)true)) {
if (game.paused) {
timer.timeInt = setInterval(updateTime, 1000);
_root.paused.removeMovieClip();
game.paused = false;
return(undefined);
}
}
};
statBar.pauses.onRelease = function () {
clearInterval(timer.timeInt);
_root.attachMovie("paused", "paused", 10000);
_root.paused._x = 275;
_root.paused._y = 200;
game.paused = true;
};
_root.hint.fHint = false;
_root.hint.fAT = true;
stop();
Frame 11
function go() {
clearInterval(timer.timeInt);
gotoAndPlay (8);
}
endG.removeMovieClip();
rRT = false;
clearInterval(timer.timeInt);
timer.timeInt = setInterval(go, 1000);
statBar.removeMovieClip();
back.removeMovieClip();
board.removeMovieClip();
defineLayouts();
game.layout++;
hint.fHint = false;
hint.fAT = true;
if (game.layout > 3) {
gotoAndPlay (12);
}
game.score = game.score + 5000;
_root.onEnterFrame = function () {
};
stop();
Frame 12
clearInterval(timer.timeInt);
statBar.removeMovieClip();
back.removeMovieClip();
board.removeMovieClip();
confirm2.removeMovieClip();
endG.removeMovieClip();
bm.removeMovieClip();
confirm.removeMovieClip();
scores.text = game.score;
score = game.score;
gcode = _level0.gcode;
submit.onRelease = function () {
delete game;
delete rRT;
delete keyListener;
delete timer;
delete match;
delete sea;
delete click;
delete wind;
delete hint;
delete defineLayouts;
delete createTileList;
delete copyTiles;
delete createTileList2;
delete createBoard;
delete findSpots;
delete chooseTile;
delete checkMatch;
delete startTimer;
delete updateTime;
delete updateScore;
delete changeBack;
delete findHint;
delete placeNM;
delete tileFunc;
delete changeFrames;
delete loader;
delete frame;
delete ly11;
delete ly12;
delete ly13;
delete ly14;
delete ly15;
delete ly21;
delete ly22;
delete ly23;
delete ly24;
delete ly25;
delete ly31;
delete ly32;
delete ly33;
delete ly34;
delete ly35;
delete layout1;
delete layout2;
delete layout3;
delete layouts;
delete backG;
delete tiles;
delete tiles2;
delete shrinker;
delete cellWidth;
delete cellHeight;
delete b0;
delete b1;
delete b2;
delete b3;
delete b4;
delete n;
delete depth;
delete depth0;
delete season;
delete flower;
delete onEnterFrame;
delete myColorTransform;
getURL ((((("http://playonlinesite.com/index.php?t=9&gameid=15&scrore=" + String(score)) + "&name=") + Name.text) + "&key=") + String(((score * score) + (5 * score)) + 34), "_blank");
};
mm.onRelease = function () {
gotoAndPlay (4);
};
_root.onEnterFrame = function () {
};
stop();
Symbol 26 MovieClip [seasonT] Frame 1
stop();
Symbol 26 MovieClip [seasonT] Frame 2
stop();
Symbol 26 MovieClip [seasonT] Frame 3
stop();
Symbol 26 MovieClip [seasonT] Frame 4
stop();
Symbol 35 MovieClip [windT] Frame 1
stop();
Symbol 35 MovieClip [windT] Frame 2
stop();
Symbol 35 MovieClip [windT] Frame 3
stop();
Symbol 35 MovieClip [windT] Frame 4
stop();
Symbol 49 MovieClip [flowerT] Frame 1
stop();
Symbol 49 MovieClip [flowerT] Frame 2
stop();
Symbol 49 MovieClip [flowerT] Frame 3
stop();
Symbol 49 MovieClip [flowerT] Frame 4
stop();
Symbol 56 MovieClip [dragonT] Frame 1
stop();
Symbol 56 MovieClip [dragonT] Frame 2
stop();
Symbol 56 MovieClip [dragonT] Frame 3
stop();
Symbol 83 MovieClip [charT] Frame 1
stop();
Symbol 83 MovieClip [charT] Frame 2
stop();
Symbol 83 MovieClip [charT] Frame 3
stop();
Symbol 83 MovieClip [charT] Frame 4
stop();
Symbol 83 MovieClip [charT] Frame 5
stop();
Symbol 83 MovieClip [charT] Frame 6
stop();
Symbol 83 MovieClip [charT] Frame 7
stop();
Symbol 83 MovieClip [charT] Frame 8
stop();
Symbol 83 MovieClip [charT] Frame 9
stop();
Symbol 93 MovieClip [bambooT] Frame 1
stop();
Symbol 93 MovieClip [bambooT] Frame 2
stop();
Symbol 93 MovieClip [bambooT] Frame 3
stop();
Symbol 93 MovieClip [bambooT] Frame 4
stop();
Symbol 93 MovieClip [bambooT] Frame 5
stop();
Symbol 93 MovieClip [bambooT] Frame 6
stop();
Symbol 93 MovieClip [bambooT] Frame 7
stop();
Symbol 93 MovieClip [bambooT] Frame 8
stop();
Symbol 93 MovieClip [bambooT] Frame 9
stop();
Symbol 103 MovieClip [ballT] Frame 1
stop();
Symbol 103 MovieClip [ballT] Frame 2
stop();
Symbol 103 MovieClip [ballT] Frame 3
stop();
Symbol 103 MovieClip [ballT] Frame 4
stop();
Symbol 103 MovieClip [ballT] Frame 5
stop();
Symbol 103 MovieClip [ballT] Frame 6
stop();
Symbol 103 MovieClip [ballT] Frame 7
stop();
Symbol 103 MovieClip [ballT] Frame 8
stop();
Symbol 103 MovieClip [ballT] Frame 9
stop();
Symbol 112 MovieClip [noMatch] Frame 1
sRT.onRelease = function () {
var _local3 = _root;
_local3.hint.fHint = false;
_local3.hint.fAT = true;
_local3.click.start();
_local3.rRT = true;
_local3.game.score = _local3.game.score - 500;
clearInterval(_local3.timer.timeInt);
_local3.board.removeMovieClip();
var _local2 = 0;
while (_local2 < _local3.levels) {
_local3["b" + _local2] = [];
_local2++;
}
_local3.back.removeMovieClip();
_local3.changeFrames();
_local3.statBar.removeMovieClip();
_local3.confirm2.removeMovieClip();
};
sSL.onRelease = function () {
var _local3 = _root;
_local3.hint.fHint = false;
_local3.hint.fAT = true;
_local3.click.start();
_local3.rRT = false;
_local3.defineLayouts();
clearInterval(_local3.timer.timeInt);
_local3.board.removeMovieClip();
var _local2 = 0;
while (_local2 < _local3.levels) {
_local3["b" + _local2] = [];
_local2++;
}
_local3.back.removeMovieClip();
_local3.changeFrames();
_local3.statBar.removeMovieClip();
_local3.confirm2.removeMovieClip();
};
sDL.onRelease = function () {
var _local3 = _root;
_local3.hint.fHint = false;
_local3.hint.fAT = true;
_local3.click.start();
_local3.rRT = false;
_local3.defineLayouts();
_local3.game.layout++;
if (_local3.game.layout == 4) {
_local3.game.layout = 1;
}
clearInterval(_local3.timer.timeInt);
_local3.board.removeMovieClip();
var _local2 = 0;
while (_local2 < _local3.levels) {
_local3["b" + _local2] = [];
_local2++;
}
_local3.back.removeMovieClip();
_local3.changeFrames();
_local3.statBar.removeMovieClip();
_local3.confirm2.removeMovieClip();
};
Symbol 123 MovieClip [confirm] Frame 1
sRT.onRelease = function () {
var _local3 = _root;
_local3.game.selections[0] = 1;
_local3.click.start();
_local3.rRT = true;
_local3.game.score = _local3.game.score - 200;
clearInterval(_local3.timer.timeInt);
_local3.board.removeMovieClip();
var _local2 = 0;
while (_local2 < _local3.levels) {
_local3["b" + _local2] = [];
_local2++;
}
_local3.back.removeMovieClip();
_local3.changeFrames();
_local3.statBar.removeMovieClip();
_local3.confirm.removeMovieClip();
};
no.onRelease = function () {
_root.click.start();
_root.confirm.removeMovieClip();
};
Symbol 125 MovieClip [backMenu] Frame 1
t1.onRelease = function () {
_root.click.start();
_root.changeBack(1);
};
t2.onRelease = function () {
_root.click.start();
_root.changeBack(2);
};
t3.onRelease = function () {
_root.click.start();
_root.changeBack(3);
};
t4.onRelease = function () {
_root.click.start();
_root.changeBack(4);
};
t5.onRelease = function () {
_root.click.start();
_root.changeBack(5);
};
t6.onRelease = function () {
_root.click.start();
_root.changeBack(6);
};
t7.onRelease = function () {
_root.click.start();
_root.changeBack(7);
};
t8.onRelease = function () {
_root.click.start();
_root.changeBack(8);
};
t9.onRelease = function () {
_root.click.start();
_root.changeBack(9);
};
t10.onRelease = function () {
_root.click.start();
_root.changeBack(10);
};
t11.onRelease = function () {
_root.click.start();
_root.changeBack(11);
};
t12.onRelease = function () {
_root.click.start();
_root.changeBack(12);
};
t13.onRelease = function () {
_root.click.start();
_root.changeBack(13);
};
t14.onRelease = function () {
_root.click.start();
_root.changeBack(14);
};
t15.onRelease = function () {
_root.click.start();
_root.changeBack(15);
};
t16.onRelease = function () {
_root.click.start();
_root.changeBack(16);
};
t17.onRelease = function () {
_root.click.start();
_root.changeBack(17);
};
done.onRelease = function () {
_root.click.start();
_root.bM.removeMovieClip();
};
Symbol 137 MovieClip [statBar] Frame 1
reshuffle.onRelease = function () {
_root.click.start();
_root.attachMovie("confirm", "confirm", 9019);
_root.confirm._x = 275;
_root.confirm._y = 200;
};
Symbol 141 MovieClip Frame 20
this.removeMovieClip();
Symbol 142 MovieClip Frame 1
level = 0;
dot._visible = false;
placeDot = function () {
dotName = "dot" + level;
var _local1 = dot.duplicateMovieClip(dotName, level);
_local1._rotation = Math.random() * 360;
_local1._xscale = (_local1._yscale = 50 + (Math.random() * 50));
tmp = Math.random();
if (tmp < 0.5) {
_local1.colo.gotoAndStop(1);
} else {
_local1.colo.gotoAndStop(1);
}
_local1.colo.x._rotation = Math.random() * 360;
level++;
};
i = 0;
while (i < 30) {
placeDot();
i++;
}
Symbol 143 MovieClip Frame 1
lev = 0;
placeBoom = function () {
lev++;
d = boom.duplicateMovieClip("b" + lev, lev);
d._x = d._x + ((Math.random() * 80) - 40);
d._y = d._y + ((Math.random() * 80) - 40);
if (lev > 5) {
clearInterval(id);
}
};
id = setInterval(placeBoom, 300);
Symbol 144 MovieClip [firework] Frame 16
this.removeMovieClip();
Symbol 151 MovieClip Frame 1
stop();
Symbol 161 Button
on (release) {
getURL ("http://www.game-mahjong.com/?from=CartoonMahjong", "_blank");
}