Combined Code
movieClip 4 {
}
movieClip 5 fire7 {
frame 1 {
cacheAsBitmap = true;
facing = _rotation * 0.01745329;
_rotation = Math.random() * 360;
this.onEnterFrame = function () {
ys = Math.sin(facing) * speed;
xs = Math.cos(facing) * speed;
_y = _y - (ys + 1);
_x = _x - 30;
_xscale = _xscale + 100;
_yscale = _yscale + 100;
_x = _x + xs;
_alpha = _alpha - (7.5 + Math.random());
if (_alpha <= 0) {
removeMovieClip(this._parent);
}
};
}
}
movieClip 8 {
}
movieClip 9 {
}
movieClip 41 gunBazooka {
frame 1 {
stop();
}
}
movieClip 43 {
}
movieClip 75 gunZapper {
}
movieClip 108 gunTau {
}
movieClip 141 gunRay {
}
movieClip 174 gunFlame {
}
movieClip 207 gunSniper {
}
movieClip 240 gunMachineGun {
}
movieClip 249 poo_anim {
frame 9 {
removeMovieClip(this);
}
}
movieClip 251 poo {
}
movieClip 284 gunShotGun {
}
movieClip 317 gunMouschete {
}
movieClip 332 {
frame 8 {
stop();
}
}
movieClip 336 {
frame 7 {
stop();
}
}
movieClip 365 fire4_bum {
frame 13 {
removeMovieClip(this);
}
}
movieClip 367 {
}
movieClip 377 fire4 {
frame 15 {
removeMovieClip(this);
}
}
movieClip 383 fire8_bum {
frame 24 {
removeMovieClip(this);
}
}
movieClip 386 {
}
movieClip 390 fire8 {
frame 7 {
removeMovieClip(this);
}
}
movieClip 395 {
}
movieClip 404 fire9 {
frame 9 {
removeMovieClip(this);
}
}
movieClip 409 {
}
movieClip 410 fire6 {
frame 7 {
removeMovieClip(this);
}
}
movieClip 412 {
}
movieClip 413 fire3 {
frame 7 {
removeMovieClip(this);
}
}
movieClip 416 fire5 {
frame 5 {
removeMovieClip(this);
}
}
movieClip 418 {
}
movieClip 419 fire2 {
frame 4 {
removeMovieClip(this);
}
}
movieClip 422 {
}
movieClip 423 fire1 {
frame 8 {
removeMovieClip(this);
}
}
movieClip 425 fearthure {
}
frame 1 {
stop();
stop();
demo_data = '';
public_version = true;
_root.isRelease = false;
_root.enableAchievements = false;
_root.enableHighScore = false;
if (demo_data != '') {
now = new Date();
EPOCH_TIME = now.getTime();
if (EPOCH_TIME < demo_data) {
} else {
loadMovie('', _root);
}
}
if (_root.enableHighScore) {
loadVariablesNum('http://gamefilez.mofunzone.com/game_scores/damn_birds_2/mfz2.php', 0);
}
if (!public_version) {
MoFunZone_path = _url;
MoFunZoneOK = false;
mfzstr = MoFunZone_path.split('.');
com = (mfzstr[2].split('/'))[0];
if (mfzstr[1] + '.' + com == 'mofunzone.com') {
MoFunZoneOK = true;
}
MoFunZone_loader = new LoadVars();
MoFunZone_loader.load('http://www.mofunzone.com/hotlink/check_online_game.php');
MoFunZone_loader.onLoad = function (success) {
if (success && this.mofunzone_allow_game && MoFunZoneOK) {
} else {
getURL('http://www.mofunzone.com/', '_self');
loadMovie('', _root);
}
};
}
if (_root.enableAchievements) {
var mfz_achievement = null;
var config = new MoFunZoneAPI.AchievementConfig();
config.test = !isRelease;
config.gameid = 'damn_birds_2';
config.autoPosition = 'cc';
config.bringToTop = true;
config.fadeout = true;
config.dialogScale = 1.5;
MoFunZoneAPI.AchievementLoaderAS2.readyCallBack(waitForReady);
MoFunZoneAPI.AchievementLoaderAS2.loadAchievement('http://www.mofunzone.com/api/AchievementAS2.swf', this, config);
}
}
movieClip 427 {
}
movieClip 429 {
}
movieClip 431 {
}
movieClip 433 {
}
movieClip 435 {
}
movieClip 436 {
}
movieClip 438 {
}
movieClip 440 {
}
movieClip 442 {
}
movieClip 444 {
}
movieClip 446 {
}
movieClip 448 {
}
movieClip 449 {
}
movieClip 450 {
}
movieClip 452 {
}
movieClip 453 {
frame 11 {
_parent.gotoAndStop(2);
}
}
movieClip 454 {
}
movieClip 456 {
}
movieClip 459 {
}
movieClip 461 {
}
movieClip 462 {
}
movieClip 463 {
frame 1 {
this.onEnterFrame = function () {
bytesloaded = Math.round(_root.getBytesLoaded());
bytestotal = Math.round(_root.getBytesTotal());
percent = bytesloaded / bytestotal;
barmask._xscale = percent * 100;
};
}
}
movieClip 465 {
}
movieClip 470 {
}
// unknown tag 88 length 149
movieClip 490 {
}
movieClip 494 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.nextFrame();
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 502 {
}
movieClip 504 {
}
movieClip 505 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.nextFrame();
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 512 {
}
movieClip 513 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.nextFrame();
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 520 {
}
movieClip 521 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.nextFrame();
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 528 {
}
movieClip 529 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.nextFrame();
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 536 {
}
movieClip 537 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.nextFrame();
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 544 {
}
movieClip 545 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.nextFrame();
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 552 {
}
movieClip 553 {
frame 1 {
if (Math.random() > 0.5) {
_xscale = -_xscale;
_x = _x - _parent.shiftamt;
}
}
frame 90 {
if (_parent.isloaded) {
_parent.gotoAndStop(10);
} else {
thenextframe = Math.ceil(Math.random() * 8) + 1;
if (thenextframe == _parent._currentframe) {
_parent.gotoAndStop(2);
} else {
_parent.gotoAndStop(thenextframe);
}
}
}
}
movieClip 554 {
}
movieClip 559 {
}
movieClip 560 {
frame 133 {
_root.play();
}
}
movieClip 561 {
frame 1 {
stop();
_root.stop();
isloaded = false;
this.onEnterFrame = function () {
bytesloaded = Math.round(_root.getBytesLoaded());
bytestotal = Math.round(_root.getBytesTotal());
percent = bytesloaded / bytestotal;
if (bytesloaded == bytestotal) {
isloaded = true;
}
};
this.onRelease = function () {
getURL('http://www.mofunzone.com/', '_blank');
};
}
}
movieClip 2152 __Packages.MoFunZoneAPI.AchievementLoaderAS2 {
#initclip
if (!_global.MoFunZoneAPI) {
_global.MoFunZoneAPI = new Object();
}
if (!_global.MoFunZoneAPI.AchievementLoaderAS2) {
var v1 = function () {};
MoFunZoneAPI.AchievementLoaderAS2 = v1;
var v2 = v1.prototype;
v1.achievementreport = function () {
trace('version :' + MoFunZoneAPI.AchievementLoaderAS2.achievement_root.apiversion);
for (var v1 in MoFunZoneAPI.AchievementLoaderAS2.achievement_cfg) {
MoFunZoneAPI.AchievementLoaderAS2.achievement_root[v1] = MoFunZoneAPI.AchievementLoaderAS2.achievement_cfg[v1];
}
MoFunZoneAPI.AchievementLoaderAS2.achievement_root.play();
clearInterval(MoFunZoneAPI.AchievementLoaderAS2.privatetimer);
MoFunZoneAPI.AchievementLoaderAS2.privatetimer = setInterval(MoFunZoneAPI.AchievementLoaderAS2.waitforready, 1000);
};
v1.waitforready = function () {
if (MoFunZoneAPI.AchievementLoaderAS2.achievement_root.achistatus == 'ok') {
trace('ready');
if (MoFunZoneAPI.AchievementLoaderAS2.readyFuntion != null) {
MoFunZoneAPI.AchievementLoaderAS2.readyFuntion();
}
clearInterval(MoFunZoneAPI.AchievementLoaderAS2.privatetimer);
}
};
v1.readyCallBack = function (funtionPointer) {
MoFunZoneAPI.AchievementLoaderAS2.readyFuntion = funtionPointer;
};
v1.getAPI = function () {
return MoFunZoneAPI.AchievementLoaderAS2.achievement_root;
};
v1.loadAchievement = function (achievement_address, topleveltimeline, achievement_config) {
System.security.allowDomain('*');
MoFunZoneAPI.AchievementLoaderAS2.achievement_root = topleveltimeline.createEmptyMovieClip('output', topleveltimeline.getNextHighestDepth());
MoFunZoneAPI.AchievementLoaderAS2.achievement_cfg = achievement_config;
var v2 = new Object();
v2.onLoadComplete = function (target_mc) {
trace('API load complete');
MoFunZoneAPI.AchievementLoaderAS2.privatetimer = setInterval(MoFunZoneAPI.AchievementLoaderAS2.achievementreport, 1000);
};
var v1 = new MovieClipLoader();
v1.addListener(v2);
v1.loadClip(achievement_address, MoFunZoneAPI.AchievementLoaderAS2.achievement_root);
};
v1.achievement_root = null;
v1.achievement_cfg = null;
v1.privatetimer = null;
v1.readyFuntion = null;
ASSetPropFlags(MoFunZoneAPI.AchievementLoaderAS2.prototype, null, 1);
}
#endinitclip
}
movieClip 2153 __Packages.MoFunZoneAPI.AchievementConfig {
#initclip
if (!_global.MoFunZoneAPI) {
_global.MoFunZoneAPI = new Object();
}
if (!_global.MoFunZoneAPI.AchievementConfig) {
var v1 = function () {
this.test = true;
this.gameid = '';
this.autoPosition = 'cc';
this.bringToTop = true;
this.fadeout = true;
this.dialogScale = 1;
};
MoFunZoneAPI.AchievementConfig = v1;
var v2 = v1.prototype;
v2.test = true;
v2.gameid = '';
v2.autoPosition = 'cc';
v2.bringToTop = true;
v2.fadeout = true;
v2.dialogScale = 1;
ASSetPropFlags(MoFunZoneAPI.AchievementConfig.prototype, null, 1);
}
#endinitclip
}
movieClip 2154 __Packages.As.clock {
#initclip
if (!_global.As) {
_global.As = new Object();
}
if (!_global.As.clock) {
var v1 = function (av) {
this.avatar = av;
};
As.clock = v1;
var v2 = v1.prototype;
v2.onTimer = function () {
this.valStart -= this.speed;
this.minute = Math.floor(this.valStart / 60);
if (this.minute > 0) {
this.sec = Math.floor(this.valStart % this.minute * 60);
} else {
this.sec = Math.floor(this.valStart);
}
if ((String(this.minute)).length == 1) {
this.minute = '0' + this.minute;
}
if ((String(this.sec)).length == 1) {
this.sec = '0' + this.sec;
}
this.vInc += this.speed * 2;
if (this.vInc >= 1) {
this.enTx = !this.enTx;
this.vInc = 0;
}
this.vt = ':';
if (this.enTx) {
this.vt = ' ';
}
if (this.valStart <= this.speed) {
this.vt = ':';
}
this.avatar.mins.text = this.minute;
this.avatar.sec.text = this.sec;
this.avatar.bat.text = this.vt;
};
v2.stopTimer = function () {
delete this.avatar.onEnterFrame;
};
v2.startTimer = function (val, sen, sp, fs) {
this.vInc = 0;
if (_root[this.avatar] != _root) {
this.avatar = _root[this.avatar];
}
this.valStart = val;
this.sens = sen;
this.speed = sp;
this.fStop = fs;
var parinte = this;
this.avatar.onEnterFrame = function () {
if (!_root.pauza) {
if (parinte.valStart <= parinte.speed) {
parinte.valStart = parinte.speed;
delete this.onEnterFrame;
parinte.fStop();
}
parinte.onTimer();
}
};
};
v2.avatar = '';
v2.valStart = '';
v2.sens = 1;
v2.idAnim = '';
v2.minute = 0;
v2.sec = 0;
v2.speed = 1;
v2.enTx = true;
v2.vInc = 0;
v2.fStop = '';
v2.vt = ':';
ASSetPropFlags(As.clock.prototype, null, 1);
}
#endinitclip
}
movieClip 2155 __Packages.As.utils {
#initclip
if (!_global.As) {
_global.As = new Object();
}
if (!_global.As.utils) {
var v1 = function () {};
As.utils = v1;
var v2 = v1.prototype;
v1.zecimale = function (number, precision) {
var v1 = Math.pow(10, precision);
return Math.round(v1 * number) / v1;
};
v1.radiani = function (_angle) {
return _angle * 3.141593 / 180;
};
v1.grade = function (_angle) {
return _angle * 180 / 3.141593;
};
v1.debug = function (_v) {
trace('x=' + _v.x + ' y=' + _v.y + ' z=' + _v.z);
};
v1.vector = function (_px, _py, _pz) {
var v1 = new Object();
v1.x = _px;
v1.y = _py;
v1.z = _pz;
return v1;
};
v1.diferenta = function (_v1, _v2) {
var v1 = new Object();
v1.x = _v2.x - _v1.x;
v1.y = _v2.y - _v1.y;
v1.z = _v2.z - _v1.z;
return v1;
};
v1.suma = function (_v1, _v2) {
var v1 = new Object();
v1.x = _v1.x + _v2.x;
v1.y = _v1.y + _v2.y;
v1.z = _v1.z + _v2.z;
return v1;
};
v1.modul = function (_v1) {
return Math.sqrt(Math.pow(_v1.x, 2) + Math.pow(_v1.y, 2) + Math.pow(_v1.z, 2));
};
v1.multiplica = function (_v1, _val) {
var v1 = new Object();
v1.x = _v1.x * _val;
v1.y = _v1.y * _val;
v1.z = _v1.z * _val;
return v1;
};
v1.point_vector = function (_p) {
var v1 = new Object();
v1.x = _p._x;
v1.y = _p._y;
v1.z = 0;
return v1;
};
v1.vector_point = function (_v, _p) {
_p._x = _v.x;
_p._y = _v.y;
};
v1.dot_product = function (_v1, _v2) {
var v2 = _v1.x * _v2.x + _v1.y * _v2.y + _v1.z * _v2.z;
return v2;
};
v1.unghi = function (_v1, _v2) {
var v1 = As.utils.modul(_v1);
var v2 = As.utils.modul(_v2);
if (v1 == 0) {
v1 = 1;
}
if (v2 == 0) {
v2 = 1;
}
var v3 = 1;
var v5 = As.utils.dot_product(_v1, _v2) / v1 * v2;
if (_v1.y < _v2.y) {
v3 = -1;
}
var v6 = As.utils.zecimale(As.utils.grade(Math.acos(v5)), 2) * v3;
return v6;
};
v1.unghi_laturi = function (_a, _b, _c) {
var v1 = As.utils.diferenta(_b, _a);
var v2 = As.utils.diferenta(_b, _c);
return As.utils.unghi(v1, v2);
};
v1.panta = function (v1, v2) {
var v2 = As.utils.vector(v2.x + 1, v2.y, v2.z);
var v3 = As.utils.unghi_laturi(v1, v2, v2);
return v3;
};
v1.panta2 = function (v1, v2) {
var v1 = -As.utils.panta(v1, v2);
if (v1 < 0) {
v1 = 360 + v1;
}
return v1;
};
v1.panta3 = function (v1, v2, u) {
u = As.utils.panta(v1, v2) - u;
if (u < 0) {
u = 360 + u;
}
return u;
};
v1.distanta = function (_v1, _v2) {
var v3 = Math.sqrt(Math.pow(_v2.y - _v1.y, 2) + Math.pow(_v2.x - _v1.x, 2) + Math.pow(_v2.z - _v1.z, 2));
if (_v1.x == _v2.x && _v1.y == _v2.y && _v1.z == _v2.z) {
v3 = 0;
}
return v3;
};
v1.rnd = function (_min, _max) {
var v1 = Math.floor(Math.floor(Math.random() * (_max - _min + 1)) + _min);
return v1;
};
v1.bezier = function (arr, t) {
t = Math.min(Math.max(t, 0), 1);
var v2 = 3 * (arr[2] - arr[0]);
var v4 = 3 * (arr[4] - arr[2]) - v2;
var v5 = arr[6] - arr[0] - v2 - v4;
var v6 = v5 * Math.pow(t, 3) + v4 * Math.pow(t, 2) + v2 * Math.pow(t, 1) + arr[0];
if (isNaN(v6)) {
v6 = arr[0];
}
v2 = 3 * (arr[3] - arr[1]);
v4 = 3 * (arr[5] - arr[3]) - v2;
v5 = arr[7] - arr[1] - v2 - v4;
var v7 = v5 * Math.pow(t, 3) + v4 * Math.pow(t, 2) + v2 * Math.pow(t, 1) + arr[1];
if (isNaN(v7)) {
v7 = arr[1];
}
var v8 = As.utils.vector(v6, v7, 0);
return v8;
};
v1.bezierRotate = function (arr, t1, t2) {
var v1 = As.utils.bezier(arr, t1);
var v2 = As.utils.bezier(arr, t2);
var v3 = As.utils.panta(v2, v1);
return v3;
};
v1.minMaxInterval = function (_mi1, _Ma1, _mi2, _Ma2, _pos) {
function procInterval(_mi, _ma, _pos) {
var v1 = (_pos - _mi) / (_ma - _mi);
if (_pos <= _mi) {
v1 = 0;
}
if (_pos >= _ma) {
v1 = 1;
}
return v1;
}
function calcProcInterval(_mi, _ma, _proc) {
var v1 = (_ma + _mi) * _proc;
if (_proc <= 0) {
v1 = _mi;
}
if (_proc >= 1) {
v1 = _ma;
}
return v1;
}
var v4 = procInterval(_mi1, _mi2, _pos);
var v2 = _Ma1 + (_Ma2 - _Ma1) * v4;
if (_pos <= _mi1) {
v2 = _Ma1;
}
if (_pos >= _mi2) {
v2 = _Ma2;
}
return v2;
};
v1.gaseste_vector = function (_v1, _v2, _d) {
var v1 = As.utils.suma(_v1, As.utils.multiplica(As.utils.diferenta(_v1, _v2), _d));
return v1;
};
v1.gaseste_vector_lungime = function (_v1, _v2, _l) {
var v1 = As.utils.diferenta(_v1, _v2);
var v2 = _l / As.utils.modul(v1);
var v3 = As.utils.suma(_v1, As.utils.multiplica(v1, v2));
return v3;
};
v1.deseneaza_linie = function (_s_mc, _v1, _v2, _col, _trsp, _gr, cum) {
if (cum) {
_s_mc.clear();
}
_s_mc.lineStyle(_gr, _col, _trsp);
_s_mc.moveTo(_v1.x, _v1.y);
_s_mc.lineTo(_v2.x, _v2.y);
};
v1.roteste_z = function (_v1, _vo, _grd) {
var v6;
var v7;
var v9;
var v4 = Math.sin(As.utils.radiani(_grd));
var v3 = Math.cos(As.utils.radiani(_grd));
var v1 = new Object();
var v2 = As.utils.vector(_vo.x, _vo.y, _vo.z);
var v8 = As.utils.vector(_v1.x, _v1.y, _v1.z);
v1 = As.utils.diferenta(v2, v8);
v9 = v1.z;
v6 = v1.x * v3 - v1.y * v4;
v7 = v1.x * v4 + v1.y * v3;
var v10 = As.utils.suma(v2, As.utils.vector(v6, v7, v9));
return v10;
};
v1.rotesteDeplasare = function (_v1, _dep, _grd) {
var v3 = As.utils.vector(_v1.x + _dep, _v1.y, _v1.z);
var v2 = As.utils.roteste_z(v3, _v1, _grd);
return v2;
};
v1.semn = function (val) {
var v1 = val / Math.abs(val);
if (val == 0) {
v1 = 1;
}
return v1;
};
ASSetPropFlags(As.utils.prototype, null, 1);
}
#endinitclip
}
movieClip 2156 __Packages.As.bird {
#initclip
if (!_global.As) {
_global.As = new Object();
}
if (!_global.As.bird) {
var v1 = function (hold, av, cr, sz, sp, hMi, hMa, can, bez, rot, rid, po, por, rf, ko, ms, co, yc1, yc2, tc, ml, pp, wn, ps, snd) {
this.holder = hold;
this.avatar = av;
this.coord = cr;
this.size = sz;
this.speed = sp;
this.hMin = hMi;
this.hMax = hMa;
this.canTurn = can;
this.useBezier = bez;
this.ridica = rid;
this.pooRand = por;
this.randomFly = rf;
this.keepOrigin = ko;
this.pooPower = pp;
this.win = wn;
this.pooSize = 100;
this.sound = '';
if (ps != undefined) {
this.pooSize = ps;
}
if (ml != undefined) {
this.maxLife = ml;
}
++_root.birdNumber;
var mc = this.holder[this.avatar].duplicateMovieClip('bird' + _root.birdNumber, this.holder.getNextHighestDepth());
if (snd != undefined) {
this.sound = snd[As.utils.rnd(0, snd.length - 1)];
this.playSound(this.sound);
}
mc.avatar = this.avatar;
if (yc1 != undefined) {
this.yCoef1 = yc1;
}
if (yc2 != undefined) {
this.yCoef2 = yc2;
}
if (rot != undefined) {
this.rotate = rot;
}
if (tc != undefined) {
this.turnChance = tc;
}
this.obj = mc;
mc.semn = Math.pow(-1, As.utils.rnd(1, 2));
mc._x = this.coord[2];
if (mc.semn == 1) {
mc._x = this.coord[0];
}
mc._y = As.utils.rnd(this.hMin, this.hMax);
mc._xscale = this.size * mc.semn;
mc._yscale = this.size;
mc.urcaMax = 0;
mc.urcaCrr = 0;
mc.canUrca = false;
mc.urcaSpeed = 0;
this.maxSpeed = this.speed;
if (ms != undefined) {
this.maxSpeed = ms;
}
if (co != undefined) {
this.chanceOfChanginDirection = co;
}
mc.crrSpeed = As.utils.rnd(this.speed, this.maxSpeed);
if (this.useBezier) {
var v11 = this.coord[0];
var v6 = this.coord[2];
if (mc.semn == -1) {
v11 = this.coord[2];
v6 = this.coord[0];
}
var v27 = As.utils.rnd(this.hMin, this.hMax);
var v24 = As.utils.rnd(this.hMin, this.hMax);
var v21 = As.utils.rnd(this.coord[0], this.coord[2]);
var v30 = As.utils.rnd(this.coord[0], this.coord[2]);
var v29 = As.utils.rnd(this.hMin, this.hMax);
var v22 = As.utils.rnd(this.hMin, this.hMax);
if (this.keepOrigin != undefined) {
v21 = As.utils.rnd(this.keepOrigin[2], this.keepOrigin[3]);
v30 = As.utils.rnd(this.keepOrigin[2], this.keepOrigin[3]);
v22 = v29;
v11 = this.keepOrigin[0];
v27 = this.keepOrigin[1];
v6 = this.keepOrigin[4];
v24 = this.keepOrigin[5];
if (mc.semn == -1) {
v11 = this.keepOrigin[4];
v6 = this.keepOrigin[0];
}
}
this.bezArr = [v11, v27, v21, v29, v30, v22, v6, v24];
}
var parinte = this;
mc.bulletPower = [0, 0];
mc.life = this.maxLife;
mc.maxLife = this.maxLife;
mc.boost = 3;
mc.boostDown = 3;
mc.maxBoost = 30;
mc.maxBoostU = 28;
mc.maxBoostX = 10;
mc.depI = 30;
mc.dep = mc.depI;
mc.depAcc = 10;
mc.depSpeed = 0;
mc.canWalk = true;
mc.shooted = false;
mc.waitShoot = _root.waitShoot;
mc.onEnterFrame = function () {
if (!_root.pauza) {
var v8 = _root.crrLevel;
var v37 = 0;
var v38 = 30 / parinte.speed;
if (parinte.dying) {
this._rotation = 0;
this._y -= this.boostUp;
var v28 = this.bulletPower[0];
var v12 = As.utils.minMaxInterval(0, this.maxBoostX, 180, -this.maxBoostX, -v28);
if (this.bulletPower[0] <= 0) {
this._x += v12;
this._x = this._x;
} else {
if (this.bulletPower[0] <= 90) {
this._x += v12;
} else {
this._x -= v12;
}
}
if (this.boostUp >= 0) {
this.boostUp -= this.boost;
} else {
this.boostUp -= this.boostDown;
}
if (this._y >= 600) {
parinte.dye();
}
mc.link._x = mc._x;
mc.link._y = mc._y;
}
if (this.shooted) {
if (!this.bulletPower[2]) {
this.depSpeed += this.depAcc;
this.dep -= this.depSpeed;
if (this.dep >= 0) {
var v19 = As.utils.rotesteDeplasare(As.utils.point_vector(this), this.dep, this.bulletPower[0]);
this._x = v19.x;
this._y = v19.y;
}
}
this.canWalk = true;
if (this.dep <= -mc.waitShoot) {
this.dep = this.depI;
this.depSpeed = 0;
this.shooted = false;
if (this.life > 0) {
parinte.canPlay = true;
this.gotoAndPlay(1);
}
}
}
if (!parinte.dying) {
if (this.bulletPower[1] != 0) {
this.rem = this._currentframe;
this.life -= this.bulletPower[1];
this.shooted = true;
this.canWalk = false;
parinte.canPlay = false;
if (this.bulletPower[2]) {
this.shooted = false;
this.canWalk = true;
parinte.canPlay = true;
this.gotoAndStop(1);
} else {
this.gotoAndStop('shooted');
}
this.bulletPower[1] = 0;
if (this.life <= 0) {
++_root.nrShooted;
var v4 = _root.birds2[parinte.avatar + '_dye'].duplicateMovieClip(parinte.avatar + '_dye' + _root.birdNumber, _root.birds2.getNextHighestDepth());
if (_root.killSoundConst >= _root.killSoundConstMax) {
if (_root.crrOverSound._currentframe == 1 || _root.crrOverSound._currentframe == undefined) {
var v20 = _root['sound_kill' + _root.crrTime + '_' + As.utils.rnd(1, 3)];
if (_root.crrTime == 3) {
parinte.playSound(v20, 255);
} else {
parinte.playSound(v20, 125);
}
_root.killSoundConst = 0;
}
}
v4._xscale = mc._xscale;
v4._yscale = mc._yscale;
v4._x = mc._x;
v4._y = mc._y;
mc.link = v4;
if (mc.tint == 0) {
v4.stop();
}
if (mc.tint != undefined) {
v4.tint = mc.tint;
parinte.setTint(v4);
}
_root.win += parinte.win;
_root.score += parinte.win;
++_root.totalBirds;
_root.mcStativ.txScore.text = _root.score;
var v3 = this.bulletPower[0];
if (this.bulletPower[0] <= 0) {
var v17 = 0;
if (v3 <= 0 && v3 >= -90) {
v17 = As.utils.minMaxInterval(0, 0, 90, this.maxBoostU, -v3);
}
if (v3 <= -90) {
v17 = As.utils.minMaxInterval(90, this.maxBoostU, 180, 0, -v3);
}
this.boostUp = v17;
}
if (this.bulletPower[0] > 0) {
v17 = 0;
if (v3 > 0 && v3 <= 90) {
v17 = As.utils.minMaxInterval(0, 0, 90, this.maxBoost, v3);
}
if (v3 >= 90) {
v17 = As.utils.minMaxInterval(90, this.maxBoost, 180, 0, v3);
}
this.boostUp = -v17;
}
parinte.dying = true;
this.gotoAndStop('dead');
parinte.canPlay = false;
}
}
var v5 = parinte.pooRand - parinte.pooRand * v8 * _root.factPoo;
var v7 = _root.maxLevels - _root.crrLevel - 15;
if (v7 <= 5) {
v7 = 5;
}
if (v7 <= 10) {
if (mc._x >= 250 && mc._x <= 400) {
v5 = As.utils.rnd(0, 5);
} else {
v5 = As.utils.rnd(0, 100);
}
}
if (As.utils.rnd(0, v7) == 0) {
if (mc._x >= 250 && mc._x <= 400) {
v5 = As.utils.rnd(0, 5);
}
}
if (v5 <= _root.minPooFrecv) {
v5 = _root.minPooFrecv;
}
if (As.utils.rnd(0, v5) == 0) {
++_root.pooNumber;
var mc2 = '';
var mc2 = _root.pooHolder.attachMovie('poo', 'poo' + _root.pooNumber, _root.pooHolder.getNextHighestDepth());
mc2._xscale = parinte.pooSize;
mc2._yscale = parinte.pooSize;
mc2.gotoAndStop(1);
mc2._x = mc._x;
mc2._y = mc._y;
mc2.speed = 0;
mc2.onEnterFrame = function () {
mc2.speed += 1;
this.clear();
this.lineStyle(5, 16776960, 0);
this.moveTo(0, 0);
this.lineTo(0, mc2.speed * 2);
mc2._y += this.speed;
var v7 = false;
var v3 = As.colission.checkForCollision(this, _root.statues.statue.body.guns);
var v4 = null;
if (v3 == null) {
v4 = As.colission.checkForCollision(this, _root.statues.statue);
}
if (v3 != null) {
v7 = true;
}
if (v4 != null) {
v7 = true;
}
var v6 = false;
if (v7) {
var v20 = _root.armour;
var v5 = parinte.pooPower / As.utils.minMaxInterval(0, 1, 5000, 150, v20);
if (v5 <= 0) {
v5 = 0;
}
mc2._y = v4.y;
if (v4.y == undefined) {
mc2._y = v3.y;
}
if (v3 != null) {
var v9 = _root.statues.trg._x + _root.statues.statue.body._x;
var v8 = _root.statues.trg._y + _root.statues.statue.body._y;
var v19 = mc2._x;
var v17 = mc2._y;
var v15 = _root.statues.statue.body.guns.gun.guide._x;
var v14 = _root.statues.statue.body.guns.gun.guide._y;
var v13 = parinte.distanta(v9, v8, v19, v17);
var v12 = parinte.distanta(v9, v8, v9 + v15, v8 + v14);
if (v13 <= v12) {
if (_root.sound_poo._currentframe == 1) {
_root.sound_poo.gotoAndPlay(2);
}
_root.pooLevel += v5;
v6 = true;
}
} else {
if (_root.sound_poo._currentframe == 1) {
_root.sound_poo.gotoAndPlay(2);
}
_root.pooLevel += v5;
v6 = true;
}
if (v6) {
if (_root.hitSoundConst >= _root.hitSoundConstMax) {
var v10 = _root['sound_hit' + _root.crrTime + '_' + As.utils.rnd(1, 3)];
_root.crrOverSound = v10;
if (_root.crrOverSound._currentframe == 1 || _root.crrOverSound._currentframe == undefined) {
if (_root.crrTime == 3) {
parinte.playSound(v10, 255);
} else {
parinte.playSound(v10, 125);
}
_root.hitSoundConst = 0;
}
}
}
var v18 = this._x;
var v16 = this._y;
delete this.onEnterFrame;
removeMovieClip(this);
var v11 = _root.pooHolder2.attachMovie('poo_anim', 'poo' + _root.pooNumber, _root.pooHolder2.getNextHighestDepth());
v11._x = v18;
v11._y = v16;
}
if (mc2._y >= parinte.coord[3]) {
delete this.onEnterFrame;
removeMovieClip(this);
}
};
}
if (mc.canWalk) {
if (parinte.canTurn) {
var v35 = As.utils.rnd(0, parinte.turnChance);
if (v35 == 0) {
if (mc._x >= 20 && mc._x <= 550) {
mc.semn = -mc.semn;
mc._xscale = -mc._xscale;
}
}
}
if (!mc.canUrca) {
if (As.utils.rnd(0, parinte.ridica) == 0) {
if (mc._x > 20 && mc._x <= 500) {
mc.canUrca = true;
mc.urcaSpeed = As.utils.rnd((mc.crrSpeed / 2) * parinte.yCoef1, mc.crrSpeed * parinte.yCoef2) * Math.pow(-1, As.utils.rnd(0, 1));
if (mc.urcaSpeed != 0) {
mc.saveSpeed = mc.crrSpeed;
mc.crrSpeed = Math.abs(As.utils.rnd(mc.urcaSpeed, mc.urcaSpeed));
}
}
}
}
if (mc.canUrca) {
var v24 = As.utils.rnd(0, parinte.chanceOfChanginDirection);
if (v24 == 0) {
mc.canUrca = false;
mc.urcaSpeed = 0;
mc.crrSpeed = mc.saveSpeed;
}
}
if (mc._xscale >= 0) {
mc._rotation = -parinte.rotate;
} else {
mc._rotation = parinte.rotate;
}
if (parinte.randomFly) {
if (As.utils.rnd(0, 10) == 0) {
parinte.canPlay = !parinte.canPlay;
}
}
if (parinte.canPlay) {
mc.play();
} else {
mc.stop();
}
if (parinte.useBezier) {
var v27 = parinte.pos;
parinte.pos += (parinte.speed + v8 * _root.factSpeed) / 400;
var v25 = parinte.pos;
var v31 = As.utils.bezierRotate(parinte.bezArr, v27, v25);
if (parinte.randomFly) {
mc._rotation = 90 + v31;
} else {
if (mc.semn == 1) {
mc._rotation = parinte.rotate;
} else {
mc._rotation = -parinte.rotate;
}
}
if (parinte.pos >= 1) {
parinte.pos = 1;
}
var v21 = As.utils.bezier(parinte.bezArr, parinte.pos);
mc._x = v21.x;
mc._y = v21.y;
} else {
mc._x += mc.crrSpeed * mc.semn + mc.semn * v8 * _root.factSpeed;
mc._y += mc.urcaSpeed + v8 * _root.factSpeed / 10;
}
if (mc._y <= -100) {
parinte.dye();
}
if (mc._y > 600) {
parinte.dye();
}
if (mc.semn == 1) {
if (mc._x >= 700) {
parinte.dye();
}
}
if (mc.semn == -1) {
if (mc._x <= -100) {
parinte.dye();
}
}
}
}
}
};
};
As.bird = v1;
var v2 = v1.prototype;
v2.distanta = function (a, b, c, d) {
var v1 = Math.sqrt(Math.pow(d - b, 2) + Math.pow(c - a, 2));
if (a == b and c == d) {
v1 = 0;
}
return v1;
};
v2.setTint = function (mc) {
var v3 = new flash.geom.Transform(mc);
var v1 = v3.colorTransform;
v1.redMultiplier = mc.tint;
v1.greenMultiplier = mc.tint;
v1.blueMultiplier = mc.tint;
v3.colorTransform = v1;
};
v2.stopSound = function (mc) {
var v1 = new Sound(mc);
v1.stop();
mc.gotoAndStop(1);
};
v2.playSound = function (mc, vol) {
var v1 = new Sound(mc);
if (vol == undefined) {
v1.setVolume(100);
mc.gotoAndPlay(2);
return mc;
}
v1.setVolume(vol);
mc.gotoAndPlay(2);
return mc;
};
v2.dye = function () {
this.stopSound(this.sound);
--_root.nrBirds;
removeMovieClip(this.obj.link);
removeMovieClip(this.obj);
};
v2.holder = '';
v2.avatar = '';
v2.speed = 1;
v2.size = 100;
v2.hMin = 300;
v2.hMax = 0;
v2.xMin = 0;
v2.xMax = 400;
v2.canTurn = false;
v2.coord = [];
v2.obj = '';
v2.bezArr = '';
v2.useBezier = false;
v2.pos = 0;
v2.canPlay = true;
v2.rotate = 0;
v2.ridica = 0;
v2.pooRand = 100;
v2.randomFly = false;
v2.keepOrigin = [];
v2.maxSpeed = 0;
v2.chanceOfChanginDirection = 1;
v2.yCoef1 = 1;
v2.yCoef2 = 1;
v2.turnChance = 120;
v2.dying = false;
v2.maxLife = 40;
v2.pooPower = 0;
v2.win = 0;
ASSetPropFlags(As.bird.prototype, null, 1);
}
#endinitclip
}
movieClip 2157 __Packages.As.colission {
#initclip
if (!_global.As) {
_global.As = new Object();
}
if (!_global.As.colission) {
var v1 = function () {};
As.colission = v1;
var v2 = v1.prototype;
v1.checkForCollision = function (p_clip1, p_clip2, p_alphaTolerance) {
if (p_alphaTolerance == undefined) {
p_alphaTolerance = 255;
}
var v7 = p_clip1.getBounds(_root);
var v6 = p_clip2.getBounds(_root);
if (v7.xMax < v6.xMin || v6.xMax < v7.xMin || (v7.yMax < v6.yMin || v6.yMax < v7.yMin)) {
return null;
}
var v3 = {};
v3.xMin = Math.max(v7.xMin, v6.xMin);
v3.xMax = Math.min(v7.xMax, v6.xMax);
v3.yMin = Math.max(v7.yMin, v6.yMin);
v3.yMax = Math.min(v7.yMax, v6.yMax);
var v5 = p_clip1.transform.matrix;
var v2 = p_clip1._parent;
while (v2 != _root) {
v5.concat(v2.transform.matrix);
v2 = v2._parent;
}
var v9 = new flash.display.BitmapData(v3.xMax - v3.xMin, v3.yMax - v3.yMin, false);
v5.tx -= v3.xMin;
v5.ty -= v3.yMin;
v9.draw(p_clip1, v5, new flash.geom.ColorTransform(1, 1, 1, 1, 255, -255, -255, p_alphaTolerance));
var v4 = p_clip2.transform.matrix;
v2 = p_clip2._parent;
while (v2 != _root) {
v4.concat(v2.transform.matrix);
v2 = v2._parent;
}
v4.tx -= v3.xMin;
v4.ty -= v3.yMin;
v9.draw(p_clip2, v4, new flash.geom.ColorTransform(1, 1, 1, 1, 255, 255, 255, p_alphaTolerance), 'difference');
var v8 = v9.getColorBoundsRect(4294967295.0, 4278255615.0);
if (v8.width == 0) {
return null;
}
v8.x += v3.xMin;
v8.y += v3.yMin;
return v8;
};
ASSetPropFlags(As.colission.prototype, null, 1);
}
#endinitclip
}
frame 2 {
function calcArmourLevel(cat) {
var v2 = Math.ceil(cat / _root.armourPerLevel);
if (v2 >= _root.defNames.length) {
v2 = _root.defNames.length - 1;
}
return v2;
}
Stage.scaleMode = 'showAll';
_quality = 'MEDIUM';
_root.highScoresPath = 'http://www.mofunzone.com/game_scores/damn_birds_2/highscores.shtml';
_root.achievement1 = new Object();
achievement1.id = 'birdinator';
achievement1.canReceived = true;
_root.achievement2 = new Object();
achievement2.id = 'modern_bird_hunter';
achievement2.canReceived = true;
_root.achievement3 = new Object();
achievement3.id = 'future_bird_terminator';
achievement3.canReceived = true;
_root.achievement4 = new Object();
achievement4.id = 'mo_poop_guard_3000';
achievement4.canReceived = true;
_root.achievement5 = new Object();
achievement5.id = 'buy_all_weapons';
achievement5.canReceived = true;
_root.achievement6 = new Object();
achievement6.id = 'brave';
achievement6.canReceived = true;
_root.achievement7 = new Object();
achievement7.id = 'early_bird';
achievement7.canReceived = true;
_root.achievement8 = new Object();
achievement8.id = 'singing_in_the_rain';
achievement8.canReceived = true;
_root.achievement9 = new Object();
achievement9.id = 'let_it_snow';
achievement9.canReceived = true;
_root.achievement10 = new Object();
achievement10.id = 'zero_musketeers';
achievement10.canReceived = true;
_root.achievement11 = new Object();
achievement11.id = 'bird_bbq';
achievement11.canReceived = true;
_root.achievement12 = new Object();
achievement12.id = 'sh1t_fest';
achievement12.canReceived = true;
_root.pasari = ['birdFlamingo', 'birdStork', 'birdDuck', 'birdHawk', 'birdParrot', 'birdBlack', 'birdPingeon', 'birdShallow', 'birdPenguin'];
_root.guns = ['gunMouschete', 'gunShotGun', 'gunMachineGun', 'gunBazooka', 'gunSniper', 'gunFlame', 'gunZapper', 'gunTau', 'gunRay'];
_root.gunsNames = ['Musket', 'Shotgun', 'Machinegun', 'Bazooka', 'Sniper', 'Flamer', 'Zapper', 'Taugun', 'Raygun'];
_root.timpi = ['THE PAST', 'PRESENT DAYS', 'THE FUTURE'];
_root.defNames = ['No Armour', 'Light Armour', 'Steel Shield', 'Pooroctector', 'Shit Shield', 'Mo\'s Poop Guard 3000'];
_root.difBgr = 4;
_root.cycle = 2;
_root.maxLevels = _root.difBgr * _root.cycle * 3;
_root.birdNumber = 0;
_root.factSpeed = 0.05;
_root.factPoo = 0.03;
_root.maxPoo = 500;
_root.secPerLevel = 59;
_root.clockSpeed = 0.05;
_root.minPene = 3;
_root.maxPene = 6;
_root.waitShoot = 150;
_root.armourPerLevel = 10;
_root.reloadTime = 0;
_root.reloadTime2 = 25;
_root.timeWeather = 300;
_root.crrTimeWeather = 0;
_root.weatherPoo = 2;
_root.maxFear = 50;
_root.minPasariLevel1 = 2;
_root.maxPasariLevel1 = 4;
_root.minPasariLastLevel = 6;
_root.maxPasariLastLevel = 8;
_root.minFrecv = 20;
_root.maxFrecv = 10;
_root.minPooFrecv = 5;
_root.goMoney = 0;
_root.killSoundConstMax = 125;
_root.hitSoundConstMax = 125;
_root.coordBirds = [-100, -100, 750, 700];
gunMouschete = new Object();
gunShotGun = new Object();
gunMachineGun = new Object();
gunBazooka = new Object();
gunSniper = new Object();
gunFlame = new Object();
gunZapper = new Object();
gunTau = new Object();
gunRay = new Object();
birdPingeon = new Object();
birdBlack = new Object();
birdShallow = new Object();
birdHawk = new Object();
birdPenguin = new Object();
birdParrot = new Object();
birdDuck = new Object();
birdStork = new Object();
birdFlamingo = new Object();
_root.cleanCost = 2;
_root.armourCost = 200;
gunMouschete.price = 0;
gunShotGun.price = 450;
gunMachineGun.price = 1000;
gunBazooka.price = 1800;
gunSniper.price = 3000;
gunFlame.price = 6000;
gunZapper.price = 9000;
gunTau.price = 15000;
gunRay.price = 25000;
gunMouschete.bulletPrice = 1;
gunShotGun.bulletPrice = 2;
gunMachineGun.bulletPrice = 1;
gunBazooka.bulletPrice = 35;
gunSniper.bulletPrice = 4;
gunFlame.bulletPrice = 4;
gunZapper.bulletPrice = 15;
gunTau.bulletPrice = 10;
gunRay.bulletPrice = 20;
birdPingeon.win = 10;
birdBlack.win = 15;
birdShallow.win = 10;
birdHawk.win = 36;
birdPenguin.win = 78;
birdParrot.win = 133;
birdDuck.win = 424;
birdStork.win = 648;
birdFlamingo.win = 1620;
birdPingeon.maxLife = 10;
birdBlack.maxLife = 15;
birdShallow.maxLife = 10;
birdHawk.maxLife = 35;
birdPenguin.maxLife = 75;
birdParrot.maxLife = 125;
birdDuck.maxLife = 400;
birdStork.maxLife = 600;
birdFlamingo.maxLife = 1500;
birdPingeon.pooPower = 5;
birdBlack.pooPower = 10;
birdShallow.pooPower = 4;
birdHawk.pooPower = 8;
birdPenguin.pooPower = 12;
birdParrot.pooPower = 12;
birdDuck.pooPower = 17;
birdStork.pooPower = 22;
birdFlamingo.pooPower = 27;
gunMouschete.power = 10;
gunShotGun.power = 15;
gunMachineGun.power = 15;
gunBazooka.power = 100;
gunSniper.power = 20;
gunFlame.power = 20;
gunZapper.power = 50;
gunTau.power = 100;
gunRay.power = 150;
gunZapper.reLoadTime = 35;
gunTau.reLoadTime = 10;
gunTau.noEnd = true;
gunMouschete.fireSpeed = 3;
gunMouschete.bulletsLoad = 1;
gunMouschete.loopShoot = false;
gunMouschete.sound = sound_gunMouschete;
gunMouschete.mcFire = 'fire1';
gunShotGun.fireSpeed = 10;
gunShotGun.bulletsLoad = 2;
gunShotGun.loopShoot = false;
gunShotGun.sound = sound_gunShotGun;
gunShotGun.mcFire = 'fire2';
gunMachineGun.fireSpeed = 2;
gunMachineGun.bulletsLoad = 10;
gunMachineGun.loopShoot = true;
gunMachineGun.mcFire = 'fire3';
gunMachineGun.sound = sound_gunMachineGun;
gunBazooka.fireSpeed = 3;
gunBazooka.bulletsLoad = 1;
gunBazooka.loopShoot = false;
gunBazooka.hasBullet = 'fire4';
gunBazooka.hasAnim = 'fire4_bum';
gunBazooka.hasAnimScale = 300;
gunBazooka.splash = true;
gunBazooka.multiple = true;
gunBazooka.sound = sound_gunBazooka;
gunBazooka.soundAnim = sound_gunBazooka_bum;
gunSniper.fireSpeed = 30;
gunSniper.bulletsLoad = 5;
gunSniper.loopShoot = false;
gunSniper.mcFire = 'fire5';
gunSniper.multiple = true;
gunSniper.sound = sound_gunSniper;
gunFlame.fireSpeed = 0;
gunFlame.bulletsLoad = 30;
gunFlame.loopShoot = true;
gunFlame.hasBullet = 'fire7';
gunFlame.multiple = true;
gunFlame.sound = sound_gunFlame;
gunFlame.waitFinishSound = true;
gunFlame.noFeat = true;
gunZapper.fireSpeed = 3;
gunZapper.bulletsLoad = 3;
gunZapper.loopShoot = false;
gunZapper.mcFire = 'fire6';
gunZapper.multiple = true;
gunZapper.sound = sound_gunZapper;
gunZapper.noPene = true;
gunTau.fireSpeed = 2;
gunTau.bulletsLoad = 10;
gunTau.loopShoot = true;
gunTau.mcFire = 'fire8';
gunTau.vol = 255;
gunTau.sound = sound_gunTau;
gunRay.fireSpeed = 2;
gunRay.bulletsLoad = 50;
gunRay.loopShoot = true;
gunRay.mcFire = 'fire9';
gunRay.multiple = true;
gunRay.sound = sound_gunRay;
gunRay.noPene = true;
birdPingeon.avatar = 'birdPingeon';
birdPingeon.coord = _root.coordBirds;
birdPingeon.size = 30;
birdPingeon.hMax = 50;
birdPingeon.hMin = 150;
birdPingeon.canTurn = true;
birdPingeon.rotate = 20;
birdPingeon.pooRand = 20;
birdPingeon.speed = 2;
birdPingeon.maxSpeed = 4;
birdPingeon.ridica = 20;
birdPingeon.chanceOfChanginDirection = 50;
birdPingeon.pene = ['0x666666', '0x999999'];
birdPingeon.peneSize = [90, 110];
birdPingeon.pooSize = 100;
birdBlack.avatar = 'birdBlack';
birdBlack.coord = _root.coordBirds;
birdBlack.peneSize = [100, 120];
birdBlack.speed = 3;
birdBlack.maxSpeed = 4;
birdBlack.size = 14;
birdBlack.hMax = 60;
birdBlack.hMin = 200;
birdBlack.canTurn = true;
birdBlack.ridica = 10;
birdBlack.rotate = 10;
birdBlack.pooRand = 20;
birdBlack.pooSize = 100;
birdShallow.avatar = 'birdShallow';
birdShallow.coord = _root.coordBirds;
birdShallow.speed = 4;
birdShallow.maxSpeed = 5;
birdShallow.size = 10;
birdShallow.hMax = 100;
birdShallow.hMin = 300;
birdShallow.canTurn = false;
birdShallow.useBezier = true;
birdShallow.pooRand = 10;
birdShallow.randomFly = true;
birdShallow.pene = ['0xDFCDB3', '0x333333'];
birdShallow.peneSize = [50, 70];
birdShallow.pooSize = 100;
birdHawk.avatar = 'birdHawk';
birdHawk.coord = _root.coordBirds;
birdHawk.speed = 3;
birdHawk.size = 15;
birdHawk.hMax = 30;
birdHawk.hMin = 200;
birdHawk.canTurn = fa;
se;
birdHawk.ridica = 50;
birdHawk.rotate = 0;
birdHawk.pooRand = 100;
birdHawk.pene = ['0xC49F4D', '0xF5EB92'];
birdHawk.peneSize = [90, 110];
birdHawk.pooSize = 100;
birdPenguin.avatar = 'birdPenguin';
birdPenguin.coord = _root.coordBirds;
birdPenguin.speed = 6;
birdPenguin.speedMax = 10;
birdPenguin.size = 20;
birdPenguin.hMax = 300;
birdPenguin.hMin = -100;
birdPenguin.canTurn = false;
birdPenguin.useBezier = true;
birdPenguin.pooRand = 50;
birdPenguin.randomFly = false;
birdPenguin.rotate = 60;
birdPenguin.keepOrigin = [-100, 400, 200, 400, 800, 400];
birdPenguin.pene = ['0x000000', '0xaaaaaa'];
birdPenguin.peneSize = [90, 120];
birdPenguin.sounds = [sound_penguin1, sound_penguin2];
birdPenguin.pooSize = 120;
birdParrot.avatar = 'birdParrot';
birdParrot.coord = _root.coordBirds;
birdParrot.speed = 4;
birdParrot.size = 10;
birdParrot.hMax = 50;
birdParrot.hMin = 350;
birdParrot.canTurn = true;
birdParrot.ridica = 35;
birdParrot.rotate = 10;
birdParrot.pooRand = 100;
birdParrot.pene = ['0xFF9933', '0x336633', '0x333333'];
birdParrot.peneSize = [110, 130];
birdParrot.pooSize = 130;
birdDuck.avatar = 'birdDuck';
birdDuck.coord = _root.coordBirds;
birdDuck.speed = 3;
birdDuck.size = 25;
birdDuck.hMax = 30;
birdDuck.hMin = 200;
birdDuck.canTurn = fa;
se;
birdDuck.ridica = 50;
birdDuck.pooRand = 100;
birdDuck.rotate = 0;
birdDuck.pene = ['0xCCCCCC', '0x336633', '0x6F5842'];
birdDuck.peneSize = [110, 120];
birdDuck.pooSize = 180;
birdStork.avatar = 'birdStork';
birdStork.coord = _root.coordBirds;
birdStork.speed = 3;
birdStork.size = 35;
birdStork.hMax = 30;
birdStork.hMin = 200;
birdStork.canTurn = false;
birdStork.ridica = 50;
birdStork.pooRand = 100;
birdStork.randomFly = false;
birdStork.pene = ['0xFF6600', '0xCCCCCC', '0x000000'];
birdStork.peneSize = [120, 140];
birdStork.pooSize = 230;
birdFlamingo.avatar = 'birdStork';
birdFlamingo.coord = _root.coordBirds;
birdFlamingo.speed = 3;
birdFlamingo.size = 30;
birdFlamingo.hMax = 30;
birdFlamingo.hMin = 200;
birdFlamingo.canTurn = false;
birdFlamingo.ridica = 50;
birdFlamingo.pooRand = 100;
birdFlamingo.randomFly = false;
birdFlamingo.pene = ['0xFF6699', '0xF8C1B1', '0x000000', '0xff0000'];
birdFlamingo.peneSize = [130, 160];
birdFlamingo.sounds = [sound_flamingo];
birdFlamingo.pooSize = 270;
var clock1 = new As.clock('mcClock');
_root.BirdsLevel1 = [6];
_root.BirdsLevel2 = [6, 6, 6, 5];
_root.BirdsLevel3 = [6, 6, 6, 5, 5, 7];
_root.BirdsLevel4 = [6, 6, 6, 6, 5, 5, 5, 5, 7, 7];
_root.BirdsLevel5 = [6, 6, 6, 5, 5, 5, 7, 7];
_root.BirdsLevel6 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3];
_root.BirdsLevel7 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3];
_root.BirdsLevel8 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 8, 8];
_root.BirdsLevel9 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4];
_root.BirdsLevel10 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4];
_root.BirdsLevel11 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4];
_root.BirdsLevel12 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4, 8, 8];
_root.BirdsLevel13 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4];
_root.BirdsLevel14 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4, 2];
_root.BirdsLevel15 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4, 2, 2];
_root.BirdsLevel16 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4, 2, 2, 2, 8, 8, 8];
_root.BirdsLevel17 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4, 2, 2, 2, 1];
_root.BirdsLevel18 = [6, 5, 7, 3, 2, 4, 1, 1];
_root.BirdsLevel19 = [6, 6, 6, 5, 5, 5, 7, 7, 7, 3, 3, 3, 4, 4, 4, 2, 2, 2, 1, 1, 1, 0];
_root.BirdsLevel20 = [1, 2, 3, 4, 5, 6, 7, 8];
_root.BirdsLevel21 = [0, 1, 2, 3, 4, 5, 6, 7];
_root.BirdsLevel22 = [0, 1, 2, 3, 4, 5, 6, 7];
_root.BirdsLevel23 = [0, 1, 2, 3, 4, 5, 6, 7];
_root.BirdsLevel24 = [0, 1, 2, 3, 4, 5, 6, 7, 8];
_root.sound = new Sound(_root.bgrSound1);
_root.sound.stop();
}
movieClip 563 {
frame 1 {
stop();
}
frame 241 {
gotoAndPlay(2);
}
}
movieClip 565 {
frame 1 {
stop();
}
frame 17 {
stop();
}
}
movieClip 567 {
frame 1 {
stop();
}
}
movieClip 569 {
frame 1 {
stop();
}
}
movieClip 571 {
frame 1 {
stop();
}
}
movieClip 573 {
frame 1 {
stop();
}
}
movieClip 576 {
frame 1 {
stop();
}
}
movieClip 578 {
frame 1 {
stop();
}
}
movieClip 580 {
frame 1 {
stop();
}
}
movieClip 582 {
frame 1 {
stop();
}
}
movieClip 584 {
frame 1 {
stop();
}
}
movieClip 586 {
frame 1 {
stop();
}
}
movieClip 588 {
frame 1 {
stop();
}
}
movieClip 590 {
frame 1 {
stop();
}
}
movieClip 592 {
frame 1 {
stop();
}
}
movieClip 594 {
frame 1 {
stop();
}
}
movieClip 596 {
frame 1 {
stop();
}
}
movieClip 598 {
frame 1 {
stop();
}
}
movieClip 600 {
frame 1 {
stop();
}
}
movieClip 602 {
frame 1 {
stop();
}
}
movieClip 604 {
frame 1 {
stop();
}
}
movieClip 606 {
frame 1 {
stop();
}
}
movieClip 608 {
frame 1 {
stop();
}
}
movieClip 610 {
frame 1 {
stop();
}
}
movieClip 612 {
frame 1 {
stop();
}
}
movieClip 614 {
frame 1 {
stop();
}
}
movieClip 616 {
frame 1 {
stop();
}
frame 311 {
gotoAndPlay(2);
}
}
movieClip 618 {
frame 1 {
stop();
}
frame 80 {
gotoAndPlay(2);
}
}
movieClip 620 {
frame 1 {
stop();
}
}
movieClip 622 {
frame 1 {
stop();
}
}
movieClip 624 {
frame 1 {
stop();
}
}
movieClip 626 {
frame 1 {
stop();
}
}
movieClip 628 {
frame 1 {
stop();
}
}
movieClip 630 {
frame 1 {
stop();
}
}
movieClip 632 {
frame 1 {
stop();
}
}
movieClip 634 {
frame 1 {
stop();
}
}
movieClip 636 {
frame 1 {
stop();
}
}
movieClip 638 {
frame 1 {
stop();
}
}
movieClip 640 {
frame 1 {
stop();
}
}
movieClip 642 {
frame 1 {
stop();
}
}
movieClip 644 {
frame 1 {
stop();
}
}
movieClip 646 {
frame 1 {
stop();
}
}
movieClip 648 {
frame 1 {
stop();
}
}
movieClip 650 {
frame 1 {
stop();
}
}
movieClip 652 {
frame 1 {
stop();
}
}
movieClip 654 {
frame 1 {
stop();
}
}
movieClip 656 {
frame 1 {
stop();
}
}
movieClip 658 {
frame 1 {
stop();
}
}
movieClip 660 {
frame 1 {
stop();
}
}
movieClip 662 {
frame 1 {
stop();
}
}
movieClip 664 {
frame 1 {
stop();
}
}
movieClip 666 {
frame 1 {
stop();
}
}
movieClip 668 {
frame 1 {
stop();
}
}
movieClip 670 {
frame 1 {
stop();
}
}
movieClip 672 {
frame 1 {
stop();
}
}
movieClip 674 {
frame 1 {
stop();
}
}
movieClip 675 {
frame 1 {
stop();
}
}
movieClip 676 {
frame 1 {
stop();
}
}
movieClip 677 {
frame 1 {
stop();
}
}
movieClip 678 {
frame 1 {
stop();
}
}
movieClip 679 {
frame 1 {
stop();
}
}
movieClip 681 {
frame 1 {
stop();
}
}
movieClip 683 {
frame 1 {
stop();
}
}
movieClip 685 {
frame 1 {
stop();
}
}
movieClip 687 {
frame 1 {
stop();
}
}
movieClip 689 {
frame 1 {
stop();
}
}
movieClip 691 {
frame 1 {
stop();
}
}
movieClip 693 {
frame 1 {
stop();
}
}
movieClip 695 {
frame 1 {
stop();
}
}
movieClip 697 {
frame 1 {
stop();
}
}
movieClip 699 {
frame 1 {
stop();
}
}
movieClip 701 {
frame 1 {
stop();
}
}
movieClip 703 {
frame 1 {
stop();
}
}
movieClip 705 {
frame 1 {
stop();
}
}
movieClip 707 {
frame 1 {
stop();
}
}
movieClip 708 {
frame 1 {
stop();
}
}
movieClip 710 {
frame 1 {
stop();
}
}
movieClip 712 {
frame 1 {
stop();
}
}
movieClip 714 {
frame 1 {
stop();
}
}
movieClip 716 {
frame 1 {
stop();
}
}
movieClip 718 {
frame 1 {
stop();
}
}
movieClip 720 {
frame 1 {
stop();
}
}
movieClip 722 {
frame 1 {
stop();
}
}
movieClip 724 {
frame 1 {
stop();
}
}
movieClip 726 {
frame 1 {
stop();
}
}
movieClip 728 {
frame 1 {
stop();
}
}
movieClip 730 {
frame 1 {
stop();
}
}
movieClip 732 {
frame 1 {
stop();
}
}
movieClip 734 {
frame 1 {
stop();
}
}
movieClip 736 {
frame 1 {
stop();
}
}
movieClip 738 {
frame 1 {
stop();
}
}
movieClip 740 {
frame 1 {
stop();
}
}
movieClip 742 {
frame 1 {
stop();
}
}
movieClip 744 {
frame 1 {
stop();
}
}
movieClip 746 {
frame 1 {
stop();
}
}
movieClip 749 {
}
movieClip 751 {
}
movieClip 754 {
}
movieClip 756 {
}
movieClip 758 {
}
// unknown tag 88 length 197
// unknown tag 88 length 143
movieClip 765 {
}
// unknown tag 88 length 82
button 771 {
on (release) {
gotoAndStop('help');
}
}
button 773 {
on (release) {
getURL('http://www.mofunzone.com/online_games/damn_birds.shtml', '_blank');
}
}
button 775 {
on (release) {
getURL(_root.highScoresPath, '_blank');
}
}
frame 3 {
function hideAchievement() {
if (_root.enableAchievements) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).hide_username();
}
}
function getAchievement(obj) {
if (_root.enableAchievements && obj.canReceived) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).success(obj.id);
obj.canReceived = false;
}
}
function doAchievements() {}
function playSound2(mc, vol) {
if (mc._currentframe == 1) {
var v2 = new Sound(mc);
if (vol != undefined) {
v2.setVolume(vol);
}
mc.gotoAndPlay(2);
}
}
function playSound3(mc, vol) {
var v1 = new Sound(mc);
v1.setVolume(vol);
mc.gotoAndPlay(2);
}
stop();
stop();
var s = new Sound();
s.setVolume(100);
_root.pooLevel = 0;
_root.pooNumber = 0;
_root.featNumber = 0;
_root.crrGun = 1;
_root.crrGunObject = '';
_root.loopShot = false;
_root.crrLevel = 1;
_root.crrTime = 0;
_root.crrSeason = 0;
_root.armour = 0;
_root.money = _root.goMoney;
_root.inventory = [1, 0, 0, 0, 0, 0, 0, 0, 0];
_root.nrShooted = 0;
_root.numberOfShots = 0;
_root.birdNumber = 0;
_root.nrBirds = 0;
_root.win = 0;
_root.score = 0;
_root.firstLevel = true;
_root.totalBirds = 0;
_root.pauza = false;
_root.survive = true;
gunMouschete.nrBullets = 150;
gunShotGun.nrBullets = 15;
gunMachineGun.nrBullets = 30;
gunBazooka.nrBullets = 5;
gunSniper.nrBullets = 10;
gunFlame.nrBullets = 50;
gunZapper.nrBullets = 20;
gunTau.nrBullets = 30;
gunRay.nrBullets = 50;
var i = 1;
while (i <= _root.guns.length) {
var gun = eval(_root.guns[i - 1]);
gun.bulletsShooted = 0;
gun.crrReload = 0;
gun.canShot = true;
++i;
}
btnNew.onPress = function () {
_root.gotoAndStop('game');
};
btnHelp.onPress = function () {
_root.gotoAndStop('help');
};
_root.bgrSound1.gotoAndStop(1);
_root.bgrSound2.gotoAndStop(1);
_root.bgrSound3.gotoAndStop(1);
var nrBird1 = _root['sound_bird' + As.utils.rnd(1, 8)];
playSound3(nrBird1, 30);
playSound3(_root.main_flap2, 50);
var crrSecBird1 = 0;
var crrSecBird2 = 0;
_root.onEnterFrame = function () {
if (_root._currentframe == 3) {
++crrSecBird1;
++crrSecBird2;
if (crrSecBird1 >= 100 + As.utils.rnd(-10, 10)) {
crrSecBird1 = 0;
var v2 = _root['sound_bird' + As.utils.rnd(1, 8)];
if (v2._currentframe == 1) {
playSound3(v2, 30);
}
playSound3(v2, 100);
}
if (crrSecBird2 >= 120 + As.utils.rnd(-10, 10)) {
crrSecBird2 = 0;
playSound3(_root.main_flap2, 50);
}
}
};
btnStart.onRelease = function () {
hideAchievement();
_root.gotoAndStop('shop');
};
if (_root.enableHighScore) {
mcLogo._alpha = 50;
}
mcLogo.onRollOver = function () {
if (_root.enableHighScore) {
this._alpha = 100;
}
};
mcLogo.onRollOut = function () {
if (_root.enableHighScore) {
this._alpha = 50;
}
};
mcLogo.onReleaseOutside = mcLogo.onRollOut;
mcLogo.onRelease = mcLogo.onRollOut;
mcLogo.onPress = function () {
if (_root.enableHighScore) {
getURL('http://www.mofunzone.com', '_blank');
} else {
getURL('http://www.mofunzone.com/online_games/damn_birds_2.shtml', '_blank');
}
};
mcAc.onPress = function () {
getURL('http://www.MoFunZone.com', '_blank');
};
}
movieClip 787 {
frame 9 {
gotoAndPlay(1);
}
frame 10 {
stop();
}
frame 11 {
stop();
}
}
movieClip 788 {
frame 1 {
function randRange(min, max) {
var v1 = Math.floor(Math.random() * (max - min + 1)) + min;
return v1;
}
stop();
this.onEnterFrame = function () {
if (randRange(0, 80) == 0) {
delete this.onEnterFrame;
gotoAndPlay(2);
}
};
}
}
movieClip 792 {
}
movieClip 798 {
frame 10 {
gotoAndPlay(1);
}
frame 11 {
stop();
}
frame 12 {
stop();
}
}
movieClip 799 {
frame 1 {
function randRange(min, max) {
var v1 = Math.floor(Math.random() * (max - min + 1)) + min;
return v1;
}
stop();
this.onEnterFrame = function () {
if (randRange(0, 80) == 0) {
delete this.onEnterFrame;
gotoAndPlay(2);
}
};
}
}
frame 13 {
function hideAchievement() {
if (_root.enableAchievements) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).hide_username();
}
}
function getAchievement(obj) {
if (_root.enableAchievements && obj.canReceived) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).success(obj.id);
obj.canReceived = false;
}
}
function doAchievements() {}
function addBirdBySeason() {
var v5 = As.utils.minMaxInterval(1, As.utils.rnd(_root.minPasariLevel1, _root.maxPasariLevel1 - 1), _root.maxLevels, As.utils.rnd(_root.minPasariLastLevel, _root.maxPasariLastLevel), _root.crrLevel);
var v3 = As.utils.minMaxInterval(1, _root.minFrecv, _root.maxLevels, _root.maxFrecv, _root.crrLevel);
if (_root.nrBirds <= v5) {
var v6 = As.utils.rnd(0, v3);
if (v6 == 0) {
++_root.nrBirds;
var v2 = _root['BirdsLevel' + _root.crrLevel];
var v4 = As.utils.rnd(0, v2.length - 1);
addBirdByName(_root.pasari[v2[v4]]);
}
}
}
function onFinishLevel(cum) {
Key.removeListener(keyListener);
_root.finishLevel = cum;
var v2 = ceasuri['ceas' + _root.crrTime];
v2.body.scurgere.gotoAndStop(1);
delete inst.onEnterFrame;
clock1.stopTimer();
_root.gotoAndStop('complete');
}
function onFinishClock() {
timerStopped = true;
}
function refresh() {
doAchievements();
checkPooLevel();
if (!_root.pauza) {
++_root.killSoundConst;
++_root.hitSoundConst;
if (_root.canDoWeather) {
if (_root.pooLevel >= _root._root.maxPoo / 2) {
if (As.utils.rnd(0, 20) == 0) {
weatherInit();
_root.canDoWeather = false;
}
}
}
rotateStatueAfterMouse();
statueSkew();
var v2 = ceasuri['ceas' + _root.crrTime];
var v3 = clock1.sec;
var v4 = Math.floor(As.utils.minMaxInterval(0, v2.body._totalframes, _root.secPerLevel, 1, v3));
}
v2.body.gotoAndStop(v4);
v2.sec.text = v3;
v2.vt.text = clock1.vt;
if (!timerStopped) {
addBirdBySeason();
} else {
if (_root.nrBirds <= 0) {
onFinishLevel();
}
}
if (_root.crrGunObject.canShot) {
} else {
_root.crrGunObject.crrReload += 1;
_root.reloadTime = _root.reloadTime2;
if (_root.crrGunObject.reLoadTime != undefined) {
_root.reloadTime = _root.crrGunObject.reLoadTime;
}
if (_root.crrGunObject.crrReload >= _root.reloadTime) {
_root.crrGunObject.crrReload = 0;
_root.crrGunObject.canShot = true;
txRel._visible = false;
txAmmo._visible = true;
bullet._visible = true;
_root.crrGunObject.bulletsShooted = 0;
txAmmo.text = 'Ammo: ' + _root.crrGunObject.nrBullets;
doMaskaBullets(true);
}
}
}
function doShotsBullets() {
if (_root.crrGunObject.bulletsShooted >= _root.crrGunObject.bulletsLoad) {
_root.crrGunObject.canShot = false;
_root.crrGunObject.crrReload = 0;
txRel._visible = true;
playSound3(sound_reload, 50);
txAmmo._visible = false;
bullet._visible = false;
} else {
txAmmo.text = 'Ammo: ' + _root.crrGunObject.nrBullets;
}
}
function doMaskaBullets(cum) {
var v2 = _root.crrGunObject.bulletsShooted;
if (cum) {
if (_root.crrGunObject.nrBullets <= _root.crrGunObject.bulletsLoad) {
_root.crrGunObject.bulletsShooted = _root.crrGunObject.bulletsLoad - _root.crrGunObject.nrBullets;
v2 = _root.crrGunObject.bulletsShooted;
}
}
if (_root.crrGunObject.nrBullets == 0) {
v2 = _root.crrGunObject.bulletsLoad;
}
var v3 = As.utils.minMaxInterval(0, bullet.maxMaska._height, _root.crrGunObject.bulletsLoad, 0, v2);
bullet.maska._height = v3;
}
function weaponShot() {
if (_root.crrGunObject.canShot) {
if (_root.crrGunObject.nrBullets == 0) {
playSound3(sound_empty, 200);
txAmmo.text = 'Ammo: ' + _root.crrGunObject.nrBullets;
}
if (_root.crrGunObject.nrBullets > 0) {
_root.survive = false;
if (_root.crrGun == 6) {
getAchievement(_root.achievement11);
}
_root.tinta.gotoAndPlay(2);
++_root.numberOfShots;
if (_root.crrGunObject.waitFinishSound) {
if (_root.crrGunObject.sound._currentframe <= 2 || _root.crrGunObject.sound._currentframe >= _root.crrGunObject.sound._totalframes - 10) {
if (_root.crrGunObject.sound.vol == undefined) {
playSound3(_root.crrGunObject.sound, 60);
} else {
playSound3(_root.crrGunObject.sound, _root.crrGunObject.sound.vol);
}
}
} else {
playSound3(_root.crrGunObject.sound, 60);
}
--_root.crrGunObject.nrBullets;
if (_root.crrGun == 1 && _root.crrGunObject.nrBullets == 0) {
getAchievement(_root.achievement10);
}
++_root.crrGunObject.bulletsShooted;
doMaskaBullets();
doShotsBullets();
if (_root.crrGunObject.loopShoot) {
_root.loopShot = true;
hit.crrFireSpeed = -1;
hit.onEnterFrame = function () {
if (!_root.pauza) {
if (_root.crrGunObject.fireSpeed != 0) {
++hit.crrFireSpeed;
if (this.crrFireSpeed >= _root.crrGunObject.fireSpeed) {
weaponShot();
hit.crrFireSpeed = 0;
}
} else {
weaponShot();
}
}
};
}
pt0 = {'x': statues._x, 'y': statues._y};
ptH = {'x': p0._x + 10, 'y': p0._y};
ptW = {'x': p0._x + 50, 'y': p0._y};
RifleAngle = As.utils.radiani(As.utils.panta3(As.utils.point_vector(statues.gunTrg), As.utils.vector(_xmouse, _ymouse, 0), 90));
VVSpeed += Math.cos(RifleAngle) * 3;
HVSpeed += Math.sin(RifleAngle) * 8;
var v4 = statues.statue.body.guns.gun.guide;
var v3 = '';
if (statues.nrGloante == undefined) {
statues.nrGloante = 0;
}
if (statues.nrGloante >= 1000) {
statues.nrGloante = 0;
}
++statues.nrGloante;
if (_root.crrGunObject.hasBullet.length != 0) {
v3 = shots.createEmptyMovieClip('fire' + statues.nrGloante, shots.getNextHighestDepth());
var v5 = v3.attachMovie(_root.crrGunObject.hasBullet, 'foc', v3.getNextHighestDepth());
v3._x = statues.statue._x + statues.statue.body._x + statues.statue.body.guns._x + statues.statue.body.guns.gun._x + statues.statue.body.guns._x + statues.statue.body.guns.gun.guide._x;
v3._y = statues.statue._y + statues.statue.body._y + statues.statue.body.guns._y + statues.statue.body.guns.gun._y + statues.statue.body.guns._x + statues.statue.body.guns.gun.guide._y;
v3._rotation = v4._rotation;
v3.hasAnim = _root.crrGunObject.hasAnim;
v3.hasAnimScale = _root.crrGunObject.hasAnimScale;
}
if (_root.crrGunObject.hasBullet == undefined) {
v3 = v4.attachMovie(_root.crrGunObject.mcFire, 'fire' + statues.nrGloante, v4.getNextHighestDepth());
}
v3.guide._alpha = 0;
if (debugMode2) {
v3.guide._alpha = 100;
}
v3.arma = _root.crrGunObject;
checkWeaponBirdColission(v3, true);
} else {
soundNoAmmo.gotoAndPlay(2);
}
}
}
function startLevel() {
_root.crrGunObject.canShot = true;
var crrCeas = ceasuri['ceas' + _root.crrTime];
clock1.startTimer(_root.secPerLevel + 1, -1, _root.clockSpeed, onFinishClock);
ceasuri._visible = true;
crrCeas.body.scurgere.play();
var maxFrec = 150 - _root.crrLevel * 4;
var aaa = As.utils.rnd(50, maxFrec);
_root.bgrSoundX = eval('bgrSound' + _root.crrTime + '_1');
_root.soundX = new Sound(_root.bgrSoundX);
_root.bgrSoundX.gotoAndStop(1);
if (_root.bgrSound._currentframe == 2) {
_root.bgrSound.gotoAndPlay(52);
}
this.onEnterFrame = function () {
if (_root.bgrSound._currentframe >= _root.bgrSound._totalframes - 20 && _root.bgrSoundX._currentframe == 1) {
_root.bgrSoundX.gotoAndPlay(2);
_root.bgrSoundX.vol = _root.bgrSound.vol;
_root.soundX.setVolume(_root.bgrSoundX.vol);
}
if (_root.bgrSound._currentframe == 10) {
_root.soundX.setVolume(0);
_root.bgrSoundX.gotoAndStop(1);
}
refresh();
++aaa;
if (aaa >= maxFrec + As.utils.rnd(-20, 20)) {
var nrp = As.utils.rnd(1, 8);
playSound2(eval('sound_bird' + nrp), As.utils.rnd(60, 90));
aaa = 0;
}
if (As.utils.rnd(0, maxFrec / 1.5) == 0) {
var nrp = As.utils.rnd(1, 8);
var minS = 15;
var maxS = 25;
if (_root.crrTime == 2) {
minS = 60;
maxS = 80;
}
if (_root.crrTime == 3) {
minS = 10;
maxS = 30;
}
playSound2(eval('sound_' + _root.crrTime + '_' + nrp), As.utils.rnd(minS, maxS));
}
if (As.utils.rnd(0, maxFrec / 10) == 0) {
var nrp = As.utils.rnd(9, 10);
playSound2(eval('sound_1_' + nrp), As.utils.rnd(60, 80));
}
};
}
function changeLevel(lvl) {
mcPausa._visible = false;
_root.pauza = false;
_root.killSoundConst = 0;
_root.hitSoundConst = 0;
_root.canDoWeather = false;
var nr = As.utils.rnd(0, 2);
if (nr == 0) {
_root.canDoWeather = true;
}
stopSounds();
delete _root.onEnterFrame;
_root.bgrSound1.gotoAndStop(1);
_root.bgrSound2.gotoAndStop(1);
_root.bgrSound3.gotoAndStop(1);
_root.sound_poo.gotoAndStop(1);
_root.canShot = false;
_root.creReload = 0;
_root.win = 0;
_root.nrShooted = 0;
_root.numberOfShots = 0;
_root.nrBirds = 0;
_root.birdNumber = 0;
_root.crrLevel = lvl;
_root.crrTime = Math.floor((_root.crrLevel - 1) / difBgr * cycle) + 1;
_root.crrSeason = Math.floor((_root.crrLevel - 1) % difBgr) + 1;
if (_root.crrTime == 2) {
getAchievement(_root.achievement2);
}
if (_root.crrTime == 3) {
getAchievement(_root.achievement3);
}
sliderGlow.gotoAndStop(1);
_root.sound.stop();
_root.sound2.stop();
_root.bgrSound = eval('bgrSound' + _root.crrTime);
_root.sound = new Sound(_root.bgrSound);
_root.bgrSound.gotoAndPlay(2);
_root.bgrSound.vol = 150;
_root.sound.setVolume(_root.bgrSound.vol);
Mouse.hide();
_root.crrTimeWeather = 0;
var i = 1;
while (i <= _root.pasari.length) {
var mc = birds[_root.pasari[i - 1]];
mc._visible = false;
mc.gotoAndStop(1);
var mc2 = birds2[_root.pasari[i - 1] + '_dye'];
mc2._visible = false;
mc2.gotoAndStop(1);
++i;
}
var i = 1;
while (i <= _root.guns.length) {
var cg = _root.guns[_root.crrGun - 1];
(eval(cg)).bulletsShooted = 0;
(eval(cg)).canShot = false;
(eval(cg)).crrReload = 0;
++i;
}
delete this.onEnterFrame;
txDef.text = 'Defense: ' + _root.armour;
defIcon.gotoAndStop(calcArmourLevel(_root.armour) + 1);
statues.rot = 180;
rain.reset();
snow.reset();
timerStopped = false;
txRel._visible = false;
txAmmo._visible = true;
bullet._visible = true;
ceasuri.gotoAndStop(_root.crrTime);
var crrCeas = ceasuri['ceas' + _root.crrTime];
ceasuri._visible = false;
crrCeas.body.scurgere.gotoAndStop(1);
crrCeas.body.gotoAndStop(1);
checkPooLevel();
mcDefense.gotoAndStop(1);
_root.pooNumber = 0;
_root.featNumber = 0;
tinta._visible = false;
var crrBgr = crrSeason + (_root.crrTime - 1) * difBgr;
mcStativ.gotoAndStop(_root.crrTime);
_root.mcStativ.txScore.text = _root.score;
var i = 1;
while (i <= 3) {
ceasuri['ceas' + i].body.gotoAndStop(1);
ceasuri['ceas' + i].body.scurgere.gotoAndStop(1);
++i;
}
bgr.gotoAndStop(crrBgr);
statues.gotoAndStop(_root.crrTime);
statues.statue._x = statues.trg._x;
statues.statue._y = statues.trg._y;
statues.statue.gotoAndStop(50);
if (statues.pos == undefined) {
statues.pos = 1;
}
statues.statue.body.gotoAndStop(statues.pos);
statues.statue.body.guns.gun.gotoAndStop(1);
changeGun('');
mcBegin.levelNumber.text1.text = _root.crrLevel;
mcBegin.levelNumber.text2.text = _root.timpi[_root.crrTime - 1];
mcBegin.gotoAndPlay(1);
mcBegin.pasare.gotoAndPlay(1);
mcBegin.onEnterFrame = function () {
bgr._alpha += 10;
if (bgr._alpha >= 100) {
bgr._alpha = 100;
}
if (this._currentframe == this._totalframes) {
delete this.onEnterFrame;
this.gotoAndStop(1);
startLevel();
}
};
}
function changeGun(care, cum) {
if (care != '') {
_root.crrGun = care;
}
removeMovieClip(statues.statue.body.guns.gun);
statues.statue.body.guns.attachMovie(_root.guns[_root.crrGun - 1], 'gun', statues.statue.body.guns.getNextHighestDepth());
statues.statue.body.guns.gun.gotoAndStop(statues.pos);
statues.statue.body.guns.gun.guide.desen._visible = false;
if (debugMode) {
statues.statue.body.guns.gun.guide.desen._visible = true;
}
_root.crrGunObject = eval(_root.guns[_root.crrGun - 1]);
mcAvatar.gotoAndStop(_root.crrGun);
txAmmo.text = 'Ammo: ' + _root.crrGunObject.nrBullets;
bullet.gotoAndStop(_root.crrGun);
doMaskaBullets(true);
if (cum) {
if (_root.crrGunObject.crrReload == 0) {
_root.crrGunObject.canShot = true;
_root.crrGunObject.crrReload = 0;
txRel._visible = false;
txAmmo._visible = true;
bullet._visible = true;
_root.crrGunObject.bulletsShooted = 0;
txAmmo.text = 'Ammo: ' + _root.crrGunObject.nrBullets;
doMaskaBullets(true);
} else {
_root.crrGunObject.canShot = false;
txRel._visible = true;
txAmmo._visible = false;
bullet._visible = false;
}
}
}
function addBirdByName(nume) {
var obj = eval(nume);
pasare[_root.nrBirds] = new As.bird(birds, nume, _root.coordBirds, obj.size, obj.speed, obj.hMin, obj.hMax, obj.canTurn, obj.useBezier, obj.rotate, obj.ridica, obj.poo, obj.pooRand, obj.randomFly, obj.keepOrigin, obj.maxSpeed, obj.chanceOfChanginDirection, obj.yCoef1, obj.yCoef2, obj.turnChance, obj.maxLife, obj.pooPower, obj.win, obj.pooSize, obj.sounds);
}
function rotateStatueAfterMouse() {
var v1 = As.utils.vector(_xmouse, _ymouse, 0);
var v2 = As.utils.point_vector(statues.gunTrg);
statues.unghi = As.utils.panta2(v2, v1);
if (statues.unghi > 350) {
statues.unghi = 0;
}
statues.pos = Math.round(As.utils.zecimale(statues.unghi / 11.25, 0) + 1);
statues.statue.body.guns.gun.gotoAndStop(statues.pos);
statues.statue.body.gotoAndStop(statues.pos);
statues.rot = statues.statue.body.guns.gun.guide._rotation;
tinta._visible = true;
As.utils.vector_point(v1, tinta);
var v3 = As.utils.gaseste_vector_lungime(v2, v1, 1000);
statues.rot = statues.statue.body.guns.gun.guide._rotation;
}
function colBirds(mcCol, mc) {
unghi = 180 - statues.unghi;
mc.bulletPower = [unghi, mcCol.arma.power, mcCol.arma.noFeat];
if (mcCol.hasAnim != undefined) {
playSound(_root.crrGunObject.soundAnim);
++statues.nrGloante;
var str = mcCol.hasAnim + statues.nrGloante;
var mcB = mcCol._parent.attachMovie(mcCol.hasAnim, str, mcCol._parent.getNextHighestDepth());
if (mcCol.hasAnimScale != undefined) {
mcB._xscale = mcCol.hasAnimScale;
mcB._yscale = mcCol.hasAnimScale;
}
mcB._x = mc._x;
mcB._y = mc._y - 25;
_root.crrGunObject.soundAnim.can = true;
}
var cate = As.utils.rnd(_root.minPene, _root.maxPene);
var poz1 = 20;
var poz2 = 30;
if (_root.featNumber >= _root.maxFear + 10) {
_root.featNumber = 0;
}
if (_root.featNumber >= _root.maxFear) {
cate = As.utils.rnd(1, 2);
}
if (_root.crrGunObject.noFeat) {
cate = 0;
mc.tint = As.utils.minMaxInterval(0, 0, mc.maxLife / 2, 1, mc.life);
if (mc.tint >= 1) {
mc.tint = 1;
}
if (mc.tint <= 0) {
mc.tint = 0;
}
setTint(mc, mc.tint);
}
if (mc.catePene == undefined) {
mc.catePene = 0;
}
if (mc.catePene > 2) {
cate = 1;
}
mc.catePene += cate;
var i = 1;
while (i <= cate) {
++_root.featNumber;
var mc2 = _root.fea.attachMovie('fearthure', 'fearthure' + _root.featNumber, _root.fea.getNextHighestDepth());
mc2._alpha = As.utils.rnd(50, 70);
var obj = eval(mc.avatar);
var nrPana = As.utils.rnd(0, obj.pene.length - 1);
var size = As.utils.rnd(obj.peneSize[0], obj.peneSize[1]);
var cul = Number(obj.pene[nrPana]);
(new Color(mc2)).setRGB(cul);
mc2._xscale = size;
mc2._yscale = size;
var semnX = As.utils.semn(-1 + As.utils.rnd(0, 1));
var semnY = As.utils.semn(-1 + As.utils.rnd(0, 1));
semnY = -1;
if (semnY < 0) {
semnY = -As.utils.rnd(1, 3);
}
mc2.fPosVec = As.utils.vector(mc._x - semnX * As.utils.rnd(poz1, poz2), mc._y + semnY * As.utils.rnd(poz1, poz2), 0);
mc2.cPosVec = As.utils.point_vector(mc);
mc2.distMare = As.utils.distanta(mc2.cPosVec, mc2.fPosVec);
As.utils.vector_point(mc2.cPosVec, mc2);
mc2.fPosSpeed = 0;
mc2.fPos = false;
mc2.maxX = 50;
mc2.cateMaxX = As.utils.rnd(0, mc2.maxX);
mc2.semnMaxX = As.utils.rnd(-1, 1);
mc2.crrMaxX = 0;
mc2._rotation = As.utils.rnd(-45, 45);
mc2.RsemnMaxX = mc2.semnMaxX;
this.rRot = 1;
mc2.onEnterFrame = function () {
if (this.fPos) {
this._y += 4;
this.crrMaxX += 1;
if (this.crrMaxX == this.cateMaxX) {
this.cateMaxX = As.utils.rnd(0, this.maxX);
this.crrMaxX = 0;
this.semnMaxX = As.utils.rnd(-1, 1);
this.rRot = As.utils.rnd(1, 3);
}
this._x += this.semnMaxX * 1;
this._rotation += -this.RsemnMaxX * this.rRot;
} else {
this.fPosSpeed += 20;
this.v1 = As.utils.gaseste_vector_lungime(this.cPosVec, this.fPosVec, this.fPosSpeed);
this.d1 = As.utils.distanta(this.cPosVec, this.v1);
As.utils.vector_point(this.v1, this);
if (this.d1 >= this.distMare) {
this.fPos = true;
}
}
if (this._y >= 500) {
delete this.onEnterFrame;
removeMovieClip(this);
}
};
++i;
}
}
function checkWeaponBirdColission(mcCol) {
mcCol.onEnterFrame = function () {
var v7 = [];
mcCol.gotoAndStop(mcCol._currentframe + 1);
var v14 = false;
for (br in birds) {
var v3 = birds[br];
if (v3._name.indexOf('bird') > -1) {
if (v3._visible) {
if (v3.life > 0) {
var v16 = mcCol.hasAnim + statues.nrGloante;
var v15 = mcCol._parent[v16];
if (v15 != undefined && mcCol.arma.splash) {
mcCol._visible = false;
v15._xscale = 500;
v15._yscale = 500;
var v5 = null;
if (!v3.hitOnce) {
v5 = As.colission.checkForCollision(v3, v15);
}
if (v5 != null) {
v3.hitOnce = true;
unghi = As.utils.panta(As.utils.vector(v5.x, v5.y, 0), As.utils.point_vector(v15));
v3.bulletPower = [unghi, mcCol.arma.power, mcCol.arma.noFeat];
}
} else {}
var v4 = null;
if (mcCol._visible) {
v4 = As.colission.checkForCollision(v3, mcCol);
if (v4 == null) {
if (mcCol._currentframe == 1) {
v4 = As.colission.checkForCollision(v3, _root.tinta);
}
}
if (v4) {
if (mcCol.arma.splash) {
mcCol._visible = false;
}
}
}
if (mcCol.arma.multiple) {
if (v4 != null) {
v14 = true;
colBirds(mcCol, v3);
}
} else {
if (v4 != null) {
var v6 = v7.length;
v7[v6] = new Object();
v7[v6].mc = v3;
var v12 = _root.statues.statue;
var v11 = _root.statues.statue.body;
var v10 = _root.statues.statue.body.guns;
var v9 = _root.statues.statue.body.guns.gun;
var v8 = _root.statues.statue.body.guns.gun.guide;
var v13 = vector(v12._x + v11._x + v10._x + v9._x + v8._x, v12._y + v11._y + v10._y + v9._y + v8._y, 0);
v7[v6].dist = As.utils.distanta(point_vector(v3), v13);
}
}
if (v15 != undefined) {
if (v15._currentframe >= v15._totalframes - 2) {
removeMovieClip(this);
break;
}
}
}
}
}
}
if (v7.length != 0) {
buf2 = v7.sortOn('dist', 16);
colBirds(mcCol, buf2[0].mc);
v7 = [];
removeMovieClip(mcCol);
}
if (mcCol.hasAnim != undefined) {
v16 = mcCol.hasAnim + statues.nrGloante;
v15 = mcCol._parent[v16];
if (v15 != undefined) {
mcCol.canVerify = true;
} else {
if (mcCol.canVerify) {
removeMovieClip(mcCol);
}
}
if (!v14) {
}
}
};
}
function statueSkew() {
var v3 = 1.5;
var v2 = 0.2;
var v1 = 0.1;
if (VVSpeed != 0) {
VPos += VVSpeed;
VSCo = VPos * v3;
VVSpeed -= VSCo;
VVSpeed *= v2;
if (Math.abs(VPos) < v1 and Math.abs(VVSpeed) < v1) {
VVSpeed = 0;
VVPos = 0;
}
statues.statue._yscale = 100 - VPos / 1;
statues.statue._xscale = 100 + VPos / 1;
}
if (HVSpeed != 0) {
HPos += HVSpeed;
HSCo = HPos * v3;
HVSpeed -= HSCo;
HVSpeed *= v2;
if (Math.abs(HPos) < v1 and Math.abs(HVSpeed) < v1) {
HVSpeed = 0;
HVPos = 0;
}
statues.statue.gotoAndStop(50 - Math.round(HPos));
}
}
function checkPooLevel() {
var v2 = As.utils.minMaxInterval(0, 0, _root.maxPoo, sliderClean.maxBara._width, _root.pooLevel);
sliderClean.maska._width = v2;
if (_root.pooLevel >= _root.maxPoo) {
onFinishLevel(true);
}
}
function stopWeather(mc) {
var spPloaie2 = 2;
mc.onEnterFrame = function () {
mc.elements._alpha -= spPloaie;
this._alpha -= spPloaie2;
if (mc.elements._alpha <= 0) {
mc.elements._alpha = 0;
}
if (this._alpha <= 0) {
this._alpha = 0;
delete this.onEnterFrame;
}
};
}
function doWeather() {
var mc = ploaie;
var crr = _root.crrLevel % 4;
if (crr == 0) {
mc = snow;
}
var spPloaie = 0.5;
mc._alpha = 100;
mc.gotoAndPlay(2);
mc.elements._alpha = 0;
_root.crrTimeWeather = 0;
sliderGlow.play();
mc.sound = eval(mc._name + '_sound');
mc.snd = new Sound(mc.sound);
mc.sndVol = 0;
mc.snd.setVolume(mc.sndVol);
mc.onEnterFrame = function () {
if (_root.crrTimeWeather >= 3) {
if (_root.crrTimeWeather == 3) {
mc.sound.gotoAndPlay(2);
}
if (_root.crrTimeWeather >= _root.timeWeather - 40) {
this.sndVol -= 2.2;
} else {
this.sndVol += 0.5;
}
}
if (this.sndVol >= 80) {
this.sndVol = 80;
}
if (this.sndVol <= 0) {
this.sndVol = 0;
}
this.snd.setVolume(this.sndVol);
mc.elements._alpha += spPloaie;
if (mc.elements._alpha >= 100) {
mc.elements._alpha = 100;
}
if (mc.elements._alpha >= 30) {
_root.pooLevel -= _root.weatherPoo;
}
if (_root.pooLevel <= 0) {
_root.pooLevel = 0;
}
_root.crrTimeWeather += 1;
if (_root.crrTimeWeather >= _root.timeWeather) {
sliderGlow.gotoAndStop(1);
delete mc.onEnterFrame;
stopWeather(mc);
}
};
}
function weatherInit() {
var v3 = ploaie;
var v4 = _root.crrLevel % 4;
if (v4 == 0) {
v3 = snow;
}
if (v4 != 0) {
getAchievement(_root.achievement8);
} else {
getAchievement(_root.achievement9);
}
var v5 = 1.75;
v3._alpha = 100;
v3.gotoAndPlay(2);
v3.elements._alpha = 0;
_root.crrTimeWeather = 0;
var a = 0;
if (v3 == ploaie) {
playSound(thunder);
mcThunder.gotoAndPlay(2);
mcThunder.onEnterFrame = function () {
if (!_root.pauza) {
++a;
if (this._currentframe == 1) {
delete this.onEnterFrame;
}
if (a > 2) {
a = -1000;
doWeather();
}
}
};
} else {
doWeather();
}
}
function setTint(mc) {
var v3 = new flash.geom.Transform(mc);
var v1 = v3.colorTransform;
v1.redMultiplier = mc.tint;
v1.greenMultiplier = mc.tint;
v1.blueMultiplier = mc.tint;
v3.colorTransform = v1;
}
function searchWeapon(nr) {
var ret = -1;
var cauta = nr;
var i = 1;
while (i <= _root.inventory.length) {
if (i > cauta) {
if (_root.inventory[i - 1] == 1) {
var gn = eval(_root.guns[i - 1]);
if (gn.nrBullets != 0) {
ret = i;
break;
}
}
}
++i;
}
if (ret == -1) {
var i = 1;
while (i <= _root.inventory.length) {
if (_root.inventory[i - 1] == 1) {
var gn = eval(_root.guns[i - 1]);
if (gn.nrBullets != 0) {
ret = i;
break;
}
}
++i;
}
}
return ret;
}
function nextGun() {
var v2 = searchWeapon(_root.crrGun);
if (v2 != -1) {
changeGun(v2, true);
}
}
function playSound(mc) {
var v1 = new Sound(mc);
v1.setVolume(40);
mc.gotoAndPlay(2);
}
function playSound3(mc, vol) {
var v1 = new Sound(mc);
v1.setVolume(vol);
mc.gotoAndPlay(2);
}
function playSound2(mc, vol) {
if (mc._currentframe == 1) {
var v2 = new Sound(mc);
if (vol != undefined) {
v2.setVolume(vol);
}
mc.gotoAndPlay(2);
}
}
function stopSound(mc) {
var v1 = new Sound(mc);
v1.stop();
mc.gotoAndStop(1);
}
function stopSounds() {
var v2 = 1;
while (v2 <= 10) {
stopSound(_root['sound_1_' + v2]);
stopSound(_root['sound_2_' + v2]);
stopSound(_root['sound_3_' + v2]);
stopSound(_root['bgrSound' + v2]);
stopSound(_root['sound_bird' + v2]);
stopSound(_root['sound_kill1' + v2]);
stopSound(_root['sound_kill2' + v2]);
stopSound(_root['sound_kill3' + v2]);
stopSound(_root['sound_hit1' + v2]);
stopSound(_root['sound_hit2' + v2]);
stopSound(_root['sound_hit3' + v2]);
++v2;
}
stopSound(_root.main_bird1);
stopSound(_root.main_bird2);
stopSound(_root.main_flap1);
stopSound(_root.main_flap2);
stopSound(_root.ploaie_sound);
stopSound(_root.thunder);
stopSound(_root.snow_sound);
}
function setTint(mc) {
var v3 = new flash.geom.Transform(mc);
var v1 = v3.colorTransform;
v1.redMultiplier = mc.tint;
v1.greenMultiplier = mc.tint;
v1.blueMultiplier = mc.tint;
v3.colorTransform = v1;
}
function doPause() {
mcPausa._visible = true;
refresh();
Mouse.show();
}
stop();
stop();
this.tabEnabled = false;
this._focusrect = false;
debugMode = false;
debugMode2 = false;
mcClock._visible = false;
var inst = this;
var timerStopped = false;
var VPos = 0;
var HPos = 0;
var VVSpeed = 0;
var HVSpeed = 0;
hit.onReleaseOutside = function () {
_root.loopShot = false;
delete hit.onEnterFrame;
};
hit.onRelease = hit.onReleaseOutside;
hit.onPress = function () {
if (!_root.pauza) {
weaponShot();
}
};
btnNext.onPress = function () {
++_root.crrLevel;
if (_root.crrLevel > _root.maxLevels) {
_root.crrLevel = 1;
}
_root.gotoAndStop('lastframe');
_root.gotoAndStop('game');
};
btnPrevGun.onRollOver = function () {
Mouse.show();
};
btnNextGun.onRollOver = btnPrevGun.onRollOver;
btnWeather.onRollOver = btnPrevGun.onRollOver;
btnPrev.onRollOver = btnPrevGun.onRollOver;
btnNext.onRollOver = btnPrevGun.onRollOver;
btnWeather.onRollOut = function () {
Mouse.hide();
};
btnPrev.onRollOut = btnWeather.onRollOut;
btnNext.onRollOut = btnWeather.onRollOut;
btnPrev.onPress = function () {
--_root.crrLevel;
if (_root.crrLevel <= 0) {
_root.crrLevel = _root.maxLevels;
}
_root.gotoAndStop('lastframe');
_root.gotoAndStop('game');
};
btnNextGun.onPress = function () {
if (_root.crrGun >= _root.guns.length) {
_root.crrGun = 0;
}
changeGun(++_root.crrGun, true);
};
btnPrevGun.onPress = function () {
if (_root.crrGun <= 1) {
_root.crrGun = _root.guns.length + 1;
}
changeGun(--_root.crrGun, true);
};
hit.useHandCursor = false;
changeLevel(_root.crrLevel);
var keyListener = new Object();
keyListener.onKeyDown = function () {
var v2 = Key.getCode() - 48;
if (v2 >= 1 and v2 <= 9) {
if (_root.inventory[v2 - 1] == 1) {
_root.deb.text = _root.crrGun;
changeGun(v2, true);
}
}
if (v2 == 34) {
if (_root.crrGunObject.nrBullets != 0) {
_root.crrGunObject.bulletsShooted = _root.crrGunObject.bulletsLoad;
doShotsBullets();
}
}
if (v2 == -39) {
nextGun();
}
if (v2 == 32) {
_root.pauza = true;
doPause();
}
};
Key.addListener(keyListener);
btnLow.onRollOver = function () {
Mouse.show();
_root.tinta._visible = false;
};
btnHigh.onRollOver = btnLow.onRollOver;
btnLow.onReleaseOutside = function () {
Mouse.hide();
_root.tinta._visible = true;
};
btnHigh.onReleaseOutside = btnLow.onReleaseOutside;
btnLow.onRollOut = btnLow.onReleaseOutside;
btnHigh.onRollOut = btnLow.onReleaseOutside;
btnHigh.onPress = function () {
_quality = 'MEDIUM';
};
btnLow.onPress = function () {
_quality = 'LOW';
};
mcPausa.bgr.onRollOver = function () {};
mcPausa.btnResume.onRelease = function () {
_root.pauza = false;
mcPausa._visible = false;
};
mcPausa.btnEnd.onRelease = function () {
_root.finishLevel = true;
_root.gotoAndStop('complete');
};
}
movieClip 804 {
}
movieClip 806 {
}
movieClip 809 {
}
movieClip 815 {
}
movieClip 825 {
}
movieClip 828 {
}
movieClip 830 {
}
movieClip 832 {
}
movieClip 835 {
}
movieClip 837 {
}
movieClip 838 {
}
movieClip 840 {
}
movieClip 842 {
}
movieClip 845 {
}
movieClip 847 {
}
movieClip 849 {
}
movieClip 851 {
}
movieClip 854 {
}
movieClip 858 {
}
movieClip 861 {
}
movieClip 862 {
}
movieClip 864 {
}
movieClip 866 {
}
movieClip 868 {
}
movieClip 871 {
}
movieClip 874 {
}
movieClip 875 {
}
movieClip 877 {
}
movieClip 879 {
}
movieClip 881 {
}
movieClip 884 {
}
movieClip 887 {
}
movieClip 891 {
}
movieClip 893 {
}
movieClip 895 {
}
movieClip 897 {
}
movieClip 898 {
}
movieClip 900 {
}
movieClip 901 {
}
movieClip 904 {
}
movieClip 905 {
}
movieClip 907 {
}
movieClip 909 {
}
movieClip 911 {
}
movieClip 914 {
}
movieClip 918 {
}
movieClip 922 {
}
movieClip 924 {
}
movieClip 926 {
}
movieClip 929 {
}
movieClip 935 {
}
movieClip 937 {
}
movieClip 939 {
}
movieClip 941 {
}
movieClip 942 {
}
movieClip 944 {
}
movieClip 946 {
}
movieClip 948 {
}
movieClip 951 {
}
movieClip 953 {
}
movieClip 955 {
}
movieClip 957 {
}
movieClip 959 {
}
movieClip 961 {
}
movieClip 963 {
}
movieClip 965 {
}
movieClip 967 {
}
movieClip 969 {
}
movieClip 971 {
}
movieClip 973 {
}
movieClip 975 {
}
movieClip 976 {
}
movieClip 979 {
}
movieClip 981 {
}
movieClip 983 {
}
movieClip 985 {
}
movieClip 987 {
}
movieClip 1000 {
}
movieClip 1003 {
}
movieClip 1004 {
}
movieClip 1006 {
}
movieClip 1008 {
}
movieClip 1011 {
}
movieClip 1013 {
}
movieClip 1015 {
}
movieClip 1017 {
}
movieClip 1020 {
}
movieClip 1023 {
}
movieClip 1025 {
}
movieClip 1027 {
}
movieClip 1028 {
}
movieClip 1030 {
}
movieClip 1033 {
}
movieClip 1036 {
}
movieClip 1038 {
}
movieClip 1041 {
}
movieClip 1042 {
}
movieClip 1043 {
}
movieClip 1045 {
}
movieClip 1047 {
}
movieClip 1048 {
}
movieClip 1049 {
}
movieClip 1050 {
}
movieClip 1051 {
}
movieClip 1053 {
}
movieClip 1055 {
}
movieClip 1057 {
}
movieClip 1060 {
}
movieClip 1064 {
}
movieClip 1066 {
}
movieClip 1069 {
}
movieClip 1071 {
}
movieClip 1072 {
}
movieClip 1075 {
}
movieClip 1078 {
}
movieClip 1082 {
}
movieClip 1085 {
}
movieClip 1087 {
}
movieClip 1089 {
}
movieClip 1091 {
}
movieClip 1093 {
}
movieClip 1095 {
}
movieClip 1097 {
}
movieClip 1099 {
}
movieClip 1101 {
}
movieClip 1103 {
}
movieClip 1105 {
}
movieClip 1107 {
}
movieClip 1109 {
}
movieClip 1110 {
}
movieClip 1111 {
}
movieClip 1114 {
}
movieClip 1115 {
}
movieClip 1116 {
}
movieClip 1119 {
}
movieClip 1121 {
}
movieClip 1124 {
}
movieClip 1126 {
}
movieClip 1129 {
}
movieClip 1131 {
}
movieClip 1133 {
}
movieClip 1135 {
}
movieClip 1138 {
}
movieClip 1140 {
}
movieClip 1142 {
}
movieClip 1145 {
}
movieClip 1146 {
}
movieClip 1147 {
}
movieClip 1149 {
}
movieClip 1151 {
}
movieClip 1152 {
}
movieClip 1153 {
}
movieClip 1154 {
}
movieClip 1155 {
}
movieClip 1157 {
}
movieClip 1159 {
}
movieClip 1161 {
}
movieClip 1164 {
}
movieClip 1172 {
}
movieClip 1174 {
}
movieClip 1176 {
}
movieClip 1179 {
}
movieClip 1181 {
}
movieClip 1183 {
}
movieClip 1185 {
}
movieClip 1187 {
}
movieClip 1190 {
}
movieClip 1193 {
}
movieClip 1194 {
}
// unknown tag 88 length 148
movieClip 1200 {
}
movieClip 1203 {
}
movieClip 1204 {
}
movieClip 1208 {
}
movieClip 1210 {
}
movieClip 1213 {
}
movieClip 1215 {
}
movieClip 1217 {
}
movieClip 1219 {
}
movieClip 1221 {
}
movieClip 1224 {
}
movieClip 1310 {
}
movieClip 1311 {
}
movieClip 1378 {
}
movieClip 1379 {
}
movieClip 1446 {
}
movieClip 1447 {
}
movieClip 1448 {
}
movieClip 1454 {
}
movieClip 1469 {
}
movieClip 1507 {
frame 15 {
gotoAndPlay(1);
}
frame 16 {
stop();
}
frame 17 {
stop();
}
}
movieClip 1524 {
frame 17 {
gotoAndPlay(1);
}
frame 18 {
stop();
}
frame 19 {
stop();
}
}
movieClip 1544 {
frame 20 {
gotoAndPlay(1);
}
frame 21 {
stop();
}
frame 22 {
stop();
}
}
movieClip 1569 {
frame 16 {
gotoAndPlay(1);
}
frame 17 {
stop();
}
frame 18 {
stop();
}
}
movieClip 1587 {
frame 19 {
gotoAndPlay(1);
}
frame 20 {
stop();
}
frame 21 {
stop();
}
}
movieClip 1602 {
frame 15 {
gotoAndPlay(1);
}
frame 16 {
stop();
}
frame 17 {
stop();
}
}
movieClip 1620 {
frame 18 {
gotoAndPlay(1);
}
frame 19 {
stop();
}
frame 20 {
stop();
}
}
movieClip 1621 {
}
movieClip 1627 {
}
movieClip 1634 {
}
movieClip 1640 {
}
movieClip 1647 {
}
movieClip 1655 {
}
movieClip 1662 {
}
movieClip 1671 {
}
movieClip 1678 {
}
movieClip 1685 {
}
movieClip 1686 {
}
movieClip 1687 {
}
movieClip 1688 {
}
movieClip 1692 {
frame 1 {
stop();
this._xscale = 50 + Math.random() * 80;
this._yscale = 50 + Math.random() * 80;
this.onEnterFrame = function () {
var v2 = Math.random() * 100;
if (v2 > 95) {
delete this.onEnterFrame;
this.gotoAndPlay(2);
}
};
}
}
movieClip 1693 {
}
movieClip 1695 {
frame 1 {
stop();
}
frame 41 {
stop();
}
}
movieClip 1698 {
frame 1 {
stop();
this._xscale = 60 + Math.random() * 150;
this._yscale = this._xscale;
this.onEnterFrame = function () {
var v3 = Math.random() * 100;
if (v3 > 95) {
this._alpha = 100;
this.can = true;
delete this.onEnterFrame;
this.onEnterFrame = function () {
if (this.can) {
this._x = 650;
this._y = -100 + Math.random() * 600;
this.speedX = 10 + Math.random() * 5;
this._alpha = 80 + Math.random() * 20;
this.speedY = Math.random() * 20;
this._alpha = 100;
this.can = false;
}
this._x -= this.speedX;
var v2 = Math.random() * 10;
if (v2 < 1) {
this.speedY += -1 + Math.random() * 2;
}
this._y += this.speedY;
if (this._x <= 0) {
this.can = true;
}
};
}
};
}
}
movieClip 1699 {
}
movieClip 1700 {
frame 1 {
stop();
}
frame 4 {
stop();
}
}
movieClip 1702 {
}
movieClip 1706 {
frame 1 {
stop();
}
}
movieClip 1708 {
}
movieClip 1711 {
}
movieClip 1714 {
}
movieClip 1721 {
}
movieClip 1762 {
}
movieClip 1775 {
frame 17 {
gotoAndPlay('init');
}
}
movieClip 1785 {
}
movieClip 1787 {
}
movieClip 1790 {
}
movieClip 1793 {
}
movieClip 1794 {
}
movieClip 1796 {
}
movieClip 1803 {
}
movieClip 1807 {
}
// unknown tag 88 length 108
movieClip 1813 {
}
movieClip 1814 {
}
movieClip 1816 {
}
movieClip 1817 {
}
movieClip 1819 {
}
movieClip 1821 {
}
movieClip 1832 {
}
// unknown tag 88 length 66
movieClip 1837 {
}
movieClip 1844 {
}
movieClip 1847 {
}
// unknown tag 88 length 153
movieClip 1865 {
frame 9 {
gotoAndPlay(1);
}
frame 10 {
stop();
}
frame 11 {
stop();
}
}
movieClip 1868 {
}
movieClip 1869 {
}
movieClip 1873 {
frame 1 {
stop();
}
}
// unknown tag 88 length 66
movieClip 1880 {
}
movieClip 1884 {
}
movieClip 1886 {
}
movieClip 1888 {
}
movieClip 1892 {
}
// unknown tag 88 length 153
movieClip 1897 {
}
frame 21 {
function hideAchievement() {
if (_root.enableAchievements) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).hide_username();
}
}
function getAchievement(obj) {
if (_root.enableAchievements && obj.canReceived) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).success(obj.id);
obj.canReceived = false;
}
}
function doAchievements() {}
function calcHowMuchClean(val, cum) {
var v3 = As.utils.minMaxInterval(0, 0, _root.maxPoo, sliderClean.maxBara._width, _root.pooLevel);
var v4 = Number(_root.cleanCost * _root.pooLevel);
if (v4 >= _root.money) {
var v7 = _root.money / v4;
v3 = As.utils.minMaxInterval(0, 0, _root.maxPoo, sliderClean.maxBara._width * v7, _root.pooLevel);
v4 = _root.money;
}
var v2 = v3;
if (val != undefined) {
v2 = val;
}
var v5 = Math.round(As.utils.minMaxInterval(0, 0, v3, v4, val));
if (_root.money == 0 || _root.pooLevel == 0) {
v2 = 0;
v5 = 0;
slider.tap._visible = false;
btnClean1._visible = false;
btnClean2._visible = false;
btnClean._visible = false;
txClean._visible = false;
if (_root.pooLevel == 0) {
txAllClean.text = 'You\'re Clean';
} else {
txAllClean.text = 'No money left';
}
txAllClean._visible = true;
slider.maska._width = v2;
txCleanCost.text = '$' + v5;
slider.tap._x = v2;
slider.cost = v5;
slider.cate = v2;
return v3;
}
slider.tap._visible = true;
btnClean1._visible = true;
btnClean2._visible = true;
btnClean._visible = true;
txClean._visible = true;
txAllClean._visible = false;
slider.maska._width = v2;
txCleanCost.text = '$' + v5;
slider.tap._x = v2;
slider.cost = v5;
slider.cate = v2;
return v3;
}
function cleanStatues() {
var v2 = _root.crrTime;
if (v2 == 0) {
v2 = 1;
}
mcShopStatues.gotoAndStop(v2);
var v3 = Math.round(As.utils.minMaxInterval(0, 1, _root.maxPoo, mcShopStatues['mcStatueShop' + v2]._totalframes, _root.pooLevel));
mcShopStatues['mcStatueShop' + v2].gotoAndStop(v3);
}
function init() {
slider.cost = 0;
calcHowMuchClean();
sliderClean.maska._width = As.utils.minMaxInterval(0, 0, _root.maxPoo, sliderClean.maxBara._width, _root.pooLevel);
defIcon.gotoAndStop(calcArmourLevel(_root.armour) + 1);
txArmourLevel.text = 'LEVEL ' + _root.armour;
txMoney.text = '$ ' + _root.money;
cleanStatues();
mcBuyAmmo.mcBullets.gotoAndStop(1);
var i = 1;
while (i <= _root.guns.length) {
var parinte = this['mcBuy' + i];
parinte.bullet.gotoAndStop(i);
parinte.bullet._visible = false;
parinte.bullets.gotoAndStop(1);
removeMovieClip(parinte.weapon);
var mc = parinte.attachMovie(_root.guns[i - 1], 'weapon', parinte.getNextHighestDepth());
var gun = eval(_root.guns[i - 1]);
mc.gotoAndStop(17);
mc.guide._visible = false;
mc._x = _root.gunsDepX[i - 1];
mc._y = _root.gunsDepY[i - 1];
parinte.txGunName.text = _root.gunsNames[i - 1];
parinte.txPrice.text = '$ ' + gun.price;
parinte.btnBuy.gotoAndStop(1);
parinte.details.text = 'Power: ' + gun.power;
parinte.details.text += '\nLoad: ' + gun.bulletsLoad;
buyWeapon(i);
parinte.btnBuy.onPress = function () {
var nr = this._parent._name.substr(5, 10);
if (this.buy == 1) {
initBuyAmmo(nr);
}
if (this.buy == 0) {
_root.inventory[nr - 1] = 1;
var pr = (eval(_root.guns[nr - 1])).price;
_root.money -= pr;
_root.crrGun = nr;
buyWeapon(nr);
init();
var ok = true;
var i = 1;
while (i <= _root.inventory.length) {
if (_root.inventory[i - 1] == 0) {
ok = false;
break;
}
++i;
}
if (ok) {
getAchievement(_root.achievement5);
}
}
};
++i;
}
}
function buyWeapon(i) {
var parinte = this['mcBuy' + i];
var gun = eval(_root.guns[i - 1]);
gun.bulletsShooted = 0;
gun.crrReload = 0;
gun.canShot = false;
var mc = parinte.weapon;
parinte.bullet._visible = false;
if (_root.inventory[i - 1] == 0) {
mc._alpha = 30;
if (gun.price > _root.money) {
parinte.gotoAndStop(2);
parinte.txPrice.text = '$ ' + gun.price;
} else {
parinte.gotoAndStop(1);
parinte.btnBuy.buy = 0;
parinte.scris.text = mesaje[0];
parinte.gotoAndStop(1);
}
} else {
if (gun.bulletPrice > _root.money) {
parinte.gotoAndStop(2);
} else {
parinte.gotoAndStop(1);
parinte.btnBuy.buy = 1;
parinte.scris.text = mesaje[1];
}
parinte.bullet._visible = true;
parinte.txPrice.text = 'ammo ' + gun.nrBullets;
mc._alpha = 100;
}
}
function initBuyAmmo(nr) {
mcBuyAmmo.mcBullets.gotoAndStop(nr);
var gun = eval(_root.guns[nr - 1]);
mcBuyAmmo.txInfo.text = _root.gunsNames[nr - 1] + ' Bullets';
mcBuyAmmo.txPrice.text = '$ ' + gun.bulletPrice + ' per unit';
mcBuyAmmo.bulletsBuy = 0;
mcBuyAmmo.bulletsUnitCost = Number(gun.bulletPrice);
mcBuyAmmo.rest = _root.money;
mcBuyAmmo.nr = nr;
mcBuyAmmo.txCate.text = '0';
mcBuyAmmo.txCost.text = 'Cost $0';
mcBuyAmmo.txRest.text = '$ ' + _root.money;
mcBuyAmmo._visible = true;
}
function initBuyDef() {
var v2 = calcArmourLevel(_root.armour);
mcBuyDeffense.defIcon.gotoAndStop(v2 + 1);
mcBuyDeffense.txInfo.text = _root.defNames[v2];
mcBuyDeffense.txPrice.text = '$ ' + _root.armourCost + ' per unit';
mcBuyDeffense.defBuy = 0;
mcBuyDeffense.defUnitCost = _root.armourCost;
mcBuyDeffense.rest = _root.money;
mcBuyDeffense.txCate.text = '0';
mcBuyDeffense.txCost.text = 'Cost $0';
mcBuyDeffense.txRest.text = '$ ' + _root.money;
mcBuyDeffense._visible = true;
}
function buyBullets(cate) {
var v2 = (mcBuyAmmo.bulletsBuy + cate) * mcBuyAmmo.bulletsUnitCost;
if (cate <= -mcBuyAmmo.bulletsBuy) {
cate = -mcBuyAmmo.bulletsBuy;
v2 = 0;
}
if (v2 >= 0 and v2 <= _root.money) {
mcBuyAmmo.rest = Number(_root.money - v2);
mcBuyAmmo.txRest.text = '$ ' + mcBuyAmmo.rest;
mcBuyAmmo.bulletsBuy += cate;
mcBuyAmmo.txCate.text = mcBuyAmmo.bulletsBuy;
mcBuyAmmo.txCost.text = 'Cost $' + v2;
}
}
function buyDef(cate) {
var v2 = (mcBuyDeffense.defBuy + cate) * mcBuyDeffense.defUnitCost;
if (cate <= -mcBuyDeffense.defBuy) {
cate = -mcBuyDeffense.defBuy;
v2 = 0;
}
if (v2 >= 0 and v2 <= _root.money) {
mcBuyDeffense.rest = Number(_root.money - v2);
mcBuyDeffense.txRest.text = '$ ' + mcBuyAmmo.rest;
mcBuyDeffense.defBuy += cate;
mcBuyDeffense.txCate.text = mcBuyDeffense.defBuy;
mcBuyDeffense.txCost.text = 'Cost $' + v2;
}
var v4 = calcArmourLevel(_root.armour + mcBuyDeffense.defBuy);
mcBuyDeffense.defIcon.gotoAndStop(v4 + 1);
mcBuyDeffense.txInfo.text = _root.defNames[v4];
}
function playSound3(mc, vol) {
var v1 = new Sound(mc);
v1.setVolume(vol);
mc.gotoAndPlay(2);
}
function stopSounds() {
var v2 = 1;
while (v2 <= 10) {
stopSound(_root['sound_1_' + v2]);
stopSound(_root['sound_2_' + v2]);
stopSound(_root['sound_3_' + v2]);
stopSound(_root['bgrSound' + v2]);
stopSound(_root['sound_bird' + v2]);
stopSound(_root['sound_kill1' + v2]);
stopSound(_root['sound_kill2' + v2]);
stopSound(_root['sound_kill3' + v2]);
stopSound(_root['sound_hit1' + v2]);
stopSound(_root['sound_hit2' + v2]);
stopSound(_root['sound_hit3' + v2]);
++v2;
}
stopSound(_root.main_bird1);
stopSound(_root.main_bird2);
stopSound(_root.main_flap1);
stopSound(_root.main_flap2);
stopSound(_root.ploaie_sound);
stopSound(_root.thunder);
stopSound(_root.snow_sound);
}
stop();
stop();
stopSounds();
Mouse.show();
mcBuyAmmo._visible = false;
mcBuyDeffense._visible = false;
_root.gunsDepX = [0, -4, 0, 25, 3, 7, 0, 0, -2];
_root.gunsDepY = [3, 3, 7, 10, 10, 5, 7, 10, 10];
var mesaje = ['Buy it', 'Buy Ammo', ''];
btnClean1.onPress = function () {
calcHowMuchClean();
};
btnClean2.onPress = function () {
calcHowMuchClean(0);
};
btnClean.onPress = function () {
var v2 = As.utils.minMaxInterval(0, 0, sliderClean.maxBara._width, _root.maxPoo, slider.cate);
_root.pooLevel -= v2;
if (_root.pooLevel <= 0) {
_root.pooLevel = 0;
}
_root.money -= slider.cost;
if (_root.money <= 0) {
_root.money = 0;
}
init();
};
slider.tap.onPress = function () {
var v2 = calcHowMuchClean(this._x);
this.startDrag(false, 0, this._y, v2, this._y);
this.onEnterFrame = function () {
calcHowMuchClean(this._x, true);
};
};
slider.tap.onReleaseOutside = function () {
this.stopDrag();
delete this.onEnterFrame;
};
slider.tap.onRelease = slider.tap.onReleaseOutside;
var i = 1;
while (i <= 3) {
mcBuyAmmo['btnu' + i].onPress = function () {
this.gotoAndPlay(2);
var v4 = Number(this._name.substr(4, 10));
var v2 = Math.pow(10, v4 - 1);
var v3 = Math.floor(mcBuyAmmo.rest / mcBuyAmmo.bulletsUnitCost);
if (v2 >= v3) {
v2 = v3;
}
buyBullets(v2);
};
mcBuyAmmo['btnd' + i].onPress = function () {
this.gotoAndPlay(2);
var v2 = Number(this._name.substr(4, 10));
var v3 = -Math.pow(10, v2 - 1);
buyBullets(v3);
};
mcBuyDeffense['btnu' + i].onPress = function () {
this.gotoAndPlay(2);
var v4 = Number(this._name.substr(4, 10));
var v2 = Math.pow(10, v4 - 1);
var v3 = Math.floor(mcBuyDeffense.rest / mcBuyDeffense.defUnitCost);
if (v2 >= v3) {
v2 = v3;
}
buyDef(v2);
};
mcBuyDeffense['btnd' + i].onPress = function () {
this.gotoAndPlay(2);
var v2 = Number(this._name.substr(4, 10));
var v3 = -Math.pow(10, v2 - 1);
buyDef(v3);
};
++i;
}
mcBuyAmmo.btnu4.onPress = function () {
this.gotoAndPlay(2);
var v2 = Math.floor(mcBuyAmmo.rest / mcBuyAmmo.bulletsUnitCost);
buyBullets(v2);
};
mcBuyAmmo.btnd4.onPress = function () {
this.gotoAndPlay(2);
var v2 = -mcBuyAmmo.bulletsBuy;
buyBullets(v2);
};
mcBuyAmmo.bgr.onRollOver = function () {
this.useHandCursor = false;
};
mcBuyDeffense.bgr.onRollOver = function () {
this.useHandCursor = false;
};
mcBuyDeffense.btnu4.onPress = function () {
this.gotoAndPlay(2);
var v2 = Math.floor(mcBuyDeffense.rest / mcBuyDeffense.defUnitCost);
buyDef(v2);
};
mcBuyDeffense.btnd4.onPress = function () {
this.gotoAndPlay(2);
var v2 = -mcBuyDeffense.defBuy;
buyDef(v2);
};
mcBuyAmmo.btnCancel.onPress = function () {
mcBuyAmmo._visible = false;
};
mcBuyAmmo.btnBuy.onPress = function () {
_root.money = mcBuyAmmo.rest;
var gun = eval(_root.guns[mcBuyAmmo.nr - 1]);
gun.nrBullets += mcBuyAmmo.bulletsBuy;
txMoney.text = '$ ' + _root.money;
init();
mcBuyAmmo._visible = false;
};
btnDef.onPress = function () {
initBuyDef();
mcBuyDeffense._visible = true;
};
mcBuyDeffense.btnCancel.onPress = function () {
mcBuyDeffense._visible = false;
};
mcBuyDeffense.btnBuy.onPress = function () {
_root.money = mcBuyDeffense.rest;
_root.armour += mcBuyDeffense.defBuy;
txMoney.text = '$ ' + _root.money;
defIcon.gotoAndStop(calcArmourLevel(_root.armour) + 1);
init();
mcBuyDeffense._visible = false;
if (_root.armour >= 30) {
getAchievement(_root.achievement4);
}
};
slider.tap.onEnterFrame = function () {};
btnPlay.onPress = function () {
playSound3(sound_click);
_root.gotoAndStop('lastframe');
_root.gotoAndStop('game');
};
if (!_root.firstLevel) {
++_root.crrLevel;
}
if (_root.firstLevel) {
_root.firstLevel = false;
}
init();
if (_root.enableHighScore) {
mcLogo._alpha = 50;
}
mcLogo.onRollOver = function () {
this._alpha = 100;
};
mcLogo.onPress = function () {
if (_root.enableHighScore) {
getURL('http://www.mofunzone.com', '_blank');
} else {
getURL('http://www.mofunzone.com/online_games/damn_birds_2.shtml', '_blank');
}
trace(_root.enableHighScore);
};
}
movieClip 1901 {
}
movieClip 1903 {
}
movieClip 1915 {
}
movieClip 1919 {
}
movieClip 1923 {
}
movieClip 1924 {
}
movieClip 1926 {
}
button 1932 {
on (release) {
gotoAndStop('shopDefense');
}
}
movieClip 1957 {
}
movieClip 1963 {
frame 1 {
stop();
}
}
movieClip 1965 {
}
movieClip 1967 {
}
movieClip 1975 {
}
movieClip 1977 {
}
movieClip 1978 {
}
// unknown tag 88 length 138
button 1984 {
on (release) {
gotoAndStop('shopDefense');
}
}
movieClip 1988 {
}
movieClip 2001 {
}
// unknown tag 88 length 61
movieClip 2008 {
frame 1 {
stop();
}
}
movieClip 2019 {
}
movieClip 2029 {
}
frame 31 {
btnPrev.enabled = false;
}
button 2033 {
on (release) {
gotoAndStop('main');
}
}
movieClip 2038 {
}
movieClip 2041 {
}
// unknown tag 88 length 87
button 2046 {
on (release) {
nextFrame();
}
}
// unknown tag 88 length 78
// unknown tag 88 length 83
movieClip 2057 {
}
movieClip 2058 {
}
movieClip 2063 {
}
movieClip 2064 {
}
button 2072 {
on (release) {
prevFrame();
}
}
movieClip 2088 {
}
movieClip 2089 {
}
frame 34 {
stop();
txShield._visible = false;
txShield.text = '';
var keyListener = new Object();
keyListener.onKeyDown = function () {
if (_root._currentframe == 34) {
var v2 = Key.getCode();
if (v2 == 67) {
txShield._visible = true;
txShield.text = '';
Key.removeListener(keyListener);
}
}
};
Key.addListener(keyListener);
btnNext.enabled = false;
}
button 2099 {
on (release) {
if (txShield.text == 'givemethemoney') {
_root.goMoney = 100000;
}
prevFrame();
}
}
frame 35 {
function hideAchievement() {
if (_root.enableAchievements) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).hide_username();
}
}
function getAchievement(obj) {
if (_root.enableAchievements && obj.canReceived) {
(MoFunZoneAPI.AchievementLoaderAS2.getAPI()).success(obj.id);
obj.canReceived = false;
}
}
function doAchievements() {}
function stopSound(mc) {
var v1 = new Sound(mc);
v1.stop();
mc.gotoAndStop(1);
}
function stopSounds() {
var v2 = 1;
while (v2 <= 10) {
stopSound(_root['sound_1_' + v2]);
stopSound(_root['sound_2_' + v2]);
stopSound(_root['sound_3_' + v2]);
stopSound(_root['bgrSound' + v2]);
stopSound(_root['sound_bird' + v2]);
++v2;
}
}
function playSound2(mc, vol) {
if (mc._currentframe == 1) {
var v2 = new Sound(mc);
if (vol != undefined) {
v2.setVolume(vol);
}
mc.gotoAndPlay(2);
}
}
function stopSounds() {
var v2 = 1;
while (v2 <= 10) {
stopSound(_root['sound_1_' + v2]);
stopSound(_root['sound_2_' + v2]);
stopSound(_root['sound_3_' + v2]);
stopSound(_root['bgrSound' + v2]);
stopSound(_root['sound_bird' + v2]);
stopSound(_root['sound_kill1' + v2]);
stopSound(_root['sound_kill2' + v2]);
stopSound(_root['sound_kill3' + v2]);
stopSound(_root['sound_hit1' + v2]);
stopSound(_root['sound_hit2' + v2]);
stopSound(_root['sound_hit3' + v2]);
++v2;
}
stopSound(_root.main_bird1);
stopSound(_root.main_bird2);
stopSound(_root.main_flap1);
stopSound(_root.main_flap2);
stopSound(_root.ploaie_sound);
stopSound(_root.thunder);
stopSound(_root.snow_sound);
}
stop();
Mouse.show();
stop();
cum = _root.finishLevel;
_root.sound.stop();
_root.sound.setVolume(0);
_root.soundX.stop();
_root.soundX.setVolume(0);
stopSound(_root.bgrSound1);
stopSound(_root.bgrSound2);
stopSound(_root.bgrSound3);
stopSound(_root.snow_sound);
stopSound(_root.ploaie_sound);
stopSound(_root.thunder);
stopSounds();
if (cum) {
mcInfo.gotoAndStop(2);
mcInfo.txTitleScore.text = 'YOUR SCORE IS ' + Number(_root.score);
if (_root.enableHighScore) {
loadVariablesNum('http://gamefilez.mofunzone.com/game_scores/damn_birds_2/mfz.php?' + _root.score, 0);
}
} else {
if (_root.crrLevel == _root.maxLevels) {
mcInfo.gotoAndStop(3);
if (_root.enableHighScore) {
loadVariablesNum('http://gamefilez.mofunzone.com/game_scores/damn_birds_2/mfz.php?' + _root.score, 0);
}
getAchievement(_root.achievement1);
if (_root.armour == 0) {
getAchievement(_root.achievement6);
}
} else {
mcInfo.gotoAndStop(1);
if (_root.crrLevel == 1) {
getAchievement(_root.achievement7);
}
if (_root.crrLevel == 2) {
if (_root.survive) {
getAchievement(_root.achievement12);
}
}
}
mcInfo.txTitle.text = 'LEVEL ' + Number(_root.crrLevel) + ' COMPLETE';
mcInfo.txScore.text = Number(_root.score);
}
mcInfo.mcSubmit._visible = false;
mcInfo.mcSubEnable._visible = false;
mcInfo.mcSubmit.txName.text = '';
mcInfo.btnSubmit.onRelease = function () {
this.gotoAndStop(1);
this.enabled = false;
mcInfo.mcSubmit._visible = true;
mcInfo.mcSubEnable._visible = true;
};
mcInfo.mcSubmit.btnSubmit2.onRelease = function () {
mcInfo.btnSubmit.enabled = true;
mcInfo.mcSubmit._visible = false;
mcInfo.mcSubEnable._visible = false;
getURL('http://www.mofunzone.com/online_games/damn_birds_2.shtml', '_blank');
};
mcInfo.mcSubmit.btnSubmit.onPress = function () {
if (mcInfo.mcSubmit.txName.text != '') {
PLAYER_NAME = mcInfo.mcSubmit.txName.text;
now = new Date();
EPOCH_TIME = now.getTime();
YEAR = now.getYear();
getURL('http://www.MoFunZone.com/game_scores/damn_birds_2/highscore.php?' + PLAYER_NAME + '/' + EPOCH_TIME + '/' + YEAR, '_blank');
trace(mcInfo.mcSubmit.txName.text.length);
mcInfo.mcSubmit._visible = false;
mcInfo.mcSubEnable._visible = true;
_root.canSubmit = false;
}
};
mcInfo.mcAci.onPress = function () {
getURL('http://www.MoFunZone.com', '_blank');
};
mcInfo.mcSubmit.btnCancel.onPress = function () {
mcInfo.mcSubmit._visible = false;
mcInfo.mcSubEnable._visible = false;
mcInfo.btnSubmit.enabled = true;
};
mcInfo.showStatue.gotoAndStop(_root.crrTime);
mcInfo._alpha = 0;
var ag = (_root.nrShooted / _root.birdNumber) * 100;
if (_root.birdNumber == 0) {
ag = 0;
}
mcInfo.ag.text = Math.round(Number(ag)) + '%';
var intel = Math.round(Number(ag * _root.birdNumber / _root.numberOfShots));
if (intel >= 100) {
intel = 100;
}
if (_root.numberOfShots == 0) {
intel = '0';
}
mcInfo.intel.text = intel + '%';
var clLevel = Math.round(Number(100 - (_root.pooLevel / _root.maxPoo) * 100));
mcInfo.cl.text = clLevel + '%';
var ov = Math.floor((ag + intel + clLevel) / 3);
var letters = ['F', 'E', 'D', 'C', 'B', 'A'];
if (ov <= 0) {
ov = 0;
}
if (ov > 0 && ov <= 20) {
procLet = 0;
}
if (ov > 20 && ov <= 40) {
procLet = 1;
}
if (ov > 40 && ov <= 60) {
procLet = 2;
}
if (ov > 60 && ov <= 80) {
procLet = 3;
}
if (ov > 80 && ov <= 95) {
procLet = 4;
}
if (ov > 95) {
procLet = 5;
}
mcInfo.ov.text = letters[procLet];
mcInfo._visible = true;
var stB = _root.nrShooted + ' birds';
if (mcInfo._currentframe > 1) {
stB = _root.totalBirds + ' birds';
}
if (_root.nrShooted == 1) {
stB = '1 bird';
}
mcInfo.txWin1.text = 'You have killed ' + stB;
if (mcInfo._currentframe > 1) {
mcInfo.txWin2.text = 'and earned $' + Number(_root.score);
}
if (mcInfo._currentframe == 1) {
mcInfo.txWin2.text = 'and earned $' + Number(_root.win);
}
_root.money += _root.win;
var mc = '';
if (mcInfo._currentframe == 1) {
var mcS = _root['sound_end' + _root.crrTime + '_' + As.utils.rnd(1, 3)];
}
if (mcInfo._currentframe == 2) {
var mcS = _root['sound_over' + _root.crrTime + '_' + As.utils.rnd(1, 2)];
}
if (mcInfo._currentframe == 3) {
var mcS = _root.sound_complete3;
}
playSound2(mcS, 100);
mcInfo.onEnterFrame = function () {
mcInfo._alpha += 20;
if (mcInfo._alpha >= 100) {
mcInfo._alpha = 100;
delete this.onEnterFrame;
}
};
mcInfo.btnShop.onPress = function () {
_root.gotoAndStop('shop');
};
mcInfo.btnRetry.onPress = function () {
_root.gotoAndStop('game');
};
mcInfo.btnSCore.onPress = function () {
trace('score');
};
}
movieClip 2106 {
}
button 2118 {
on (release) {
gotoAndStop('shop');
}
}
// unknown tag 88 length 100
movieClip 2125 {
}
button 2128 {
on (release) {
_root.gotoAndStop('main');
}
}
movieClip 2131 {
}
button 2133 {
on (release) {
getURL('http://www.mofunzone.com', '_blank');
}
}
movieClip 2139 {
}
movieClip 2143 {
}
movieClip 2146 {
}
movieClip 2151 {
}