Frame 1
fscommand ("trapallkeys", true);
stop();
Frame 15
if (initialized == undefined) {
var x;
var y;
y = 0;
while (y < 9) {
x = 0;
while (x < 9) {
this.attachMovie("sudoku field", ("sf" + y) + x, this.getNextHighestDepth(), {_x:270 + (x * 30), _y:60 + (y * 30)});
this[("sf" + y) + x].button.useHandCursor = false;
x++;
}
y++;
}
delete x;
delete y;
this.attachMovie("digit menu", "digit_menu_mc", this.getNextHighestDepth(), {_visible:false});
this.attachMovie("paused sign animation", "paused_sign_mc", this.getNextHighestDepth(), {_x:270, _y:60, _visible:false});
this.attachMovie("generating sign animation", "gen_sign_mc", this.getNextHighestDepth(), {_x:270, _y:60, _visible:false});
}
var initialized = true;
Frame 16
function placeDigit(slctd_fld, digit) {
if (digit) {
if (slctd_fld.getDigit() == undefined) {
digits_placed++;
}
} else {
digits_placed--;
}
var _local3 = Number(slctd_fld._name.charAt(2));
var _local4 = Number(slctd_fld._name.charAt(3));
sdk_partial[_local3][_local4] = digit;
slctd_fld.setDigit(digit);
}
function clearTable() {
var _local3;
var _local2;
_local3 = 0;
while (_local3 < 9) {
_local2 = 0;
while (_local2 < 9) {
this[("sf" + _local3) + _local2].setDigit(undefined);
_local2++;
}
_local3++;
}
}
function setEnableTable(val) {
var _local3;
var _local2;
_local3 = 0;
while (_local3 < 9) {
_local2 = 0;
while (_local2 < 9) {
this[("sf" + _local3) + _local2].setEnabled(val);
_local2++;
}
_local3++;
}
}
function setBoldTable(val) {
var _local3;
var _local2;
_local3 = 0;
while (_local3 < 9) {
_local2 = 0;
while (_local2 < 9) {
this[("sf" + _local3) + _local2].setBold(val);
_local2++;
}
_local3++;
}
}
function isCompleted() {
var _local2;
var _local1;
_local2 = 0;
while (_local2 < 9) {
_local1 = 0;
while (_local1 < 9) {
if (sdk_full[_local2][_local1] != sdk_partial[_local2][_local1]) {
return(false);
}
_local1++;
}
_local2++;
}
return(true);
}
function milsecToString(ms) {
var _local5 = Math.floor(ms / 1000);
var _local3;
var _local2;
var _local1;
var _local4;
_local3 = Math.floor(_local5 / 3600);
_local2 = Math.floor((_local5 % 3600) / 60);
_local1 = Math.floor((_local5 % 3600) % 60);
_local4 = Math.floor((ms % 1000) / 100);
var _local6;
if (_local3 > 0) {
_local6 = ((((((_local3 < 10) ? ("0" + _local3) : (_local3)) + ":") + ((_local2 < 10) ? ("0" + _local2) : (_local2))) + :(((_local1 < 10) ? ("0" + _local1) : (_local1)))) + ".") + _local4;
} else if (_local2 > 0) {
_local6 = (((((_local2 < 10) ? ("0" + _local2) : (_local2)) + ":") + ((_local1 < 10) ? ("0" + _local1) : (_local1))) + ".") + _local4;
} else {
_local6 = (((_local1 < 10) ? ("0" + _local1) : (_local1)) + ".") + _local4;
}
return(_local6);
}
function startGeneratingNew() {
clearTable();
setBoldTable(false);
setEnableTable(false);
sdk.Generator.generate(sdk_full);
this.gen_sign_mc.play();
this.gen_sign_mc._visible = true;
submode = "generating";
digits_placed = 0;
this.contextmenu.txt.text = "";
}
function startSolving() {
sdk.Solver.solve(sdk_partial);
var _local3 = 0;
while (_local3 < 9) {
var _local2 = 0;
while (_local2 < 9) {
if (this[("sf" + _local3) + _local2].getDigit() == undefined) {
this[("sf" + _local3) + _local2].setBold(false);
}
this[("sf" + _local3) + _local2].setEnabled(false);
_local2++;
}
_local3++;
}
submode = "solving";
this.contextmenu.txt.text = "";
this.contextmenu.btnCA.enabled = false;
this.contextmenu.btnS.enabled = false;
}
function setPaused(val) {
paused = val;
this.contextmenu.btnContinue._visible = val;
this.contextmenu.btnPause._visible = !val;
if (val) {
setEnableTable(false);
} else {
var _local3;
var _local2;
_local3 = 0;
while (_local3 < 9) {
_local2 = 0;
while (_local2 < 9) {
if (!this[("sf" + _local3) + _local2].bold) {
this[("sf" + _local3) + _local2].setEnabled(true);
}
_local2++;
}
_local3++;
}
}
paused_sign_mc._visible = val;
if (val) {
paused_sign_mc.play();
} else {
paused_sign_mc.gotoAndStop(1);
}
}
function startPlayMode() {
sdk.Solver.cancel();
workmode = "playmode";
this.contextmenu.gotoAndStop("Play Mode");
this.PlayBtn._visible = false;
this.SolverModeBtn._visible = true;
this.contextmenu.btnContinue._visible = false;
startGeneratingNew();
}
function resetSolverMode() {
clearTable();
setBoldTable(true);
setEnableTable(true);
sdk.Tools.clearArray(sdk_partial);
submode = "idle";
digits_placed = 0;
this.contextmenu.btnCA.enabled = false;
this.contextmenu.btnS.enabled = true;
}
function startSolverMode() {
workmode = "solvermode";
this.PlayBtn._visible = true;
this.SolverModeBtn._visible = false;
this.contextmenu.gotoAndStop("Solver Mode");
this.contextmenu.txt.text = "";
if (paused) {
setPaused(false);
}
resetSolverMode();
}
stop();
var workmode;
var submode;
var digits_placed;
var paused;
var sdk_full = new Array();
var sdk_partial = new Array();
var elapsed_time;
var oldTimer = 0;
var newTimer;
var audio = true;
var loop_snd = new Sound();
var btn_snd = new Sound();
var win_snd = new Sound();
loop_snd.attachSound("_loop music");
loop_snd.onSoundComplete = function () {
loop_snd.start();
};
btn_snd.attachSound("_dugme");
win_snd.attachSound("_pobedi");
this.onEnterFrame = function () {
switch (workmode) {
case "playmode" :
switch (submode) {
case "generating" :
if (!sdk.Generator.__get__busy()) {
sdk.Tools.copyArray(sdk_full, sdk_partial);
sdk.Finalizer.hideFields(sdk_partial);
submode = "finalizing";
}
break;
case "finalizing" :
if (!sdk.Finalizer.__get__busy()) {
this.gen_sign_mc.gotoAndPlay(1);
this.gen_sign_mc._visible = false;
setEnableTable(false);
var _local3 = 0;
while (_local3 < 9) {
var _local2 = 0;
while (_local2 < 9) {
if (sdk_partial[_local3][_local2]) {
this[("sf" + _local3) + _local2].setBold(true);
this[("sf" + _local3) + _local2].setDigit(sdk_partial[_local3][_local2]);
digits_placed++;
} else {
this[("sf" + _local3) + _local2].setEnabled(true);
}
_local2++;
}
_local3++;
}
submode = "playing";
elapsed_time = 0;
oldTimer = getTimer();
}
break;
case "playing" :
newTimer = getTimer();
var _local4 = newTimer - oldTimer;
oldTimer = newTimer;
if (!paused) {
elapsed_time = elapsed_time + _local4;
this.contextmenu.txt.text = "Elapsed time :\n" + milsecToString(elapsed_time);
}
if (digits_placed != 81) {
break;
}
trace("placed 81 digits");
if (!isCompleted()) {
break;
}
this.contextmenu.txt.text = "Congratulations ! Finished !\n" + milsecToString(elapsed_time);
setEnableTable(false);
if (audio) {
win_snd.start();
}
trace("Congrats !");
submode = "finished";
}
break;
case "solvermode" :
switch (submode) {
case "idle" :
break;
case "solving" :
if (sdk.Solver.__get__busy()) {
break;
}
digits_placed = 0;
var _local3 = 0;
while (_local3 < 9) {
var _local2 = 0;
while (_local2 < 9) {
if (sdk_partial[_local3][_local2]) {
this[("sf" + _local3) + _local2].setDigit(sdk_partial[_local3][_local2]);
digits_placed++;
}
_local2++;
}
_local3++;
}
if (digits_placed == 81) {
this.contextmenu.txt.text = "Completed successfully !";
} else {
this.contextmenu.txt.text = "Unsuccessful...";
}
submode = "finished";
this.contextmenu.btnCA.enabled = true;
}
}
};
this.btnExt._visible = System.capabilities.playerType == "StandAlone";
loop_snd.start();
startPlayMode();
Symbol 1 MovieClip Frame 1
function drawRoundRect(x, y, w, h, alpha, fill, outline) {
this.moveTo(x + 4, y);
if (outline != undefined) {
this.lineStyle(2, outline, alpha, true);
}
this.beginFill(fill, alpha);
this.lineTo((x + w) - 4, y);
this.curveTo(x + w, y, x + w, y + 4);
this.lineTo(x + w, (y + h) - 4);
this.curveTo(x + w, y + h, (x + w) - 4, y + h);
this.lineTo(x + 4, y + h);
this.curveTo(x, y + h, x, (y + h) - 4);
this.lineTo(x, y + 4);
this.curveTo(x, y, x + 4, y);
this.endFill();
}
function bytesToString(bytes) {
if (bytes <= 0) {
return("0 B");
}
if ((bytes > 0) && (bytes < 1024)) {
return(String(Math.round(bytes)) + " B");
}
if ((bytes > 1024) && (bytes < 1048576)) {
return(String(Math.round(bytes / 1024)) + " KB");
}
if (bytes > 1048576) {
return(String(Math.round(bytes / 1048576)) + " MB");
}
}
function secondsToString(seconds) {
var _local3;
var _local2;
var _local1;
_local3 = Math.floor(seconds / 3600);
_local2 = Math.floor((seconds % 3600) / 60);
_local1 = Math.floor((seconds % 3600) % 60);
return((((((_local3 < 10) ? ("0" + _local3) : (_local3)) + ":") + ((_local2 < 10) ? ("0" + _local2) : (_local2))) + ":") + ((_local1 < 10) ? ("0" + _local1) : (_local1)));
}
var old_bytes = 0;
var new_bytes;
var rate;
var total_bytes = this._parent.getBytesTotal();
var oldTimer = getTimer();
this._x = 5;
this._y = 5;
this.createTextField("txt", 1, 1, 1, 178, 18);
this.txt.selectable = false;
this.txt.autoSize = "left";
var tfm = new TextFormat();
tfm.font = "_sans";
tfm.bold = true;
tfm.size = 12;
tfm.color = 16777215 /* 0xFFFFFF */;
this.txt.setNewTextFormat(tfm);
this.onEnterFrame = function () {
new_bytes = this._parent.getBytesLoaded();
var _local3 = getTimer();
var _local4 = _local3 - oldTimer;
if (_local4 >= 1000) {
rate = new_bytes - old_bytes;
oldTimer = _local3;
old_bytes = new_bytes;
}
this.txt.text = ((((bytesToString(new_bytes) + " of ") + bytesToString(total_bytes)) + " loaded at ") + bytesToString(rate)) + "ps.";
if (this.hitTest(_root._xmouse, _root._ymouse)) {
this.txt.text = this.txt.text + "\nestimated time remaining: ";
if (rate) {
this.txt.text = this.txt.text + secondsToString((total_bytes - new_bytes) / rate);
} else {
this.txt.text = this.txt.text + "--:--:--";
}
}
this.clear();
drawRoundRect(5, 5, this.txt._width + 2, this.txt._height + 2, 50, 0);
drawRoundRect(0, 0, this.txt._width + 2, this.txt._height + 2, 100, 10668287, 16777215);
if (new_bytes == total_bytes) {
this._parent.gotoAndPlay(3);
this.removeMovieClip();
}
};
Symbol 177 MovieClip [__Packages.sdk.Finalizer] Frame 0
class sdk.Finalizer
{
static var sdk_array, init, id;
function Finalizer () {
}
static function get array() {
return(sdk_array);
}
static function get busy() {
return(__busy);
}
static function __hideFields() {
var _local7 = 0;
var _local2;
var _local1;
var _local6 = true;
_local2 = (init ? (random(7) + 1) : 0);
while ((_local2 >= 0) && (_local2 <= 9)) {
if (init) {
init = false;
}
_local1 = (_local6 ? 0 : 8);
while ((-1 < _local1) && (_local1 < 9)) {
if (sdk_array[_local2][_local1] == undefined) {
} else {
var _local4 = sdk_array[_local2][_local1];
sdk_array[_local2][_local1] = undefined;
_local7++;
var _local3 = 0;
var _local5 = 0;
while (_local5 < 9) {
if (sdk_array[(Math.floor(_local2 / 3) * 3) + Math.floor(_local5 / 3)][(Math.floor(_local1 / 3) * 3) + (_local5 % 3)] != undefined) {
} else if (sdk.Tools.available((Math.floor(_local1 / 3) * 3) + (_local5 % 3), (Math.floor(_local2 / 3) * 3) + Math.floor(_local5 / 3), _local4, sdk_array)) {
_local3++;
}
_local5++;
}
if (_local3 == 1) {
} else {
_local3 = 0;
_local5 = 0;
while (_local5 < 9) {
if (sdk_array[_local2][_local5] != undefined) {
} else if (sdk.Tools.available(_local5, _local2, _local4, sdk_array)) {
_local3++;
}
_local5++;
}
if (_local3 == 1) {
} else {
_local3 = 0;
_local5 = 0;
while (_local5 < 9) {
if (sdk_array[_local5][_local1] != undefined) {
} else if (sdk.Tools.available(_local1, _local5, _local4, sdk_array)) {
_local3++;
}
_local5++;
}
if (_local3 == 1) {
} else {
_local3 = 0;
_local5 = 1;
while (_local5 <= 9) {
if (sdk.Tools.available(_local1, _local2, _local5, sdk_array)) {
_local3++;
}
_local5++;
}
if (_local3 == 1) {
} else {
sdk_array[_local2][_local1] = _local4;
_local7--;
}
}
}
}
}
(_local6 ? (_local1++) : (_local1--));
}
if (_local2 == 8) {
_local6 = false;
_local2 = 9;
}
(_local6 ? (_local2 = _local2 + 2) : (_local2 = _local2 - 2));
}
if (_local7 == 0) {
__busy = false;
clearInterval(id);
}
}
static function hideFields(out_array) {
__busy = true;
init = true;
sdk_array = out_array;
id = setInterval(__hideFields, 100);
}
static function cancel() {
if (__busy) {
clearInterval(id);
__busy = false;
}
}
static var __busy = false;
}
Symbol 178 MovieClip [__Packages.sdk.Tools] Frame 0
class sdk.Tools
{
function Tools () {
}
static function available(x, y, num, arr) {
var _local1;
_local1 = 0;
while (_local1 < 9) {
if (((arr[y][_local1] == num) || (arr[_local1][x] == num)) || (arr[(Math.floor(y / 3) * 3) + Math.floor(_local1 / 3)][(Math.floor(x / 3) * 3) + (_local1 % 3)] == num)) {
return(false);
}
_local1++;
}
return(true);
}
static function copyArray(source, destination) {
var _local2;
var _local1;
_local2 = 0;
while (_local2 < 9) {
destination[_local2] = new Array();
_local1 = 0;
while (_local1 < 9) {
destination[_local2][_local1] = source[_local2][_local1];
_local1++;
}
_local2++;
}
}
static function clearArray(target) {
var _local1;
_local1 = 0;
while (_local1 < 9) {
target[_local1] = new Array();
_local1++;
}
}
}
Symbol 179 MovieClip [__Packages.sdk.Generator] Frame 0
class sdk.Generator
{
static var sdk_array, stack_pointer, stack, id;
function Generator () {
}
static function get array() {
return(sdk_array);
}
static function get busy() {
return(__busy);
}
static function __generate(Void) {
var _local3;
var _local2;
var _local6 = false;
_local3 = stack[stack_pointer].y;
_local2 = stack[stack_pointer].x;
var _local4 = random(stack[stack_pointer].pos_nums.length);
sdk_array[_local3][_local2] = stack[stack_pointer].pos_nums[_local4];
stack[stack_pointer].pos_nums[_local4] = null;
stack[stack_pointer].pos_nums.sort();
stack[stack_pointer].pos_nums.pop();
_local2 = _local2 + 1;
while (_local2 < 9) {
sdk_array[_local3][_local2] = undefined;
_local2++;
}
_local3 = _local3 + 1;
while (_local3 < 9) {
sdk_array[_local3] = new Array();
_local3++;
}
_local3 = stack[stack_pointer].y;
_local2 = stack[stack_pointer].x + 1;
if (stack[stack_pointer].pos_nums.length > 0) {
stack_pointer++;
}
while (_local3 < 9) {
while (_local2 < 9) {
stack[stack_pointer] = {x:_local2, y:_local3, pos_nums:new Array()};
var _local1 = 1;
while (_local1 <= 9) {
if (sdk.Tools.available(_local2, _local3, _local1, sdk_array)) {
stack[stack_pointer].pos_nums.push(_local1);
}
_local1++;
}
if (stack[stack_pointer].pos_nums.length == 0) {
stack_pointer--;
_local6 = true;
break;
}
_local4 = random(stack[stack_pointer].pos_nums.length);
sdk_array[_local3][_local2] = stack[stack_pointer].pos_nums[_local4];
stack[stack_pointer].pos_nums[_local4] = null;
stack[stack_pointer].pos_nums.sort();
stack[stack_pointer].pos_nums.pop();
if (stack[stack_pointer].pos_nums.length > 0) {
stack_pointer++;
}
_local2++;
}
if (_local6) {
break;
}
_local2 = 0;
_local3++;
}
if ((_local3 == 9) && (_local2 == 0)) {
clearInterval(id);
__busy = false;
}
}
static function generate(out_array) {
__busy = true;
sdk_array = out_array;
stack_pointer = 0;
var _local2 = 0;
while (_local2 < 9) {
sdk_array[_local2] = new Array();
_local2++;
}
stack = new Array();
stack[0] = {x:0, y:0, pos_nums:new Array(1, 2, 3, 4, 5, 6, 7, 8, 9)};
id = setInterval(__generate, 100);
}
static function cancel() {
if (__busy) {
clearInterval(id);
__busy = false;
}
}
static var __busy = false;
}
Symbol 180 MovieClip [__Packages.sdk.Solver] Frame 0
class sdk.Solver
{
static var sdk_array, id;
function Solver () {
}
static function get array() {
return(sdk_array);
}
static function get busy() {
return(__busy);
}
static function __solve(Void) {
var _local4;
var _local6;
var _local2;
var _local8;
var _local7;
var _local1 = {x:0, y:0, number:0};
var _local3 = 0;
var _local5 = 0;
_local4 = 0;
while (_local4 < 9) {
_local6 = 1;
while (_local6 <= 9) {
_local2 = 0;
while (_local2 < 9) {
_local8 = ((_local4 % 3) * 3) + (_local2 % 3);
_local7 = (Math.floor(_local4 / 3) * 3) + Math.floor(_local2 / 3);
if (sdk_array[_local7][_local8] == undefined) {
if (sdk.Tools.available(_local8, _local7, _local6, sdk_array)) {
_local1 = {x:_local8, y:_local7, number:_local6};
_local3++;
}
}
_local2++;
}
if (_local3 == 1) {
sdk_array[_local1.y][_local1.x] = _local1.number;
_local5++;
}
_local7 = _local4;
_local3 = 0;
_local2 = 0;
while (_local2 < 9) {
_local8 = _local2;
if (sdk_array[_local7][_local8] == undefined) {
if (sdk.Tools.available(_local8, _local7, _local6, sdk_array)) {
_local1 = {x:_local8, y:_local7, number:_local6};
_local3++;
}
}
_local2++;
}
if (_local3 == 1) {
sdk_array[_local1.y][_local1.x] = _local1.number;
_local5++;
}
_local8 = _local4;
_local3 = 0;
_local2 = 0;
while (_local2 < 9) {
_local7 = _local2;
if (sdk_array[_local7][_local8] == undefined) {
if (sdk.Tools.available(_local8, _local7, _local6, sdk_array)) {
_local1 = {x:_local8, y:_local7, number:_local6};
_local3++;
}
}
_local2++;
}
if (_local3 == 1) {
sdk_array[_local1.y][_local1.x] = _local1.number;
_local5++;
}
_local6++;
}
_local4++;
}
_local4 = 0;
while (_local4 < 9) {
_local2 = 0;
while (_local2 < 9) {
_local8 = ((_local4 % 3) * 3) + (_local2 % 3);
_local7 = (Math.floor(_local4 / 3) * 3) + Math.floor(_local2 / 3);
_local6 = 1;
while (_local6 <= 9) {
if (sdk_array[_local7][_local8] == undefined) {
if (sdk.Tools.available(_local8, _local7, _local6, sdk_array)) {
_local1 = {x:_local8, y:_local7, number:_local6};
_local3++;
}
}
_local6++;
}
if (_local3 == 1) {
sdk_array[_local1.y][_local1.x] = _local1.number;
_local5++;
}
_local7 = _local4;
_local8 = _local2;
_local3 = 0;
_local6 = 1;
while (_local6 <= 9) {
if (sdk_array[_local7][_local8] == undefined) {
if (sdk.Tools.available(_local8, _local7, _local6, sdk_array)) {
_local1 = {x:_local8, y:_local7, number:_local6};
_local3++;
}
}
_local6++;
}
if (_local3 == 1) {
sdk_array[_local1.y][_local1.x] = _local1.number;
_local5++;
}
_local8 = _local4;
_local7 = _local2;
_local3 = 0;
_local6 = 1;
while (_local6 <= 9) {
if (sdk_array[_local7][_local8] == undefined) {
if (sdk.Tools.available(_local8, _local7, _local6, sdk_array)) {
_local1 = {x:_local8, y:_local7, number:_local6};
_local3++;
}
}
_local6++;
}
if (_local3 == 1) {
sdk_array[_local1.y][_local1.x] = _local1.number;
_local5++;
}
_local2++;
}
_local4++;
}
if (_local5 == 0) {
clearInterval(id);
__busy = false;
}
}
static function solve(out_array) {
__busy = true;
sdk_array = out_array;
id = setInterval(__solve, 200);
}
static function cancel() {
if (__busy) {
clearInterval(id);
__busy = false;
}
}
static var __busy = false;
}
Symbol 3 MovieClip Frame 17
stop();
Symbol 5 Button
on (release) {
this._parent.digit_menu_mc.show(this);
if (this._parent.audio) {
this._parent.btn_snd.start();
}
}
Symbol 8 MovieClip [sudoku field] Frame 1
function setEnabled(val) {
this.button.enabled = val;
}
function getEnabled() {
return(this.button.enabled);
}
function setDigit(digit) {
if (digit) {
this.txt_field.text = digit;
} else {
this.txt_field.text = "";
}
}
function getDigit(Void) {
if (this.txt_field.text == "") {
return(undefined);
}
return(Number(this.txt_field.text));
}
function setBold(val) {
var _local2 = new TextFormat();
_local2.bold = (bold = val);
if (val) {
_local2.color = 102;
} else {
_local2.color = 0;
}
this.txt_field.setNewTextFormat(_local2);
}
var bold = false;
Symbol 24 MovieClip [generating sign animation] Frame 1
stop();
Symbol 24 MovieClip [generating sign animation] Frame 57
this.gotoAndPlay(22);
Symbol 31 MovieClip [paused sign animation] Frame 1
stop();
Symbol 31 MovieClip [paused sign animation] Frame 22
stop();
this.note_anim._visible = this._parent.audio;
Symbol 46 MovieClip Frame 4
stop();
Symbol 47 Button
on (release) {
this._parent.placeDigit(selected_field, 1);
hide();
}
Symbol 48 Button
on (release) {
this._parent.placeDigit(selected_field, 2);
hide();
}
Symbol 49 Button
on (release) {
this._parent.placeDigit(selected_field, 3);
hide();
}
Symbol 50 Button
on (release) {
this._parent.placeDigit(selected_field, 4);
hide();
}
Symbol 51 Button
on (release) {
this._parent.placeDigit(selected_field, 5);
hide();
}
Symbol 52 Button
on (release) {
this._parent.placeDigit(selected_field, 6);
hide();
}
Symbol 53 Button
on (release) {
this._parent.placeDigit(selected_field, 7);
hide();
}
Symbol 54 Button
on (release) {
this._parent.placeDigit(selected_field, 8);
hide();
}
Symbol 55 Button
on (release) {
this._parent.placeDigit(selected_field, 9);
hide();
}
Symbol 57 Button
on (release) {
this._parent.placeDigit(selected_field, undefined);
hide();
}
Symbol 58 MovieClip [digit menu] Frame 1
function show(slctd_fld) {
this._visible = true;
this.background.gotoAndPlay(1);
var _local4 = ((slctd_fld._x < 350) ? 50 : -20);
var _local3 = ((slctd_fld._y < 250) ? 50 : -20);
this._x = slctd_fld._x + _local4;
this._y = slctd_fld._y + _local3;
this.indicator._x = -_local4;
this.indicator._y = -_local3;
if (slctd_fld.getDigit()) {
this.deleteb._visible = true;
this.deleteb._x = -30 + (((slctd_fld.getDigit() - 1) % 3) * 20);
this.deleteb._y = -30 + (Math.floor((slctd_fld.getDigit() - 1) / 3) * 20);
} else {
this.deleteb._visible = false;
}
selected_field = slctd_fld;
}
function hide() {
this._visible = false;
}
var selected_field;
this.onMouseDown = function () {
if (!this.hitTest(this._parent._xmouse, this._parent._ymouse, true)) {
hide();
}
};
Symbol 63 MovieClip Frame 7
stop();
Symbol 64 MovieClip Frame 7
stop();
Symbol 66 MovieClip Frame 7
stop();
Symbol 67 Button
on (release) {
this._parent.startGeneratingNew();
this._parent.setPaused(false);
if (this._parent.audio) {
this._parent.btn_snd.start();
}
this.removeMovieClip();
}
Symbol 69 MovieClip Frame 7
stop();
Symbol 70 MovieClip Frame 7
stop();
Symbol 72 MovieClip Frame 7
stop();
Symbol 73 Button
on (release) {
this._parent.setPaused(false);
if (this._parent.audio) {
this._parent.btn_snd.start();
}
this.removeMovieClip();
}
Symbol 74 MovieClip [gennewpopup] Frame 1
this.fdb.useHandCursor = false;
Symbol 76 Button
on (release) {
switch (this._parent.submode) {
case "generating" :
sdk.Generator.cancel();
break;
case "finalizing" :
sdk.Finalizer.cancel();
}
this._parent.gen_sign_mc.gotoAndPlay(1);
this._parent.gen_sign_mc._visible = false;
this._parent.startSolverMode();
if (this._parent.audio) {
this._parent.btn_snd.start();
}
this.removeMovieClip();
}
Symbol 77 MovieClip [switch to SM] Frame 1
this.fdb.useHandCursor = false;
Symbol 80 Button
on (release) {
this.nextFrame();
}
Symbol 88 Button
on (release) {
this.prevFrame();
}
Symbol 101 MovieClip Frame 1
stop();
Symbol 105 MovieClip Frame 7
stop();
Symbol 106 Button
on (release) {
if (this._parent.workmode == "playmode") {
this._parent.setPaused(false);
}
if (this._parent.audio) {
this._parent.btn_snd.start();
}
this.removeMovieClip();
}
Symbol 107 MovieClip [help window] Frame 1
this.fdb.useHandCursor = false;
Symbol 121 MovieClip Frame 1
stop();
Symbol 126 Button
on (release) {
if (this._parent.audio) {
this._parent.audio = false;
this.gotoAndStop(2);
this._parent.loop_snd.stop();
} else {
this._parent.audio = true;
this.gotoAndStop(1);
this._parent.loop_snd.start();
}
}
Symbol 128 MovieClip Frame 1
stop();
Symbol 130 MovieClip Frame 7
stop();
Symbol 131 MovieClip Frame 7
stop();
Symbol 133 MovieClip Frame 7
stop();
Symbol 134 Button
on (release) {
startPlayMode();
if (audio) {
btn_snd.start();
}
}
Symbol 136 MovieClip Frame 7
stop();
Symbol 137 MovieClip Frame 7
stop();
Symbol 139 MovieClip Frame 7
stop();
Symbol 140 Button
on (release) {
if ((workmode == "playmode") && (submode == "finished")) {
startSolverMode();
} else {
if (!paused) {
setPaused(true);
}
this.attachMovie("switch to SM", "stsm", this.getNextHighestDepth());
}
if (audio) {
btn_snd.start();
}
}
Symbol 142 MovieClip Frame 7
stop();
Symbol 143 MovieClip Frame 7
stop();
Symbol 145 MovieClip Frame 7
stop();
Symbol 146 Button
on (release) {
if (workmode == "playmode") {
if (!paused) {
setPaused(true);
}
}
this.attachMovie("help window", "hwndw", this.getNextHighestDepth());
if (audio) {
btn_snd.start();
}
}
Symbol 148 Button
on (release) {
this.aboutandname.play();
}
Symbol 150 Button
on (release) {
fscommand ("quit");
}
Symbol 152 MovieClip Frame 7
stop();
Symbol 153 MovieClip Frame 7
stop();
Symbol 155 MovieClip Frame 7
stop();
Symbol 156 Button
on (release) {
this._parent.resetSolverMode();
this.txt.text = "Cleared.";
if (this._parent.audio) {
this._parent.btn_snd.start();
}
}
Symbol 158 MovieClip Frame 7
stop();
Symbol 159 Button
on (release) {
this._parent.startSolving();
if (this._parent.audio) {
this._parent.btn_snd.start();
}
}
Symbol 165 MovieClip Frame 7
stop();
Symbol 166 MovieClip Frame 7
stop();
Symbol 168 MovieClip Frame 7
stop();
Symbol 169 Button
on (release) {
if (this._parent.workmode == "playmode") {
if (this._parent.submode == "playing") {
if (!this._parent.paused) {
this._parent.setPaused(true);
}
this._parent.attachMovie("gennewpopup", "gnpu", this._parent.getNextHighestDepth());
} else if (this._parent.submode == "finished") {
this._parent.startGeneratingNew();
}
}
if (this._parent.audio) {
this._parent.btn_snd.start();
}
}
Symbol 171 Button
on (release) {
if (this._parent.submode != "finished") {
this._parent.setPaused(true);
}
}
Symbol 173 Button
on (release) {
this._parent.setPaused(false);
}
Symbol 176 MovieClip Frame 1
stop();