Frame 1
function preload() {
var _local4 = this.getBytesTotal();
var _local5 = this.getBytesLoaded();
var _local3 = int((_local5 * 100) / _local4);
_root.mvBar.loadtext = _local3 + " %";
mcBar.gotoAndStop(_local3);
if ((_local3 >= 100) && (_local4 > 4)) {
delete this.onEnterFrame;
gotoAndStop ("titleScreen");
}
}
stop();
this.onEnterFrame = preload;
ver = $version;
Frame 10
function geturl() {
}
stop();
_global.sndobj = new com.sound.CSound();
var gameLevel = 3;
var currentlevel = 1;
var gamescore1 = 0;
var levelscore = 1500;
var dieCount = 0;
var sndon = true;
instr_btn.onRelease = function () {
gotoAndStop ("instructions");
stopAllSounds();
};
play_btn.onRelease = function () {
masina.play();
masina.roti.play();
stopAllSounds();
};
more_btn.onRelease = function () {
getURL ("http://www.101cargames.com", "_blank");
};
Frame 20
gotoAndStop ("game");
Frame 40
play_btn.onRelease = function () {
gotoAndStop ("game");
};
Frame 50
init();
Symbol 51 MovieClip [level1] Frame 1
var copii;
var beculete1;
var beculete2;
var beculete3;
var beculete4;
var beculete5;
var beculete10;
onEnterFrame = function () {
if (coordonate_masina == undefined) {
} else {
if (Number(coordonate_masina) <= 0) {
if (beculete1._visible == undefined) {
beculete1 = this.attachMovie("becuri1", "becuri1", 4);
beculete1._x = -30.5;
beculete1._y = 1004.4;
beculete1.swapDepths(end);
trace("attach1");
}
}
if ((Number(coordonate_masina) >= 20) && (Number(coordonate_masina) < 258)) {
if (beculete2._visible == undefined) {
beculete2 = this.attachMovie("becuri2", "becuri2", 5);
beculete2._x = 811.25;
beculete2._y = 899.35;
trace("attach2");
}
}
if ((Number(coordonate_masina) >= 500) && (Number(coordonate_masina) < 768)) {
beculete1.removeMovieClip();
}
if ((Number(coordonate_masina) >= 768) && (Number(coordonate_masina) < 1250)) {
if (beculete3._visible == undefined) {
beculete3 = this.attachMovie("becuri3", "becuri3", 6);
beculete3._x = 1599.95;
beculete3._y = 880.25;
trace("attach3");
}
}
if ((Number(coordonate_masina) >= 1250) && (Number(coordonate_masina) < 2000)) {
beculete2.removeMovieClip();
}
if ((Number(coordonate_masina) >= 2000) && (Number(coordonate_masina) < 2540)) {
beculete3.removeMovieClip();
}
if ((Number(coordonate_masina) >= 2540) && (Number(coordonate_masina) < 3640)) {
if (beculete4._visible == undefined) {
beculete4 = this.attachMovie("becuri4", "becuri4", 4);
beculete4._x = 3271.6;
beculete4._y = 780.5;
trace("attach4");
}
}
if ((Number(coordonate_masina) >= 3640) && (Number(coordonate_masina) < 4500)) {
beculete4.removeMovieClip();
}
if ((Number(coordonate_masina) >= 4500) && (Number(coordonate_masina) < 5750)) {
if (beculete5._visible == undefined) {
beculete5 = this.attachMovie("becuri5", "becuri5", 4);
beculete5._x = 5326.4;
beculete5._y = 805.4;
trace("attach5");
}
}
if ((Number(coordonate_masina) >= 5750) && (Number(coordonate_masina) < 6000)) {
beculete5.removeMovieClip();
}
if (Number(coordonate_masina) >= 6000) {
if (beculete10._visible == undefined) {
beculete10 = this.attachMovie("becuri10", "becuri10", 4);
beculete10._x = 7043.4;
beculete10._y = 859.8;
trace("attach10");
horn = this.attachMovie("horn_l1", "horn_l1", 100);
horn._x = 7115.6;
horn._y = 786;
}
}
}
if (mos == true) {
if (copii._visible == undefined) {
_root.game.b._Level.mcVehiclePlace._dmCarBody.mos_masina._visible = false;
copii = this.attachMovie("copii", "copii", 10);
copii._x = coordonate_masina;
copii._y = coordonate_masina_y;
var _local3 = new mx.transitions.Tween(copii, "_x", none, copii._x, 6954, 3, true);
var _local4 = new mx.transitions.Tween(copii, "_y", none, copii._y, 909.9, 3, true);
_local3.onMotionFinished = function () {
copii.play();
};
}
}
};
Symbol 96 MovieClip Frame 1
stop();
Symbol 98 Button
on (press) {
getURL ("http://www.101cargames.com", "_blank");
}
Symbol 464 MovieClip [__Packages.mx.transitions.OnEnterFrameBeacon] Frame 0
class mx.transitions.OnEnterFrameBeacon
{
function OnEnterFrameBeacon () {
}
static function init() {
var _local4 = _global.MovieClip;
if (!_root.__OnEnterFrameBeacon) {
mx.transitions.BroadcasterMX.initialize(_local4);
var _local3 = _root.createEmptyMovieClip("__OnEnterFrameBeacon", 9876);
_local3.onEnterFrame = function () {
_global.MovieClip.broadcastMessage("onEnterFrame");
};
}
}
static var version = "1.1.0.52";
}
Symbol 465 MovieClip [__Packages.mx.transitions.BroadcasterMX] Frame 0
class mx.transitions.BroadcasterMX
{
var _listeners;
function BroadcasterMX () {
}
static function initialize(o, dontCreateArray) {
if (o.broadcastMessage != undefined) {
delete o.broadcastMessage;
}
o.addListener = mx.transitions.BroadcasterMX.prototype.addListener;
o.removeListener = mx.transitions.BroadcasterMX.prototype.removeListener;
if (!dontCreateArray) {
o._listeners = new Array();
}
}
function addListener(o) {
removeListener(o);
if (broadcastMessage == undefined) {
broadcastMessage = mx.transitions.BroadcasterMX.prototype.broadcastMessage;
}
return(_listeners.push(o));
}
function removeListener(o) {
var _local2 = _listeners;
var _local3 = _local2.length;
while (_local3--) {
if (_local2[_local3] == o) {
_local2.splice(_local3, 1);
if (!_local2.length) {
broadcastMessage = undefined;
}
return(true);
}
}
return(false);
}
function broadcastMessage() {
var _local5 = String(arguments.shift());
var _local4 = _listeners.concat();
var _local6 = _local4.length;
var _local3 = 0;
while (_local3 < _local6) {
_local4[_local3][_local5].apply(_local4[_local3], arguments);
_local3++;
}
}
static var version = "1.1.0.52";
}
Symbol 466 MovieClip [__Packages.mx.transitions.Tween] Frame 0
class mx.transitions.Tween
{
var obj, prop, begin, useSeconds, _listeners, addListener, prevTime, _time, looping, _duration, broadcastMessage, isPlaying, _fps, prevPos, _pos, change, _intervalID, _startTime;
function Tween (obj, prop, func, begin, finish, duration, useSeconds) {
mx.transitions.OnEnterFrameBeacon.init();
if (!arguments.length) {
return;
}
this.obj = obj;
this.prop = prop;
this.begin = begin;
position = (begin);
this.duration = (duration);
this.useSeconds = useSeconds;
if (func) {
this.func = func;
}
this.finish = (finish);
_listeners = [];
addListener(this);
start();
}
function set time(t) {
prevTime = _time;
if (t > duration) {
if (looping) {
rewind(t - _duration);
update();
broadcastMessage("onMotionLooped", this);
} else {
if (useSeconds) {
_time = _duration;
update();
}
stop();
broadcastMessage("onMotionFinished", this);
}
} else if (t < 0) {
rewind();
update();
} else {
_time = t;
update();
}
//return(time);
}
function get time() {
return(_time);
}
function set duration(d) {
_duration = (((d == null) || (d <= 0)) ? (_global.Infinity) : (d));
//return(duration);
}
function get duration() {
return(_duration);
}
function set FPS(fps) {
var _local2 = isPlaying;
stopEnterFrame();
_fps = fps;
if (_local2) {
startEnterFrame();
}
//return(FPS);
}
function get FPS() {
return(_fps);
}
function set position(p) {
setPosition(p);
//return(position);
}
function setPosition(p) {
prevPos = _pos;
obj[prop] = (_pos = p);
broadcastMessage("onMotionChanged", this, _pos);
updateAfterEvent();
}
function get position() {
return(getPosition());
}
function getPosition(t) {
if (t == undefined) {
t = _time;
}
return(func(t, begin, change, _duration));
}
function set finish(f) {
change = f - begin;
//return(finish);
}
function get finish() {
return(begin + change);
}
function continueTo(finish, duration) {
begin = position;
this.finish = (finish);
if (duration != undefined) {
this.duration = (duration);
}
start();
}
function yoyo() {
continueTo(begin, time);
}
function startEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.addListener(this);
} else {
_intervalID = setInterval(this, "onEnterFrame", 1000 / _fps);
}
isPlaying = true;
}
function stopEnterFrame() {
if (_fps == undefined) {
_global.MovieClip.removeListener(this);
} else {
clearInterval(_intervalID);
}
isPlaying = false;
}
function start() {
rewind();
startEnterFrame();
broadcastMessage("onMotionStarted", this);
}
function stop() {
stopEnterFrame();
broadcastMessage("onMotionStopped", this);
}
function resume() {
fixTime();
startEnterFrame();
broadcastMessage("onMotionResumed", this);
}
function rewind(t) {
_time = ((t == undefined) ? 0 : (t));
fixTime();
update();
}
function fforward() {
time = (_duration);
fixTime();
}
function nextFrame() {
if (useSeconds) {
time = ((getTimer() - _startTime) / 1000);
} else {
time = (_time + 1);
}
}
function onEnterFrame() {
nextFrame();
}
function prevFrame() {
if (!useSeconds) {
time = (_time - 1);
}
}
function toString() {
return("[Tween]");
}
function fixTime() {
if (useSeconds) {
_startTime = getTimer() - (_time * 1000);
}
}
function update() {
position = (getPosition(_time));
}
static var version = "1.1.0.52";
static var __initBeacon = mx.transitions.OnEnterFrameBeacon.init();
static var __initBroadcaster = mx.transitions.BroadcasterMX.initialize(mx.transitions.Tween.prototype, true);
function func(t, b, c, d) {
return(((c * t) / d) + b);
}
}
Symbol 467 MovieClip [__Packages.com.sound.CSound] Frame 0
class com.sound.CSound
{
static var instance;
var engineStart, engineLoop, bgsnd, truck_snd, welcome, trickotreat, merry, sndVol, truckstart, truckblast, zoombiesnd, truckidle;
function CSound () {
engineStart = new Sound();
engineStart.attachSound("engineStart");
engineLoop = new Sound();
engineLoop.attachSound("engineLoop");
bgsnd = new Sound();
bgsnd.attachSound("bgsnd");
truck_snd = new Sound();
truck_snd.attachSound("truck_snd");
welcome = new Sound();
welcome.attachSound("welcome");
trickotreat = new Sound();
trickotreat.attachSound("trickotreat");
merry = new Sound();
merry.attachSound("merry");
sndVol = new Sound();
truckstart = new Sound();
truckstart.attachSound("bg1");
truckstart.setVolume(40);
truckblast = new Sound();
truckblast.attachSound("blast");
zoombiesnd = new Sound();
zoombiesnd.attachSound("zoombiesnd");
truckstart.onSoundComplete = function () {
this.start(0, 1);
};
truckidle.onSoundComplete = function () {
this.start(0, 1);
};
instance = this;
}
function sndvolon() {
sndVol.setVolume(100);
}
function sndvoloff() {
sndVol.setVolume(0);
}
function playBgsnd() {
stopBgsnd();
truckstart.start(0.999999);
bgsnd.start(0, 999999999);
bgsnd.setVolume(50);
}
function stopBgsnd() {
bgsnd.stop();
}
function playStartsnd() {
truckstart.stop();
truckstart.start(0, 9999999);
}
function stopSnds() {
stopBgsnd();
truckstart.stop();
truckidle.stop();
}
function playWelcome() {
welcome.start(0, 1);
}
function playEngineStart() {
engineStart.start(0, 1);
}
function playEngineLoop() {
engineLoop.start(0, 9999999);
}
function playBlastsnd() {
truckblast.start(0, 1);
}
function playTrick() {
trickotreat.start(0, 1);
}
function playMerry() {
merry.start(0, 1);
}
}
Symbol 468 MovieClip [__Packages.mx.transitions.easing.Elastic] Frame 0
class mx.transitions.easing.Elastic
{
function Elastic () {
}
static function easeIn(t, b, c, d, a, p) {
if (t == 0) {
return(b);
}
t = t / d;
if (t == 1) {
return(b + c);
}
if (!p) {
p = d * 0.3;
}
if ((!a) || (a < Math.abs(c))) {
a = c;
var _local7 = p / 4;
} else {
var _local7 = (p / (Math.PI*2)) * Math.asin(c / a);
}
t = t - 1;
return((-((a * Math.pow(2, 10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p))) + b);
}
static function easeOut(t, b, c, d, a, p) {
if (t == 0) {
return(b);
}
t = t / d;
if (t == 1) {
return(b + c);
}
if (!p) {
p = d * 0.3;
}
if ((!a) || (a < Math.abs(c))) {
a = c;
var _local7 = p / 4;
} else {
var _local7 = (p / (Math.PI*2)) * Math.asin(c / a);
}
return((((a * Math.pow(2, -10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p)) + c) + b);
}
static function easeInOut(t, b, c, d, a, p) {
if (t == 0) {
return(b);
}
t = t / (d / 2);
if (t == 2) {
return(b + c);
}
if (!p) {
p = d * 0.45;
}
if ((!a) || (a < Math.abs(c))) {
a = c;
var _local7 = p / 4;
} else {
var _local7 = (p / (Math.PI*2)) * Math.asin(c / a);
}
if (t < 1) {
t = t - 1;
return((-0.5 * ((a * Math.pow(2, 10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p))) + b);
}
t = t - 1;
return(((((a * Math.pow(2, -10 * t)) * Math.sin((((t * d) - _local7) * (Math.PI*2)) / p)) * 0.5) + c) + b);
}
static var version = "1.1.0.52";
}
Symbol 469 MovieClip [__Packages.mx.transitions.easing.Regular] Frame 0
class mx.transitions.easing.Regular
{
function Regular () {
}
static function easeIn(t, b, c, d) {
t = t / d;
return(((c * t) * t) + b);
}
static function easeOut(t, b, c, d) {
t = t / d;
return((((-c) * t) * (t - 2)) + b);
}
static function easeInOut(t, b, c, d) {
t = t / (d / 2);
if (t < 1) {
return((((c / 2) * t) * t) + b);
}
t--;
return((((-c) / 2) * ((t * (t - 2)) - 1)) + b);
}
static var version = "1.1.0.52";
}
Symbol 470 MovieClip [__Packages.com.UI.Game] Frame 0
class com.UI.Game extends MovieClip
{
static var m_instance;
var inPostGame, m_pauseOn, hitcount, min, sec, snd, firetime, m_level, attachMovie, m_pEngine, _parent, setint, inProcess, scen, m_car, bodyCrash, score, onEnterFrame, _scrPause;
function Game () {
super();
m_instance = this;
}
function set pauseOn(pauseState) {
if (inPostGame) {
return;
}
m_pauseOn = pauseState;
enableProcess(!m_pauseOn);
//return(pauseOn);
}
function get pauseOn() {
return(m_pauseOn);
}
function onLoad() {
init();
pauseOn = (false);
}
function init() {
_root.levelscore = 1500;
hitcount = 0;
min = 5;
sec = 60;
snd = com.sound.CSound.instance;
firetime = 75;
_level0.game.b._Level.mcVehiclePlace._dmCarBody.far._visible = false;
trace("_root.currentlevel" + _root.currentlevel);
m_level = attachMovie("level" + _root.currentlevel, "_Level", 1001);
trace("m_level._x" + m_level._y);
m_level.mcHit._alpha = 0;
m_pEngine = new com.ACA.DynamicsEngine(m_level.mcHit, 7);
var mc = attachMovie("popup", "popup", 1002);
trace("mc" + mc);
mc._x = 400;
mc._y = 300;
mc.gotoAndStop("startup");
var sco = this;
trace("init :" + _root.gamescore1);
_parent.scorepanel.gscore1 = _root.gamescore1;
if (_root.sndon == true) {
_parent.scorepanel.music.txt = "ON";
snd.sndvolon();
} else {
_parent.scorepanel.music.txt = "OFF";
snd.sndvoloff();
}
mc.onEnterFrame = function () {
if (mc.lev._currentframe >= 90) {
sco.str();
mc.onEnterFrame = null;
}
};
_parent.scorepanel.music.onRelease = function () {
if (_root.sndon == true) {
this.gotoAndStop(2);
_root.sndon = false;
sco.snd.sndvoloff();
} else {
this.gotoAndStop(1);
_root.sndon = true;
sco.snd.sndvolon();
}
};
}
function str() {
newRace();
setint = setInterval(this, "tim", 1000);
}
function tim() {
if (!pauseOn) {
sec--;
if (sec <= 0) {
sec = 59;
min--;
if (min < 0) {
_parent.scorepanel.timer = "00:00";
clearInterval(setint);
}
}
if (min == 0) {
_parent.scorepanel.timer = "00:" + sec;
if (sec < 10) {
_parent.scorepanel.timer = "00:0" + sec;
}
} else {
_parent.scorepanel.timer = (("0" + min) + ":") + sec;
if (sec < 10) {
_parent.scorepanel.timer = ((("0" + min) + ":") + "0") + sec;
}
}
}
}
function newRace() {
inPostGame = false;
inProcess = true;
scen._x = 0;
scen._y = 0;
snd.playBgsnd();
snd.playStartsnd();
if (_root.sndon == true) {
_parent.scorepanel.music.gotoAndStop(1);
snd.sndvolon();
} else {
_parent.scorepanel.music.gotoAndStop(2);
snd.sndvoloff();
}
m_pEngine.clear();
m_car = new com.UI.Truck();
m_car.init(m_level.mcVehiclePlace, m_pEngine);
setObstruct_mc();
setPosition(true);
}
function setObstruct_mc() {
for (var _local2 in m_level.obstruct) {
m_level.obstruct[_local2].gotoAndStop(1);
}
}
function gameNewEnd() {
var _local3 = attachMovie("popup", "popup", 1002);
_local3._x = 400;
_local3._y = 300;
if (_root.currentlevel >= _root.gameLevel) {
_local3.gotoAndStop("congrats");
snd.stopSnds();
snd.playMerry();
} else {
_local3.gotoAndStop("levelup");
snd.stopSnds();
snd.playTrick();
}
trace("_root.levelscore :" + _root.levelscore);
trace("die count " + _root.dieCount);
_local3.lscore = (_root.levelscore - (_root.dieCount * 100)) + (sec * 100);
_root.gamescore1 = _root.gamescore1 + ((_root.levelscore - (_root.dieCount * 100)) + (sec * 100));
_local3.gscore = _root.gamescore1;
_parent.scorepanel._visible = false;
_parent.sbar._visible = false;
trace("_root.gamescore :" + _root.gamescore1);
trace("sec :" + sec);
clearInterval(setint);
}
function processRace() {
m_pEngine.process();
m_car.process();
setPosition();
_root.game.b._Level.coordonate_masina = m_car.__get__backWheel().pos.x;
_root.game.b._Level.coordonate_masina_y = m_car.__get__backWheel().pos.y;
if ((m_level.mcFinish._x < (m_car.__get__backWheel().pos.x - 50)) && (!inPostGame)) {
inPostGame = true;
}
var _local3 = m_car.getHitForBonus();
if (_local3.hitTest(m_level.bonus_mc)) {
i = 1;
while (i <= 10) {
if (_local3.hitTest(m_level.bonus_mc["bonus" + i])) {
if (m_level.bonus_mc["bonus" + i]._alpha != 0) {
m_level.bonus_mc["bonus" + i]._alpha = 0;
trace("bonus");
_root.levelscore = _root.levelscore + 111;
_root.game.scorepanel.gscore1 = _root.game.scorepanel.gscore1 + 111;
}
}
if (_local3.hitTest(m_level.bonus_mc["cadou" + i])) {
if (m_level.bonus_mc["cadou" + i]._alpha != 0) {
m_level.bonus_mc["cadou" + i]._alpha = 0;
trace("cadou");
_root.levelscore = _root.levelscore + 111;
_root.game.scorepanel.gscore1 = _root.game.scorepanel.gscore1 + 111;
}
}
i++;
}
}
if (_local3.hitTest(m_level.end1)) {
m_car.stopCar();
if (m_car.kids == true) {
if (kid == false) {
_root.game.b._Level.mos = true;
kid = true;
}
if (_level0.game.b._Level.copii.bla == true) {
if (gameNew == false) {
gameNewEnd();
gameNew = true;
}
}
}
if (inProcess) {
m_car.inProcess = false;
inProcess = false;
}
}
for (var i in m_level.obstruct) {
if ((_local3.hitTest(m_level.obstruct[i].mc) == true) && (inProcess)) {
m_level.obstruct[i].gotoAndPlay("die");
snd.zoombiesnd.start(0, 1);
updatescore(100);
}
}
if (inProcess && ((getTimer() - m_car.bornTime) > 200)) {
if (!inPostGame) {
if (m_car.checkDeathPoints(m_level.mcHit)) {
bodyCrash = true;
if (inProcess) {
hitcount++;
if (hitcount >= 1) {
hitcount = 0;
_parent.sbar.nextFrame();
}
if ((_parent.sbar._currentframe >= 100) || (min < 0)) {
m_car.inProcess = false;
inProcess = false;
inPostGame = true;
var _local4 = attachMovie("popup", "dieMessage", 1002);
_local4._x = 400;
_local4._y = 300;
_local4.gotoAndStop("crash");
_parent.scorepanel._visible = false;
_parent.sbar._visible = false;
_root.dieCount++;
_local4.level = _root.currentlevel;
_local4.lscore = _root.levelscore;
_root.gamescore1 = _root.gamescore1 + 0;
_local4.gscore = _root.gamescore1;
trace("gamescore :" + _root.gamescore1);
snd.stopSnds();
snd.playBlastsnd();
clearInterval(setint);
}
}
} else {
bodyCrash = false;
}
if (m_car.chkDeath(m_level.mcHit.Deathhit) || (min < 0)) {
_parent.scorepanel.timer = "00:00";
m_car.inProcess = false;
inProcess = false;
inPostGame = true;
var _local4 = attachMovie("popup", "dieMessage", 1002);
_local4.gotoAndStop("die");
_local4._x = 400;
_local4._y = 300;
_parent.scorepanel._visible = false;
_parent.sbar._visible = false;
_local4.level = _root.currentlevel;
_root.dieCount++;
_local4.lscore = _root.levelscore;
_root.gamescore1 = _root.gamescore1 + 0;
_local4.gscore = _root.gamescore1;
trace("gamescore :" + _root.gamescore1);
snd.stopSnds();
snd.playBlastsnd();
clearInterval(setint);
}
}
}
}
function updatescore(no) {
score = score + no;
_root.levelscore = score;
_parent.scorepanel.gscore = _root.gamescore;
}
function enableProcess(enable) {
if (enable) {
onEnterFrame = processRace;
_scrPause.removeMovieClip();
} else {
onEnterFrame = function () {
};
attachMovie("popup", "_scrPause", 32001);
_scrPause.gotoAndStop("pause");
_scrPause._x = 400;
_scrPause._y = 300;
}
}
function setPosition(b) {
var _local4 = m_car.__get__image()._x;
var _local3 = m_car.__get__image()._y;
var _local5 = leftOffset;
var _local6 = rightOffset;
if (!m_car.mode) {
_local5 = rightOffset;
_local6 = leftOffset;
}
var _local2 = m_level._x;
if (_local2 < (_local5 - _local4)) {
_local2 = _local5 - _local4;
}
if (_local2 > ((550 - _local6) - _local4)) {
_local2 = (550 - _local6) - _local4;
}
if (b) {
m_level._x = _local2;
} else {
m_level._x = m_level._x + ((_local2 - m_level._x) / xScrollFactor);
scen._x = scen._x + (((_local2 - m_level._x) / xScrollFactor) * 0.03);
}
if (m_level._y < (topOffset - _local3)) {
m_level._y = topOffset - _local3;
}
if (m_level._y > ((450 - bottomOffset) - _local3)) {
m_level._y = (450 - bottomOffset) - _local3;
}
}
static function get instance() {
return(m_instance);
}
function endOfLevel(n) {
if (n == 1) {
} else if (n == 2) {
}
}
var leftOffset = 200;
var rightOffset = 350;
var topOffset = 250;
var bottomOffset = 120;
var xScrollFactor = 5;
var stopArray = [7020, 7450, 7100, 11070];
var kid = false;
var gameNew = false;
var spacePressed = false;
}
Symbol 471 MovieClip [__Packages.com.ACA.DynamicsEngine] Frame 0
class com.ACA.DynamicsEngine
{
var m_particles, m_constraints, m_gravity, m_hitMovie, m_koeffDamp;
function DynamicsEngine (hitMovie, nGravity, koeffDamp) {
m_particles = new Array();
m_constraints = new Array();
setHitMovie(hitMovie);
init(nGravity, koeffDamp);
}
function set gravity(nGravity) {
m_gravity = nGravity;
//return(gravity);
}
function get gravity() {
return(m_gravity);
}
function setHitMovie(hitMovie) {
if (hitMovie == undefined) {
hitMovie = null;
}
m_hitMovie = hitMovie;
}
function getHitMovie() {
return(m_hitMovie);
}
function init(nGravity, koeffDamp) {
if (nGravity == undefined) {
nGravity = 9.8;
}
if (koeffDamp == undefined) {
koeffDamp = 0.99;
}
gravity = (nGravity);
m_koeffDamp = koeffDamp;
}
function addParticle(p) {
m_particles.push(p);
}
function process() {
var _local2 = 0;
while (_local2 < m_particles.length) {
m_particles[_local2].accelerate.plusXY(0, m_gravity * m_particles[_local2].mass);
m_particles[_local2].accelerate.mult(1 / REPEAT_COUNT);
_local2++;
}
var _local3 = 0;
while (_local3 < REPEAT_COUNT) {
_local2 = 0;
while (_local2 < m_particles.length) {
m_particles[_local2].verlet(D_TIME, m_koeffDamp);
_local2++;
}
_local2 = 0;
while (_local2 < m_constraints.length) {
m_constraints[_local2].resolve();
_local2++;
}
_local2 = 0;
while (_local2 < m_particles.length) {
m_particles[_local2].checkCollision(m_hitMovie);
_local2++;
}
_local3++;
}
_local2 = 0;
while (_local2 < m_particles.length) {
m_particles[_local2].accelerate.init(0, 0);
_local2++;
}
}
function addConstraint(c) {
m_constraints.push(c);
}
function clear() {
while (m_particles.pop() != undefined) {
}
clearConstraints();
}
function clearConstraints() {
while (m_constraints.pop() != undefined) {
}
}
static var SEC_PER_FRAME = 0.04;
static var REPEAT_COUNT = 3;
static var D_TIME = SEC_PER_FRAME / REPEAT_COUNT;
}
Symbol 472 MovieClip [__Packages.com.ACA.Vehicle] Frame 0
class com.ACA.Vehicle
{
var m_vehicleDir, m_vehicleNormal, m_vehicleParam, m_vehicleAngle, m_vehicleMovie, m_bodyMovie, m_backWheel, m_forwardWheel, m_accPercMultForTurn, m_normalYLimitForTurn, m_koeffPrimaryForTurn, m_koeffSecondaryForTurn, m_accPercBaseForTurn, m_accForwardWheel, m_accBackWheel, m_brakeForwardWheel, m_brakeBackWheel, t_turnToPerc;
function Vehicle () {
m_vehicleDir = new com.ACA.util.Vector(0, 0);
m_vehicleNormal = new com.ACA.util.Vector(0, 0);
}
function get vehicleParam() {
return(m_vehicleParam);
}
function set vehicleParam(nParam) {
m_vehicleParam = nParam;
//return(vehicleParam);
}
function get vehicleAngle() {
return(m_vehicleAngle);
}
function get vehicleDir() {
return(m_vehicleDir);
}
function getVehiclePoint(mc) {
var _local2 = new Object();
_local2.x = mc._x;
_local2.y = mc._y;
mc._parent.localToGlobal(_local2);
m_vehicleMovie._parent.globalToLocal(_local2);
return(_local2);
}
function moveMovieToMovieGlobal(movie, moviePos) {
var _local1 = {x:movie._x, y:movie._y};
movie._parent.localToGlobal(_local1);
moviePos._parent.globalToLocal(_local1);
moviePos._x = _local1.x;
moviePos._y = _local1.y;
}
function rotateMovieToMovieLocal(movie, moviePos) {
movie._rotation = Math.atan2(moviePos._y - movie._y, moviePos._x - movie._x) * VAL_180_DIV_PI;
}
function construct(vehicleParam, bodyMovie, vehicleMovie, mcWBack, mcWForward) {
m_vehicleParam = vehicleParam;
m_bodyMovie = bodyMovie;
m_vehicleMovie = vehicleMovie;
m_vehicleParam.changeGeometry(getVehiclePoint(m_bodyMovie.mcA), getVehiclePoint(m_bodyMovie.mcB), getVehiclePoint(m_bodyMovie.mcC), getVehiclePoint(m_bodyMovie.mcD));
m_backWheel = m_vehicleParam.A;
m_forwardWheel = m_vehicleParam.D;
if (mcWBack != undefined) {
m_backWheel.setMovie(mcWBack);
m_backWheel.setRotationMovie(mcWBack.mcSpoke);
}
if (mcWForward != undefined) {
m_forwardWheel.setMovie(mcWForward);
m_forwardWheel.setRotationMovie(mcWForward.mcSpoke);
}
setVehicleParam(getDefaultVehicleParam());
}
static function getDefaultVehicleParam() {
var _local1 = new Object();
_local1.accPercMult = 39.2;
_local1.normalYLimit = 0.4;
_local1.koeffPrimary = 1.3;
_local1.koeffSecondary = 0.7;
_local1.accPercBase = 0.6;
_local1.accelerateForwardWheel = 0;
_local1.accelerateBackWheel = 50;
_local1.brakeForwardWheel = 0;
_local1.brakeBackWheel = 0;
return(_local1);
}
function setVehicleParam(param) {
m_accPercMultForTurn = param.accPercMult;
m_normalYLimitForTurn = param.normalYLimit;
m_koeffPrimaryForTurn = param.koeffPrimary;
m_koeffSecondaryForTurn = param.koeffSecondary;
m_accPercBaseForTurn = param.accPercBase;
m_accForwardWheel = param.accelerateForwardWheel;
m_accBackWheel = param.accelerateBackWheel;
m_brakeForwardWheel = param.brakeForwardWheel;
m_brakeBackWheel = param.brakeBackWheel;
}
function processKey(mask) {
if ((mask & KM_ACCELERATE) != 0) {
accelerate();
} else if ((mask & KM_BRAKE) != 0) {
brake();
} else {
stopAccelerate();
}
if ((mask & KM_MOVE_BODY_FORWARD) != 0) {
turnTo(DIR_RIGHT, m_accPercMultForTurn);
} else if ((mask & KM_MOVE_BODY_BACK) != 0) {
turnTo(DIR_LEFT, m_accPercMultForTurn);
}
}
function process() {
m_vehicleDir.init(m_forwardWheel.__get__pos().x - m_backWheel.__get__pos().x, m_forwardWheel.__get__pos().y - m_backWheel.__get__pos().y);
m_vehicleNormal.init(m_vehicleDir.x, m_vehicleDir.y);
m_vehicleNormal.normalize();
var _local4 = m_vehicleNormal.x;
m_vehicleNormal.x = -m_vehicleNormal.y;
m_vehicleNormal.y = _local4;
m_vehicleAngle = Math.atan2(m_vehicleDir.y, m_vehicleDir.x) * VAL_180_DIV_PI;
m_vehicleMovie._rotation = m_vehicleAngle;
var _local3 = new Object();
_local3.x = m_bodyMovie.mcB._x;
_local3.y = m_bodyMovie.mcB._y;
m_bodyMovie.localToGlobal(_local3);
m_vehicleMovie._parent.globalToLocal(_local3);
var _local2 = new Object();
_local2.x = m_bodyMovie.mcC._x;
_local2.y = m_bodyMovie.mcC._y;
m_bodyMovie.localToGlobal(_local2);
m_vehicleMovie._parent.globalToLocal(_local2);
m_vehicleMovie._x = m_vehicleMovie._x + ((((m_vehicleParam.__get__B().__get__pos().x - _local3.x) + m_vehicleParam.__get__C().__get__pos().x) - _local2.x) / 2);
m_vehicleMovie._y = m_vehicleMovie._y + ((((m_vehicleParam.__get__B().__get__pos().y - _local3.y) + m_vehicleParam.__get__C().__get__pos().y) - _local2.y) / 2);
}
function drawSuspension() {
if (!m_vehicleMovie._parent.sus_mc) {
m_vehicleMovie._parent.createEmptyMovieClip("sus_mc", 1015);
m_vehicleMovie._parent.sus_mc._x = (m_vehicleMovie._parent.sus_mc._y = 0);
}
var _local2 = m_vehicleMovie._parent.sus_mc;
_local2.clear();
_local2.lineStyle(5, 16777215, 100);
_local2.moveTo(m_vehicleParam.__get__A().__get__pos().x, m_vehicleParam.__get__A().__get__pos().y);
_local2.lineTo(m_vehicleParam.__get__B().__get__pos().x, m_vehicleParam.__get__B().__get__pos().y);
_local2.lineTo(m_vehicleParam.__get__C().__get__pos().x, m_vehicleParam.__get__C().__get__pos().y);
_local2.lineTo(m_vehicleParam.__get__A().__get__pos().x, m_vehicleParam.__get__A().__get__pos().y);
_local2.moveTo(m_vehicleParam.__get__D().__get__pos().x, m_vehicleParam.__get__D().__get__pos().y);
_local2.lineTo(m_vehicleParam.__get__B().__get__pos().x, m_vehicleParam.__get__B().__get__pos().y);
_local2.lineTo(m_vehicleParam.__get__C().__get__pos().x, m_vehicleParam.__get__C().__get__pos().y);
_local2.lineTo(m_vehicleParam.__get__D().__get__pos().x, m_vehicleParam.__get__D().__get__pos().y);
}
function turnTo(dir, turnPower) {
t_turnToPerc = ((Math.abs(m_vehicleNormal.y) * (1 - m_accPercBaseForTurn)) + m_accPercBaseForTurn) * turnPower;
var _local3;
var _local2;
_local3 = m_vehicleNormal.x * t_turnToPerc;
_local2 = m_vehicleNormal.y * t_turnToPerc;
if (m_vehicleNormal.y > (-m_normalYLimitForTurn)) {
if (dir == DIR_RIGHT) {
if (!m_forwardWheel.hasIntersection()) {
m_forwardWheel.__get__accelerate().plusXY(_local3 * m_koeffPrimaryForTurn, _local2 * m_koeffPrimaryForTurn);
}
m_backWheel.__get__accelerate().plusXY((-_local3) * m_koeffSecondaryForTurn, (-_local2) * m_koeffSecondaryForTurn);
} else {
m_forwardWheel.__get__accelerate().plusXY((-_local3) * m_koeffSecondaryForTurn, (-_local2) * m_koeffSecondaryForTurn);
if (!m_backWheel.hasIntersection()) {
m_backWheel.__get__accelerate().plusXY(_local3 * m_koeffPrimaryForTurn, _local2 * m_koeffPrimaryForTurn);
}
}
}
}
function accelerate() {
if (!m_vehicleMovie._parent._parent._parent.bodyCrash) {
m_backWheel.setAccelerate(m_accBackWheel);
m_forwardWheel.setAccelerate(m_accForwardWheel);
}
}
function brake() {
if (!m_vehicleMovie._parent._parent._parent.bodyCrash) {
m_backWheel.setAccelerate(m_brakeBackWheel);
m_forwardWheel.setAccelerate(m_brakeForwardWheel);
}
}
function stopAccelerate() {
m_backWheel.setAccelerate(0);
m_forwardWheel.setAccelerate(0);
}
function get backWheel() {
return(m_backWheel);
}
function get forwardWheel() {
return(m_forwardWheel);
}
function onGround() {
return(m_backWheel.hasIntersection() || (m_forwardWheel.hasIntersection()));
}
static var VAL_180_DIV_PI = 57.2957795130823;
static var DIR_RIGHT = 0;
static var DIR_LEFT = 1;
static var KM_NONE = 0;
static var KM_ACCELERATE = 1;
static var KM_BRAKE = 2;
static var KM_MOVE_BODY_FORWARD = 4;
static var KM_MOVE_BODY_BACK = 8;
}
Symbol 473 MovieClip [__Packages.com.ACA.util.Vector] Frame 0
class com.ACA.util.Vector
{
var x, y;
function Vector (nx, ny) {
init(nx, ny);
}
function init(nx, ny) {
x = nx;
y = ny;
}
function copyFrom(v) {
x = v.x;
y = v.y;
}
function copyTo(v) {
v.x = x;
v.y = y;
}
function plusXY(nx, ny) {
x = x + nx;
y = y + ny;
}
static function getDistanceBetween(p1, p2) {
var _local2 = p1.x - p2.x;
var _local1 = p1.y - p2.y;
return(Math.sqrt((_local2 * _local2) + (_local1 * _local1)));
}
function duplicate() {
return(new com.ACA.util.Vector(x, y));
}
function minus(v) {
x = x - v.x;
y = y - v.y;
}
function minusNew(v) {
return(new com.ACA.util.Vector(x - v.x, y - v.y));
}
function normalize() {
var _local2 = Math.sqrt((x * x) + (y * y));
x = x / _local2;
y = y / _local2;
}
function reverseNew() {
return(new com.ACA.util.Vector(-x, -y));
}
function scalar(v) {
return((x * v.x) + (y * v.y));
}
function modul() {
return(Math.sqrt((x * x) + (y * y)));
}
function rotate(u) {
var _local4 = x;
var _local3 = y;
x = (_local4 * Math.cos(u)) - (_local3 * Math.sin(u));
y = (_local4 * Math.sin(u)) + (_local3 * Math.cos(u));
}
function rotateNew(u) {
return(new com.ACA.util.Vector((x * Math.cos(u)) - (y * Math.sin(u)), (x * Math.sin(u)) + (y * Math.cos(u))));
}
function mult(k) {
x = x * k;
y = y * k;
return(this);
}
function multNew(k) {
return(new com.ACA.util.Vector(x * k, y * k));
}
function plus(v) {
x = x + v.x;
y = y + v.y;
}
function plusNew(v) {
return(new com.ACA.util.Vector(x + v.x, y + v.y));
}
function getDistanceTo(p1, p2) {
var _local2 = p1.y - p2.y;
var _local3 = p2.x - p1.x;
var _local5 = (p1.x * (p2.y - p1.y)) - (p1.y * (p2.x - p1.x));
var _local6 = Math.sqrt((_local2 * _local2) + (_local3 * _local3));
_local2 = _local2 / _local6;
_local3 = _local3 / _local6;
_local5 = _local5 / _local6;
return(((_local2 * x) + (_local3 * y)) + _local5);
}
}
Symbol 474 MovieClip [__Packages.com.ACA.composites.Composite] Frame 0
class com.ACA.composites.Composite
{
var m_A, m_B, m_C, m_D, m_AB, m_AC, m_AD, m_BC, m_BD, m_CD, m_ABC, m_DCB;
function Composite () {
}
function get A() {
return(m_A);
}
function get B() {
return(m_B);
}
function get C() {
return(m_C);
}
function get D() {
return(m_D);
}
function get AB() {
return(m_AB);
}
function get AC() {
return(m_AC);
}
function get AD() {
return(m_AD);
}
function get BC() {
return(m_BC);
}
function get BD() {
return(m_BD);
}
function get CD() {
return(m_CD);
}
function init(a, b, c, d, ab, ac, ad, bc, bd, cd) {
m_A = a;
m_B = b;
m_C = c;
m_D = d;
m_AB = ab;
m_AB.__set__p1(a);
m_AB.__set__p2(b);
m_AC = ac;
m_AC.__set__p1(a);
m_AC.__set__p2(c);
m_AD = ad;
m_AD.__set__p1(a);
m_AD.__set__p2(d);
m_BC = bc;
m_BC.__set__p1(b);
m_BC.__set__p2(c);
m_BD = bd;
m_BD.__set__p1(b);
m_BD.__set__p2(d);
m_CD = cd;
m_CD.__set__p1(c);
m_CD.__set__p2(d);
m_ABC = new com.ACA.constraints.AngularConstraint(m_D, m_C, m_B);
m_DCB = new com.ACA.constraints.AngularConstraint(m_A, m_B, m_C);
return(this);
}
function changeGeometry(pA, pB, pC, pD) {
m_A.moveTo(pA.x, pA.y);
m_B.moveTo(pB.x, pB.y);
m_C.moveTo(pC.x, pC.y);
m_D.moveTo(pD.x, pD.y);
m_AB.fixDistance();
m_AC.fixDistance();
m_AD.fixDistance();
m_BC.fixDistance();
m_BD.fixDistance();
m_CD.fixDistance();
m_ABC.fixDistance();
m_DCB.fixDistance();
}
function addToEngine(engine) {
engine.addParticle(m_A);
engine.addParticle(m_B);
engine.addParticle(m_C);
engine.addParticle(m_D);
engine.addConstraint(m_AB);
engine.addConstraint(m_AC);
engine.addConstraint(m_AD);
engine.addConstraint(m_BC);
engine.addConstraint(m_BD);
engine.addConstraint(m_CD);
engine.addConstraint(m_ABC);
engine.addConstraint(m_DCB);
}
}
Symbol 475 MovieClip [__Packages.com.ACA.primitives.Particle] Frame 0
class com.ACA.primitives.Particle
{
var m_curPosition, m_prevPosition, m_accelerate, m_buckup, m_mass, m_mc;
function Particle () {
m_curPosition = new com.ACA.util.Vector();
m_prevPosition = new com.ACA.util.Vector();
m_accelerate = new com.ACA.util.Vector();
m_buckup = new com.ACA.util.Vector();
}
function get mass() {
return(m_mass);
}
function set mass(nMass) {
m_mass = nMass;
//return(mass);
}
function get accelerate() {
return(m_accelerate);
}
function set accelerate(acc) {
m_accelerate = acc;
//return(accelerate);
}
function get prevPos() {
return(m_prevPosition);
}
function set prevPos(pos) {
m_prevPosition = pos;
//return(prevPos);
}
function get pos() {
return(m_curPosition);
}
function set pos(pos) {
m_curPosition = pos;
//return(this.pos);
}
function initParticle(x, y, mass, mc) {
if (x == undefined) {
x = 0;
}
if (y == undefined) {
y = 0;
}
if (mass == undefined) {
mass = 1;
}
moveTo(x, y);
m_mass = mass;
m_accelerate.x = 0;
m_accelerate.y = 0;
if (mc) {
setMovie(mc);
}
return(this);
}
function moveTo(nx, ny) {
m_curPosition.x = (m_prevPosition.x = nx);
m_curPosition.y = (m_prevPosition.y = ny);
synchronizeMovie();
}
function verlet(dTime, koeffDamp) {
m_buckup.copyFrom(m_curPosition);
m_curPosition.x = m_curPosition.x + (((m_curPosition.x - m_prevPosition.x) * koeffDamp) + (m_accelerate.x * dTime));
m_curPosition.y = m_curPosition.y + (((m_curPosition.y - m_prevPosition.y) * koeffDamp) + (m_accelerate.y * dTime));
m_buckup.copyTo(m_prevPosition);
synchronizeMovie();
}
function checkCollision(hitMovie) {
}
function synchronizeMovie() {
}
function moveMovieToCurentPosition() {
m_mc._x = m_curPosition.x;
m_mc._y = m_curPosition.y;
}
function setMovie(mc) {
if ((mc == null) || (mc == undefined)) {
synchronizeMovie = function () {
};
m_mc = null;
} else {
m_mc = mc;
synchronizeMovie = moveMovieToCurentPosition;
}
}
function getMovie() {
return(m_mc);
}
}
Symbol 476 MovieClip [__Packages.com.ACA.primitives.Wheel] Frame 0
class com.ACA.primitives.Wheel extends com.ACA.primitives.Particle
{
var m_rim, rot, m_radius, m_speed, m_acceleration, initParticle, m_koeffSpring, m_koeffSlip, m_maxAccSpeed, m_accSpeed, intersectionFlag, lastIntersPoint, lastN, hitPointArray, normalArray, hitArray, intersArray, n_part, oldPos, _p, _n, p3, m_prevPosition, synchronizeMovie, m_mc, m_curPosition;
function Wheel () {
super();
}
function setRotationMovie(rotationMovie) {
if ((rotationMovie == undefined) || (rotationMovie == null)) {
rotateMovie = function () {
};
m_rim = null;
} else {
rotateMovie = rmovie;
m_rim = rotationMovie;
}
}
function rmovie() {
rot.rotate(m_speed / m_radius);
m_rim._rotation = Math.atan2(rot.y, rot.x) * ANGLE_180_DIV_PI;
}
function setAccelerate(nAccelerate) {
m_acceleration = nAccelerate;
}
function getAccelerate() {
return(m_acceleration);
}
function initWheel(x, y, mass, rad, maxAccSpeed, mc, rotationMovie, koeffSpring, koeffSlip) {
_innerInit();
initParticle(x, y, mass, mc);
if (koeffSpring == undefined) {
koeffSpring = 0.1;
}
if (koeffSlip == undefined) {
koeffSlip = 0.1;
}
m_koeffSpring = koeffSpring;
m_koeffSlip = koeffSlip;
setRotationMovie(rotationMovie);
m_radius = rad;
m_maxAccSpeed = maxAccSpeed;
m_speed = 0;
m_accSpeed = 0;
rot = new com.ACA.util.Vector(1, 0);
intersectionFlag = false;
lastIntersPoint = new com.ACA.util.Vector(0, 0);
lastN = new com.ACA.util.Vector(0, 0);
var _local3 = (Math.PI*2) / m_hitCount;
hitPointArray = new Array(m_hitCount);
normalArray = new Array(m_hitCount);
hitArray = new Array(m_hitCount);
intersArray = new Array();
var _local2 = 0;
while (_local2 < m_hitCount) {
hitPointArray[_local2] = new com.ACA.util.Vector(Math.sin(_local3 * _local2) * m_radius, (-Math.cos(_local3 * _local2)) * m_radius);
normalArray[_local2] = hitPointArray[_local2].multNew(-1);
normalArray[_local2].normalize();
_local2++;
}
m_acceleration = 0;
return(this);
}
function verlet(dTime, koeffDamp) {
super.verlet(dTime, koeffDamp);
m_accSpeed = Math.max(-m_maxAccSpeed, Math.min(m_maxAccSpeed, m_accSpeed + (m_acceleration * dTime)));
m_speed = Math.max((-m_maxSpeed) * dTime, Math.min((m_speed * koeffDamp) + m_accSpeed, m_maxSpeed * dTime));
rotateMovie();
}
function rotateMovie() {
}
function _innerInit() {
n_part = new com.ACA.util.Vector(0, 0);
oldPos = new com.ACA.util.Vector(0, 0);
_p = new com.ACA.util.Vector(0, 0);
_n = new com.ACA.util.Vector(0, 0);
p3 = new com.ACA.util.Vector(0, 0);
}
function checkCollision(hit_mc) {
var _local14 = false;
var _local3 = 0;
var _local4 = 0;
var _local15 = 0;
_p.init(0, 0);
oldPos.init(m_prevPosition.x, m_prevPosition.y);
_n.init(0, 0);
n_part.init(0, 0);
synchronizeMovie();
var _local6 = 0;
while (_local6 < m_hitCount) {
hitPointArray[_local6].copyTo(_p);
m_mc.localToGlobal(_p);
hitArray[_local6] = hit_mc.hitTest(_p.x, _p.y, true);
if (hitArray[_local6]) {
_local14 = true;
_local3 = _local6;
_local15++;
}
_local6++;
}
if (_local15 == m_hitCount) {
m_curPosition.x = m_prevPosition.x + ((m_curPosition.x - m_prevPosition.x) * 0.3);
m_curPosition.y = m_prevPosition.y + ((m_curPosition.y - m_prevPosition.y) * 0.3);
synchronizeMovie();
return(undefined);
}
if (_local14) {
var _local2 = 0;
while (true) {
_local2++;
if (_local2 == m_hitCount) {
_local2 = 0;
}
if (!hitArray[_local2]) {
_local3 = -1;
var _local5 = 0;
while (_local5 < m_hitCount) {
_local2++;
if (_local2 == m_hitCount) {
_local2 = 0;
}
if (_local3 == -1) {
if (hitArray[_local2]) {
_local3 = _local2;
_n.plus(normalArray[_local2]);
normalArray[_local2].copyTo(n_part);
}
} else if (!hitArray[_local2]) {
_local4 = _local2 - 1;
if (_local4 < 0) {
_local4 = m_hitCount - 1;
}
intersArray.push({k1:_local3, k2:_local4, n:new com.ACA.util.Vector(n_part.x, n_part.y)});
_local3 = -1;
} else {
_n.plus(normalArray[_local2]);
n_part.plus(normalArray[_local2]);
}
_local5++;
}
break;
}
}
p3.init(0, 0);
if (intersArray.length > 0) {
_n.normalize();
if (intersectionFlag) {
_n.x = _n.x + lastN.x;
_n.y = _n.y + lastN.y;
_n.x = _n.x / 2;
_n.y = _n.y / 2;
}
var _local16 = intersArray.length;
var _local7;
var _local10 = 0;
while (_local10 < _local16) {
_local7 = intersArray.pop();
_local3 = _local7.k1;
_local4 = _local7.k2;
_local7.n.copyTo(n_part);
m_curPosition.minusNew(m_prevPosition).copyTo(p3);
if (_n.scalar(p3) < 0) {
var _local12 = Math.atan2(_n.y, _n.x);
p3.rotate(-_local12);
p3.x = (-p3.x) * m_koeffSpring;
p3.rotate(_local12);
pushOut(_local3, _local4, n_part, hit_mc);
m_prevPosition.x = m_curPosition.x - p3.x;
m_prevPosition.y = m_curPosition.y - p3.y;
} else {
pushOut(_local3, _local4, n_part, hit_mc);
}
_local10++;
}
validateRotation(_n, oldPos);
intersectionFlag = true;
m_curPosition.copyTo(lastIntersPoint);
_n.copyTo(lastN);
}
} else if (intersectionFlag) {
validateRotation(lastN, oldPos);
intersectionFlag = false;
}
synchronizeMovie();
}
function pushOut(k1, k2, n, hit_mc) {
n.normalize();
if (k1 != k2) {
var _local9 = new com.ACA.util.Vector(0, 0);
var _local8 = _local9.getDistanceTo(hitPointArray[k1], hitPointArray[k2]);
_local8 = m_radius - Math.abs(_local8);
m_curPosition.plus(n.multNew(_local8));
m_prevPosition.plus(n.multNew(_local8));
} else {
var _local6 = n.multNew(-m_radius);
var _local4 = new com.ACA.util.Vector(0, 0);
var _local5 = 0;
var _local3 = 0.03;
if (true) {
_local6.copyTo(_local4);
m_mc.localToGlobal(_local4);
if (hit_mc.hitTest(_local4.x, _local4.y, true)) {
_local5++;
m_curPosition.x = m_curPosition.x + (n.x * _local3);
m_curPosition.y = m_curPosition.y + (n.y * _local3);
synchronizeMovie();
// unexpected jump
}
_local5--;
m_curPosition.x = m_curPosition.x - (n.x * _local3);
m_curPosition.y = m_curPosition.y - (n.y * _local3);
m_prevPosition.plus(n.multNew(_local3 * _local5));
}
}
}
function validateRotation(n, oldPos) {
if ((!intersectionFlag) && (Math.abs(m_accSpeed) > 0.01)) {
if (Math.abs(m_accSpeed) < ((m_maxAccSpeed * 0.02) / 2)) {
m_accSpeed = 0;
} else if (m_accSpeed > 0) {
m_accSpeed = m_maxAccSpeed * 0.02;
} else {
m_accSpeed = (-m_maxAccSpeed) * 0.02;
}
}
var _local3 = new com.ACA.util.Vector(-n.y, n.x);
var _local6 = m_curPosition.minusNew(oldPos);
var _local5 = Math.atan2(_local3.y, _local3.x);
var _local2 = _local6.rotateNew(-_local5);
m_speed = _local2.x + m_accSpeed;
_local2.y = 0;
_local2.rotate(_local5);
var _local4 = 1 - m_koeffSlip;
m_curPosition.x = (m_curPosition.x + ((_local3.x * m_accSpeed) * _local4)) - (m_koeffFriction * _local2.x);
m_curPosition.y = (m_curPosition.y + ((_local3.y * m_accSpeed) * _local4)) - (m_koeffFriction * _local2.y);
m_accSpeed = m_accSpeed * m_koeffSlip;
}
function hasIntersection() {
return(intersectionFlag);
}
static var m_maxSpeed = 180;
static var m_hitCount = 16;
static var m_koeffFriction = 0.03;
static var ANGLE_180_DIV_PI = 57.2957795130823;
}
Symbol 477 MovieClip [__Packages.com.ACA.constraints.SpringConstraint] Frame 0
class com.ACA.constraints.SpringConstraint
{
var _p1, _p2, coeffV, coeffH, restLen;
function SpringConstraint () {
}
function set p1(nP1) {
_p1 = nP1;
//return(p1);
}
function get p1() {
return(_p1);
}
function set p2(nP2) {
_p2 = nP2;
//return(p2);
}
function get p2() {
return(_p2);
}
function init(cV, cH, p1, p2) {
if (p1) {
_p1 = p1;
_p2 = p2;
}
if (cV) {
coeffV = cV;
coeffH = cH;
}
fixDistance();
return(this);
}
function fixDistance() {
restLen = com.ACA.util.Vector.getDistanceBetween(_p1.__get__pos(), _p2.__get__pos());
}
function resolve() {
var _local9 = _p1.__get__pos().minusNew(_p2.__get__pos());
var _local2 = com.ACA.util.Vector.getDistanceBetween(_p1.__get__pos(), _p2.__get__pos());
var _local8 = (_local2 - restLen) / _local2;
var _local3;
if (_local2 > restLen) {
_local3 = coeffH;
} else {
_local3 = coeffV;
}
var _local6 = _p1.__get__mass();
var _local5 = _p2.__get__mass();
var _local7 = (_local8 * _local3) / (_local6 + _local5);
var _local4 = _local9.multNew(_local7);
_p1.__get__pos().minus(_local4.multNew(_local6));
_p2.__get__pos().plus(_local4.multNew(_local5));
}
}
Symbol 478 MovieClip [__Packages.com.ACA.constraints.AngularConstraint] Frame 0
class com.ACA.constraints.AngularConstraint
{
var p0, p1, p2, sign;
function AngularConstraint (np0, np1, np2) {
p0 = np0;
p1 = np1;
p2 = np2;
fixDistance();
}
function fixDistance() {
sign = p0.__get__pos().getDistanceTo(p1.__get__pos(), p2.__get__pos());
if (sign < 0) {
sign = -1;
} else {
sign = 1;
}
}
function resolve() {
var _local3 = p0.__get__pos().getDistanceTo(p1.__get__pos(), p2.__get__pos());
if ((sign * _local3) <= 1) {
var _local2 = new com.ACA.util.Vector(p2.__get__pos().x, p2.__get__pos().y);
_local2.minus(p1.__get__pos());
_local2.normalize();
_local2.rotate(PI2 * sign);
_local2.mult(Math.abs(_local3) + 1);
p1.__get__pos().minus(_local2);
}
}
static var PI2 = (Math.PI/2);
}
Symbol 479 MovieClip [__Packages.com.UI.Truck] Frame 0
class com.UI.Truck extends com.ACA.Vehicle
{
var bornTime, inProcess, mode, getKeys, snd1, m_vehicleMovie, flipTime, construct, setVehicleParam, m_forwardWheel, m_backWheel, processKey;
function Truck () {
super();
bornTime = getTimer();
inProcess = true;
mode = true;
getKeys = true;
snd1 = com.sound.CSound.instance;
}
function get image() {
return(m_vehicleMovie);
}
function init(carPlace, engine) {
flipTime = getTimer();
if (carPlace.xx == undefined) {
carPlace.xx = carPlace._x;
}
if (carPlace.yy == undefined) {
carPlace.yy = carPlace._y;
}
carPlace._x = (carPlace._y = 0);
var _local4 = carPlace.attachMovie("truckbody", "_dmCarBody", 100);
var _local15 = carPlace.attachMovie("wheel", "_dmWheel1", 1010);
var _local12 = carPlace.attachMovie("wheel", "_dmWheel2", 1020);
_local4._x = carPlace.xx;
_local4._y = carPlace.yy;
_local4._y = 700;
_local4.copii._visible = false;
var _local16 = new com.ACA.primitives.Wheel();
var _local13 = new com.ACA.primitives.Wheel();
var _local10 = new com.ACA.primitives.Particle();
var _local9 = new com.ACA.primitives.Particle();
var _local8 = new com.ACA.constraints.SpringConstraint();
var _local7 = new com.ACA.constraints.SpringConstraint();
var _local6 = new com.ACA.constraints.SpringConstraint();
var _local18 = new com.ACA.constraints.SpringConstraint();
var _local17 = new com.ACA.constraints.SpringConstraint();
var _local14 = new com.ACA.constraints.SpringConstraint();
var _local5 = new com.ACA.composites.Composite();
_local5.init(_local16.initWheel(0, 0, 5, 20, 20), _local10.initParticle(0, 0, 15), _local9.initParticle(0, 0, 15), _local13.initWheel(0, 0, 5, 20, 20), _local8.init(0.3, 0.3), _local7.init(0.5, 0.5), _local6.init(0.7, 0.7), _local18.init(0.9, 0.9), _local17.init(0.5, 0.5), _local14.init(0.3, 0.3));
construct(_local5, _local4, _local4, _local15, _local12);
engine.__set__gravity(7);
var _local3 = com.ACA.Vehicle.getDefaultVehicleParam();
_local3.accelerateForwardWheel = 33;
_local3.accelerateBackWheel = 38;
_local3.brakeForwardWheel = -10;
_local3.brakeBackWheel = -20;
_local3.accPercMult = engine.__get__gravity() * 6;
_local3.normalYLimit = 0.9;
setVehicleParam(_local3);
_local5.addToEngine(engine);
}
function stopCar() {
if (m_forwardWheel.m_speed > 1) {
kids = false;
m_backWheel.setAccelerate(-10);
m_forwardWheel.setAccelerate(-10);
} else {
kids = true;
}
}
function showKids() {
trace(m_vehicleMovie.copii);
m_vehicleMovie.copii._visible = true;
m_vehicleMovie.copii.play();
}
function process() {
var _local3 = 0;
if (inProcess) {
if (!m_vehicleMovie._parent._parent._parent.bodyCrash) {
if (getKeys) {
if (Key.isDown(37)) {
_local3 = _local3 | com.ACA.Vehicle.KM_MOVE_BODY_BACK;
} else if (Key.isDown(39)) {
_local3 = _local3 | com.ACA.Vehicle.KM_MOVE_BODY_FORWARD;
}
}
if (Key.isDown(38)) {
_local3 = _local3 | com.ACA.Vehicle.KM_ACCELERATE;
} else if (Key.isDown(40)) {
_local3 = _local3 | com.ACA.Vehicle.KM_BRAKE;
}
_level0.game.bg_level.back_mc.stop();
} else if (Key.isDown(38) && (Key.isDown(37))) {
moveFor();
} else if (Key.isDown(38) && (Key.isDown(39))) {
moveBack();
}
}
processKey(_local3);
super.process();
}
function moveFor() {
m_backWheel.__get__accelerate().plusXY(0, -100);
}
function moveBack() {
m_forwardWheel.__get__accelerate().plusXY(0, -100);
}
function getMC() {
return(m_vehicleMovie);
}
function getHitForBonus() {
return(m_vehicleMovie.mcHit);
}
function checkDeathPoints(hitMov) {
var _local2 = new Object();
for (var _local4 in m_vehicleMovie.mcDeathPoints) {
_local2.x = m_vehicleMovie.mcDeathPoints[_local4]._x;
_local2.y = m_vehicleMovie.mcDeathPoints[_local4]._y;
m_vehicleMovie.mcDeathPoints.localToGlobal(_local2);
if (hitMov.hitTest(_local2.x, _local2.y, true)) {
return(true);
}
}
return(false);
}
function chkDeath(ht) {
var _local2 = new Object();
for (var _local4 in m_vehicleMovie.mcDeathPoints) {
_local2.x = m_vehicleMovie.mcDeathPoints[_local4]._x;
_local2.y = m_vehicleMovie.mcDeathPoints[_local4]._y;
m_vehicleMovie.mcDeathPoints.localToGlobal(_local2);
if (ht.hitTest(_local2.x, _local2.y, true)) {
return(true);
}
}
return(false);
}
static var TRICK_ANGLE = 130;
static var EVENT_TRICK = "trick";
static var TRICK_FRONT_FLIP = 0;
static var TRICK_BACK_FLIP = 1;
var kids = false;
}
Symbol 106 MovieClip Frame 1
stop();
Symbol 107 MovieClip Frame 1
stop();
Symbol 111 MovieClip Frame 1
stop();
Symbol 117 MovieClip Frame 1
stop();
Symbol 123 MovieClip Frame 1
stop();
Symbol 124 MovieClip Frame 1
stop();
Symbol 125 MovieClip Frame 1
stop();
Symbol 126 MovieClip Frame 1
stop();
Symbol 127 MovieClip Frame 1
stop();
Symbol 129 MovieClip Frame 1
ren2.gotoAndStop(2);
ren3.gotoAndStop(2);
ren4.gotoAndStop(2);
ren5.gotoAndStop(2);
ren6.gotoAndStop(2);
ren9.gotoAndStop(2);
Symbol 129 MovieClip Frame 5
ren1.gotoAndStop(2);
Symbol 129 MovieClip Frame 10
ren2.gotoAndStop(1);
ren1.gotoAndStop(1);
Symbol 129 MovieClip Frame 15
ren2.gotoAndStop(2);
ren3.gotoAndStop(1);
ren4.gotoAndStop(1);
Symbol 129 MovieClip Frame 20
ren3.gotoAndStop(2);
ren4.gotoAndStop(2);
ren5.gotoAndStop(1);
ren6.gotoAndStop(1);
Symbol 129 MovieClip Frame 25
ren5.gotoAndStop(2);
ren6.gotoAndStop(2);
ren8.gotoAndStop(1);
Symbol 129 MovieClip Frame 30
ren8.gotoAndStop(2);
ren9.gotoAndStop(1);
Symbol 129 MovieClip Frame 35
ren10.gotoAndStop(2);
ren9.gotoAndStop(2);
Symbol 129 MovieClip Frame 40
ren10.gotoAndStop(1);
Symbol 160 MovieClip Frame 1
stop();
Symbol 160 MovieClip Frame 20
gotoAndPlay (2);
Symbol 162 MovieClip Frame 1
stop();
Symbol 162 MovieClip Frame 43
stop();
_root.gotoAndStop("game");
Symbol 167 MovieClip Frame 1
k = 0;
while (k < 50) {
duplicateMovieClip (this.snow, "snow" + k, k);
k++;
}
Instance of Symbol 166 MovieClip "snow" in Symbol 167 MovieClip Frame 1
onClipEvent (load) {
movieWidth = 450;
movieHeight = 600;
rad = 0;
i = 1 + (Math.random() * 2);
k = -3.14159265358979 + (Math.random() * Math.PI);
this._xscale = (this._yscale = 50 + (Math.random() * 100));
this._alpha = 70 + (Math.random() * 100);
this._x = -10 + (Math.random() * movieWidth);
this._y = -10 + (Math.random() * movieHeight);
}
onClipEvent (enterFrame) {
rad = rad + ((k / 180) * Math.PI);
this._x = this._x - Math.abs(Math.cos(rad));
this._y = this._y + i;
this._rotation = this._rotation + (Math.random() * 5);
if (this._y >= movieHeight) {
this._y = -5;
}
if ((this._x >= movieWidth) || (this._x <= 0)) {
this._x = -10 + (Math.random() * movieWidth);
this._y = -5;
}
}
Symbol 209 Button
on (release) {
getURL ("http://www.101cargames.com", "_blank");
}
Symbol 210 Button
on (release) {
trace(this);
_root.gamescore = _root.gamescore - _root.levelscore;
_parent._parent._parent.removeMovieClip();
_root.gotoAndStop("start");
}
Instance of Symbol 204 MovieClip in Symbol 215 MovieClip Frame 20
on (release) {
getURL ("http://www.101cargames.com", "_blank");
}
Instance of Symbol 208 MovieClip in Symbol 215 MovieClip Frame 20
on (release) {
_root.gamescore = _root.gamescore - _root.levelscore;
_parent._parent.removeMovieClip();
_root.gotoAndStop("start");
}
Symbol 215 MovieClip Frame 31
stop();
Symbol 218 Button
on (release) {
_root.gamescore = _root.gamescore - _root.levelscore;
_parent._parent.removeMovieClip();
_root.gotoAndStop("start");
}
Symbol 220 Button
on (release) {
getURL ("http://www.101cargames.com", "_blank");
}
Symbol 229 MovieClip Frame 1
ren2.gotoAndStop(2);
ren3.gotoAndStop(2);
ren4.gotoAndStop(2);
ren5.gotoAndStop(2);
ren6.gotoAndStop(2);
ren9.gotoAndStop(2);
Symbol 229 MovieClip Frame 5
ren1.gotoAndStop(2);
Symbol 229 MovieClip Frame 10
ren2.gotoAndStop(1);
ren1.gotoAndStop(1);
Symbol 229 MovieClip Frame 15
ren2.gotoAndStop(2);
ren3.gotoAndStop(1);
ren4.gotoAndStop(1);
Symbol 229 MovieClip Frame 20
ren3.gotoAndStop(2);
ren4.gotoAndStop(2);
ren5.gotoAndStop(1);
ren6.gotoAndStop(1);
Symbol 229 MovieClip Frame 25
ren5.gotoAndStop(2);
ren6.gotoAndStop(2);
ren8.gotoAndStop(1);
Symbol 229 MovieClip Frame 30
ren8.gotoAndStop(2);
ren9.gotoAndStop(1);
Symbol 229 MovieClip Frame 35
ren10.gotoAndStop(2);
ren9.gotoAndStop(2);
Symbol 229 MovieClip Frame 40
ren10.gotoAndStop(1);
Symbol 232 Button
on (release) {
_root.dieCount = 0;
_root.gamescore1 = 0;
_root.currentlevel = 1;
trace(_parent._parent);
trace(this);
_parent._parent.removeMovieClip();
_root.gotoAndStop("start");
}
Symbol 233 Button
on (release) {
_root.dieCount = 0;
_root.gamescore1 = 0;
_root.currentlevel = 1;
trace(_parent._parent);
trace(this);
_parent._parent.removeMovieClip();
_root.gotoAndStop("start");
}
Symbol 251 Button
on (release) {
getURL ("http://www.101cargames.com", "_blank");
}
Symbol 255 Button
on (release) {
_root.dieCount = 0;
_root.currentlevel++;
_parent._parent._parent.removeMovieClip();
_root.gotoAndStop("start");
}
Symbol 257 MovieClip Frame 1
k = 0;
while (k < 50) {
duplicateMovieClip (this.snoww, "snoww" + k, k);
k++;
}
Instance of Symbol 166 MovieClip "snoww" in Symbol 257 MovieClip Frame 1
onClipEvent (load) {
var time = 200;
var a = 10;
movieWidth = 1000;
movieHeight = 600;
rad = 0;
i = 1 + (Math.random() * 2);
k = -3.14159265358979 + (Math.random() * Math.PI);
this._xscale = (this._yscale = 50 + (Math.random() * 100));
this._alpha = 70 + (Math.random() * 100);
this._x = -10 + (Math.random() * movieWidth);
this._y = -10 + (Math.random() * movieHeight);
}
onClipEvent (enterFrame) {
if (_root.currentlevel == 1) {
rad = rad + ((k / 180) * Math.PI);
this._x = this._x - Math.abs(Math.cos(rad));
this._y = this._y + i;
}
if (_root.currentlevel == 2) {
rad = rad + ((k / 180) * Math.PI);
this._x = this._x - (8 * Math.abs(Math.cos(rad)));
this._y = this._y + (5 * i);
}
if (_root.currentlevel == 3) {
time--;
if (time == 0) {
time = 200;
if (a == 10) {
a = -10;
} else {
a = 10;
}
}
rad = rad + ((k / 180) * Math.PI);
this._x = this._x - (a * Math.abs(Math.cos(rad)));
this._y = this._y + (5 * i);
}
this._rotation = this._rotation + (Math.random() * 5);
if (this._y >= movieHeight) {
this._y = -5;
}
if ((this._x >= movieWidth) || (this._x <= 0)) {
this._x = -10 + (Math.random() * movieWidth);
this._y = -5;
}
}
Symbol 261 Button
on (press) {
_root.game.b.pauseOn = true;
}
Symbol 287 MovieClip Frame 1
stop();
gotoAndStop(_root.currentlevel);
Symbol 288 MovieClip Frame 64
stop();
Symbol 292 MovieClip Frame 1
stop();
Symbol 292 MovieClip Frame 20
stop();
Symbol 326 MovieClip Frame 1
stop();
Symbol 326 MovieClip Frame 20
stop();
Symbol 327 MovieClip [popup] Frame 1
stop();
more_btn.onRelease = function () {
getURL ("http://www.101cargames.com", "_blank");
};
more_btn.onRollOver = function () {
more_btn.gotoAndPlay("over");
};
more_btn.onRollOut = function () {
more_btn.gotoAndPlay("out");
};
Symbol 327 MovieClip [popup] Frame 10
stop();
Symbol 327 MovieClip [popup] Frame 20
textFinal._alpha = 0;
stop();
var xScaleT = (new mx.transitions.Tween(greatJob, "_rotation", mx.transitions.easing.Elastic.easeOut, 0, 360, 3, true));
xScaleT.onMotionFinished = function () {
var _local2 = new mx.transitions.Tween(greatJob, "_y", mx.transitions.easing.Elastic.easeOut, greatJob._y, -255, 2, true);
var _local1 = new mx.transitions.Tween(textFinal, "_alpha", mx.transitions.easing.Regular.easeIn, 0, 100, 1, true);
var _local6 = new mx.transitions.Tween(glob1, "_rotation", mx.transitions.easing.Elastic.easeOut, 0, 360, 5, true);
var _local5 = new mx.transitions.Tween(glob1, "_x", mx.transitions.easing.Elastic.easeOut, glob1._x, -137.1, 5, true);
var _local4 = new mx.transitions.Tween(glob2, "_rotation", mx.transitions.easing.Elastic.easeOut, 360, 0, 5, true);
var _local3 = new mx.transitions.Tween(glob2, "_x", mx.transitions.easing.Elastic.easeOut, glob2._x, 51, 5, true);
};
var se = _root.game.scorepanel.timer;
var s = se.split(":")[1];
lscore = (_root.levelscore - (_root.dieCount * 100)) + (Number(s) * 100);
gscore = _root.gamescore1;
Symbol 327 MovieClip [popup] Frame 29
stop();
Symbol 327 MovieClip [popup] Frame 30
stop();
glob_stanga.gotoAndPlay(70);
more_btn.onRelease = function () {
getURL ("http://www.101cargames.com", "_blank");
};
Symbol 327 MovieClip [popup] Frame 41
stop();
crash.play();
Instance of Symbol 326 MovieClip in Symbol 327 MovieClip [popup] Frame 50
on (press) {
_root.game.b.pauseOn = false;
}
Symbol 336 MovieClip Frame 1
stop();
trace("back" + this);
Symbol 336 MovieClip Frame 1000
stop();
Symbol 338 MovieClip Frame 1000
stop();
Symbol 344 MovieClip Frame 1000
stop();
Symbol 348 MovieClip Frame 1
onEnterFrame = function () {
gotoAndStop(_root.currentlevel);
};
Symbol 354 MovieClip [bg] Frame 1
#initclip 17
Object.registerClass("bg", com.UI.Game);
#endinitclip
Instance of Symbol 353 MovieClip "hitspace" in Symbol 354 MovieClip [bg] Frame 1
onClipEvent (load) {
_visible = false;
}
Symbol 360 MovieClip Frame 1
stop();
Symbol 374 MovieClip Frame 1
stop();
Symbol 375 MovieClip Frame 1
stop();
init();
trace("game_game" + this);
more_btn.onRelease = function () {
getURL ("http://www.101cargames.com", "_blank");
};
more_btn.onRollOver = function () {
more_btn.gotoAndPlay("over");
};
more_btn.onRollOut = function () {
more_btn.gotoAndPlay("out");
};
Symbol 404 MovieClip Frame 1
stop();
Symbol 404 MovieClip Frame 21
gotoAndPlay (2);
Symbol 411 MovieClip [copii] Frame 1
stop();
Symbol 411 MovieClip [copii] Frame 2
mos_end.mana_stanga.gotoAndPlay(10);
Symbol 411 MovieClip [copii] Frame 52
mos_end.picioare.play();
Symbol 411 MovieClip [copii] Frame 146
stop();
var bla = true;
trace(bla + " aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa");
Symbol 414 MovieClip Frame 1
trace("mosmasina" + this);
Symbol 426 MovieClip [truckbody] Frame 1
trace("aaaaaaaaaaaaaaaaaaaaaaaaaaaa" + _root.currentlevel);
far._visible == false;
trace("sssssssssssssssssssssssss" + far);
if (_root.currentlevel == 3) {
far._visible = true;
}
Symbol 446 MovieClip [level2] Frame 1
var l2beculete1;
var l2beculete2;
var l2beculete3;
var l2beculete4;
var l2beculete5;
var l2beculete6;
var l2beculete7;
onEnterFrame = function () {
if (coordonate_masina == undefined) {
} else {
if (Number(coordonate_masina) <= 400) {
if (l2beculete1._visible == undefined) {
l2beculete1 = this.attachMovie("l2becuri1", "l2becuri1", 4);
l2beculete1._x = 1029.6;
l2beculete1._y = 729.3;
l2beculete1.swapDepths(end);
trace("attach1");
}
}
if ((Number(coordonate_masina) >= 1290) && (Number(coordonate_masina) < 2681)) {
if (l2beculete2._visible == undefined) {
l2beculete2 = this.attachMovie("l2becuri2", "l2becuri2", 6);
l2beculete2._x = 2152;
l2beculete2._y = 740.9;
l2beculete2.swapDepths(end);
trace("attach2");
}
}
if ((Number(coordonate_masina) >= 1430) && (Number(coordonate_masina) < 2680)) {
l2beculete1.removeMovieClip();
}
if ((Number(coordonate_masina) >= 2680) && (Number(coordonate_masina) < 2879)) {
l2beculete2.removeMovieClip();
}
if ((Number(coordonate_masina) >= 2879) && (Number(coordonate_masina) < 3960)) {
if (l2beculete3._visible == undefined) {
l2beculete3 = this.attachMovie("l2becuri3", "l2becuri3", 5);
l2beculete3._x = 3636.6;
l2beculete3._y = 673.1;
l2beculete3.swapDepths(end);
trace("attach3");
}
}
if ((Number(coordonate_masina) >= 3960) && (Number(coordonate_masina) < 4083)) {
l2beculete3.removeMovieClip();
}
if ((Number(coordonate_masina) >= 4083) && (Number(coordonate_masina) < 4978)) {
if (l2beculete4._visible == undefined) {
l2beculete4 = this.attachMovie("l2becuri4", "l2becuri4", 5);
l2beculete4._x = 4879.6;
l2beculete4._y = 585.3;
l2beculete4.swapDepths(end);
trace("attach4");
}
}
if ((Number(coordonate_masina) >= 4978) && (Number(coordonate_masina) < 5627)) {
if (l2beculete5._visible == undefined) {
l2beculete5 = this.attachMovie("l2becuri5", "l2becuri5", 10);
l2beculete5._x = 5940;
l2beculete5._y = 765.1;
l2beculete5.swapDepths(end);
trace("attach5");
}
}
if ((Number(coordonate_masina) >= 5246) && (Number(coordonate_masina) < 5627)) {
l2beculete4.removeMovieClip();
}
if ((Number(coordonate_masina) >= 5627) && (Number(coordonate_masina) < 6400)) {
if (l2beculete6._visible == undefined) {
l2beculete6 = this.attachMovie("l2becuri6", "l2becuri6", 6);
l2beculete6._x = 6378.8;
l2beculete6._y = 668.8;
l2beculete6.swapDepths(end);
trace("attach6");
}
}
if ((Number(coordonate_masina) >= 6400) && (Number(coordonate_masina) < 6600)) {
l2beculete5.removeMovieClip();
}
if (Number(coordonate_masina) >= 6600) {
if (l2beculete7._visible == undefined) {
l2beculete6.removeMovieClip();
l2beculete7 = this.attachMovie("l2becuri7", "l2becuri7", 5);
l2beculete7._x = 7550.3;
l2beculete7._y = 662.9;
l2beculete7.swapDepths(end);
trace("attach7");
horn = this.attachMovie("horn_l2", "horn_l2", 100);
horn._x = 7600.1;
horn._y = 604;
}
}
}
if (mos == true) {
if (copii._visible == undefined) {
_root.game.b._Level.mcVehiclePlace._dmCarBody.mos_masina._visible = false;
copii = this.attachMovie("copii", "copii", 10);
copii._x = coordonate_masina;
copii._y = coordonate_masina_y;
var _local3 = new mx.transitions.Tween(copii, "_x", none, copii._x, 7443.3, 3, true);
var _local4 = new mx.transitions.Tween(copii, "_y", none, copii._y, 734, 3, true);
_local3.onMotionFinished = function () {
copii.play();
};
}
}
};
Symbol 460 MovieClip [level3] Frame 1
var copii;
var l3beculete1;
var l3beculete2;
var l3beculete3;
var l3beculete4;
var l3beculete5;
onEnterFrame = function () {
if (coordonate_masina == undefined) {
} else {
if (Number(coordonate_masina) <= 800) {
if (l3beculete1._visible == undefined) {
l3beculete1 = this.attachMovie("l3becuri1", "l3becuri1", 4);
l3beculete1._x = 1206.85;
l3beculete1._y = 891.05;
l3beculete1.swapDepths(end);
trace("attach1");
}
}
if ((Number(coordonate_masina) >= 1350) && (Number(coordonate_masina) < 1650)) {
if (l3beculete2._visible == undefined) {
l3beculete2 = this.attachMovie("l3becuri2", "l3becuri2", 5);
l3beculete2._x = 2167.35;
l3beculete2._y = 891.95;
trace("attach2");
l3beculete2.swapDepths(end);
}
}
if ((Number(coordonate_masina) >= 1650) && (Number(coordonate_masina) < 2150)) {
l3beculete1.removeMovieClip();
}
if ((Number(coordonate_masina) >= 2150) && (Number(coordonate_masina) < 2550)) {
if (l3beculete3._visible == undefined) {
l3beculete3 = this.attachMovie("l3becuri3", "l3becuri3", 6);
l3beculete3._x = 2896.3;
l3beculete3._y = 849.8;
trace("attach3");
l3beculete3.swapDepths(end);
}
}
if ((Number(coordonate_masina) >= 2550) && (Number(coordonate_masina) < 3300)) {
l3beculete2.removeMovieClip();
}
if ((Number(coordonate_masina) >= 3300) && (Number(coordonate_masina) < 3420)) {
l3beculete3.removeMovieClip();
}
if ((Number(coordonate_masina) >= 3420) && (Number(coordonate_masina) < 4600)) {
if (l3beculete4._visible == undefined) {
l3beculete4 = this.attachMovie("l3becuri4", "l3becuri4", 8);
l3beculete4._x = 4246.1;
l3beculete4._y = 866.05;
l3beculete4.swapDepths(end);
trace("attach4");
}
}
if ((Number(coordonate_masina) >= 4600) && (Number(coordonate_masina) < 5360)) {
l3beculete4.removeMovieClip();
}
if ((Number(coordonate_masina) >= 5360) && (Number(coordonate_masina) < 6650)) {
if (l3beculete5._visible == undefined) {
l3beculete5 = this.attachMovie("l3becuri5", "l3becuri5", 4);
l3beculete5._x = 6153.65;
l3beculete5._y = 886.8;
trace("attach5");
l3beculete5.swapDepths(end);
}
}
if ((Number(coordonate_masina) >= 6650) && (Number(coordonate_masina) < 7150)) {
l3beculete5.removeMovieClip();
}
}
if (mos == true) {
if (copii._visible == undefined) {
_root.game.b._Level.mcVehiclePlace._dmCarBody.mos_masina._visible = false;
copii = this.attachMovie("copii", "copii", 10);
copii._x = coordonate_masina;
copii._y = coordonate_masina_y;
copii.swapDepths(horn3);
var _local3 = new mx.transitions.Tween(copii, "_x", none, copii._x, 7853, 3, true);
var _local4 = new mx.transitions.Tween(copii, "_y", none, copii._y, 1023, 3, true);
_local3.onMotionFinished = function () {
copii.play();
};
}
}
};