Frame 1
txtPercentage = "---";
txtAmountLoaded = "---";
txtTimeRemaining = "---";
startTime = getTimer();
currentLoaded = 0;
minutesleft = 0;
secondsLeftDisplay = 0;
Frame 2
tBytesLoaded = _root.getBytesLoaded();
tBytesTotal = _root.getBytesTotal();
tBytesRemaining = tBytesTotal - tBytesLoaded;
kilobytesRemaining = tBytesRemaining / 1024;
currentTimer = getTimer();
elapsedTime = currentTimer - startTime;
if (elapsedTime > 1000) {
amountLoaded = tBytesLoaded - currentLoaded;
amountLoadedInKilobytes = amountLoaded / 1024;
currentLoaded = tBytesLoaded;
kilobytesPerSecond = amountLoadedInKilobytes;
secondsRemaining = Math.round(kilobytesRemaining / kilobytesPerSecond);
trace("secondsRemaining = " + secondsRemaining);
minutesleft = Math.floor(secondsRemaining / 60);
trace("minutesleft = " + minutesleft);
secondsLeftDisplay = secondsRemaining - (minutesleft * 60);
if (secondsLeftDisplay < 10) {
secondsLeftDisplay = "0" + secondsLeftDisplay;
}
startTime = getTimer();
}
tRoundedTotal = Math.floor(tBytesTotal / 1024);
tRoundedLoaded = Math.floor(tBytesLoaded / 1024);
if (minutesleft < 0) {
txtTimeRemaining = "Time Left: " + secondsLeftDisplay;
} else {
txtTimeRemaining = (("Time Left: " + minutesleft) + ":") + secondsLeftDisplay;
}
txtPercent = Math.round((tBytesLoaded / tBytesTotal) * 100);
loader.gotoAndStop(txtPercent);
txtAmountLoaded = ((tRoundedLoaded + "k/") + tRoundedTotal) + "k";
txtPercentage = txtPercent + "% loaded";
Frame 3
if (_root.getBytesLoaded() >= _root.getBytesTotal()) {
gotoAndPlay ("introStartFrame");
} else {
gotoAndPlay ("loadingFrame");
}
Frame 89
var myGameClass = (new com.games.reportforduty.ReportForDuty(this));
myGameClass.init();
play();
Frame 118
stop();
Frame 135
stop();
Frame 149
stop();
Symbol 393 MovieClip [__Packages.com.games.reportforduty.ReportForDuty] Frame 0
class com.games.reportforduty.ReportForDuty
{
var rootMC, myStatTracker, _tryAgain, _allowedToPlayCrashingNoise, forwardPressed, _crashSoundTimerStartTime, _crashSoundTimerElapsedTime, _crashSoundTimerLimit, _cycleTimerLimit, myGameStateManager, myLevelManager, soundManager_mc, cycleMessage, _soldierAllowedToSpawn, myKeyboardManager, myTimerClass, myCar, myMap, myUI, numberSoldiersCollected, _requiredSoldiersCollected, _messageTimerStartTime, _activeMessage, level, __get__gameLevel;
function ReportForDuty (aMovieClip) {
trace("ReportForDuty");
rootMC = aMovieClip;
com.events.EventDispatcher.initialize(this);
var _local2 = new com.utilities.StatTracker();
myStatTracker = _local2;
myStatTracker.__set__setTrackingEnabled(true);
myStatTracker.submitStat("/games/sponsored/army/reportforduty/sessionstarted");
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init() {
trace("init");
initDepths();
createClasses();
initClasses();
_tryAgain = false;
_allowedToPlayCrashingNoise = true;
forwardPressed = false;
_crashSoundTimerStartTime = getTimer();
(_crashSoundTimerElapsedTime);// not popped
_crashSoundTimerLimit = 900;
_cycleTimerLimit = 2000;
}
function initDepths() {
trace("initDepths");
depths_obj.gameStateManagerDepth = 10;
depths_obj.mapDepth = 20;
depths_obj.carDepth = 30;
depths_obj.UIDepth = 40;
depths_obj.transitionDepth = 50;
}
function createClasses() {
trace("createClasses");
var _local4 = new com.managers.GameStateManager(rootMC, depths_obj.gameStateManagerDepth);
myGameStateManager = _local4;
myGameStateManager.addEventListener("onIntroGameStateTick", this);
myGameStateManager.addEventListener("onInstructionsGameStateTick", this);
myGameStateManager.addEventListener("onSetupGameStateTick", this);
myGameStateManager.addEventListener("onRoundSetupStateTick", this);
myGameStateManager.addEventListener("onMainGameStateTick", this);
myGameStateManager.addEventListener("onLoseGameStateTick", this);
myGameStateManager.addEventListener("onWinGameStateTick", this);
var _local5 = new com.managers.LevelManager();
myLevelManager = _local5;
trace("soundManager_mc = " + soundManager_mc);
var _local2 = rootMC.createEmptyMovieClip("soundManagerMC", 1);
trace("soundManagerMCthing = " + _local2);
_local2._visible = false;
trace("soundManagerMCthing = " + _local2);
var _local3 = new com.managers.SoundManager(_local2);
trace("theSoundManager_mc = " + _local3);
soundManager_mc = _local3;
trace("soundManager_mc = " + soundManager_mc);
soundManager_mc.addSound("loseBuzz");
soundManager_mc.addSound("menu_select_two");
soundManager_mc.addSound("win_music");
soundManager_mc.addSound("jeep_hit1.aiff");
soundManager_mc.addSound("jeep_hit2.aiff");
soundManager_mc.addSound("jeep_hit3.aiff");
soundManager_mc.addSound("Humvee_rev_engine.wav");
soundManager_mc.addSound("Humvee_idle.wav");
soundManager_mc.addSound("Humvee_driving_loop.wav");
soundManager_mc.addSound("Army_Pickup-1.aiff");
soundManager_mc.addSound("Army_Pickup-2.aiff");
soundManager_mc.addSound("Army_Pickup-3.aiff");
soundManager_mc.addSound("Boxing_Bell2.wav");
}
function initClasses() {
trace("initClasses");
myGameStateManager.init();
}
function setupGame() {
trace("setupGame");
myGameStateManager.__set__setGameState("GS_ROUND_SETUP_");
if (_tryAgain) {
} else {
myLevelManager.init();
}
}
function setupInstructionsState() {
trace("setupInstructionsState");
myStatTracker.submitStat("/games/sponsored/army/reportforduty/instructionspressed");
rootMC.gotoAndStop("instructions");
myGameStateManager.__set__setGameState("GS_GAME_INSTRUCTIONS_");
}
function setupPlayState() {
trace("setupPlayState");
myStatTracker.submitStat("/games/sponsored/army/reportforduty/playpressed");
rootMC.gotoAndStop("playFrame");
soundManager_mc.playSound("menu_select_two", 0, 1);
soundManager_mc.setSoundVolume("menu_select_two", 0, 1);
myGameStateManager.__set__setGameState("GS_GAME_SETUP_");
}
function setupRound() {
trace("setupRound");
rootMC.gotoAndStop("playFrame");
cycleMessage = false;
_soldierAllowedToSpawn = true;
if (_tryAgain) {
_tryAgain = false;
} else {
myLevelManager.incrementLevel();
}
rootMC.level_text.text = myLevelManager.getGameLevel;
myStatTracker.submitStat("/games/sponsored/army/reportforduty/roundreached_" + myLevelManager.__get__getGameLevel());
var _local2 = new com.managers.KeyboardManager();
myKeyboardManager = _local2;
rootMC.attachMovie("TransitionMC", "transition_mc", depths_obj.transitionDepth, {_x:275, _y:200});
rootMC.transition_mc.gotoAndPlay("level" + myLevelManager.__get__getGameLevel());
myGameStateManager.__set__setGameState("GS_PAUSE_");
}
function doneWithTransition() {
var _local9 = new com.games.reportforduty.TimerClass();
myTimerClass = _local9;
myTimerClass.init(myLevelManager.__get__getGameLevel());
myTimerClass.guySpawnInit(myLevelManager.__get__getGameLevel());
var _local12 = new com.games.reportforduty.Car(rootMC, depths_obj.carDepth);
myCar = _local12;
if (((myLevelManager.__get__getGameLevel() == 1) || (myLevelManager.__get__getGameLevel() == 4)) || (myLevelManager.__get__getGameLevel() == 7)) {
} else {
myCar.__get__getCarClip()._rotation = 180;
}
var _local10 = new com.games.reportforduty.Map(rootMC, myLevelManager.__get__getGameLevel());
myMap = _local10;
myMap.init(depths_obj.mapDepth, myLevelManager.__get__getGameLevel());
var _local11 = new com.games.reportforduty.UIClass(rootMC, depths_obj.UIDepth);
myUI = _local11;
var _local6 = myMap.__get__getMapClip();
var _local8 = _local6.jeep_spawn_mc._x;
var _local7 = _local6.jeep_spawn_mc._y;
var _local5 = 275 - _local8;
var _local4 = 200 - _local7;
myMap.__get__getMapClip()._x = _local5;
myMap.__get__getMapClip()._y = _local4;
numberSoldiersCollected = 0;
_requiredSoldiersCollected = 4 + ((myLevelManager.__get__getGameLevel() - 1) * 2);
trace("_requiredSoldiersCollected = " + _requiredSoldiersCollected);
myUI.updateLevel(myLevelManager.__get__getGameLevel());
myUI.updateSoldiers(0, _requiredSoldiersCollected);
myUI.updateTime(myTimerClass.__get__getTimeLeft());
myUI.updatePrompt("");
myUI.setupRadar(myLevelManager.__get__getGameLevel());
soundManager_mc.playSound("Humvee_idle.wav", 0, 999);
soundManager_mc.setSoundVolume("Humvee_idle.wav", 50);
myUI.__get__getUIClip().radar_mc.map_info_mc._x = _local5;
myUI.__get__getUIClip().radar_mc.map_info_mc._y = _local4;
var _local3 = 8;
var _local2 = 1;
while (_local2 < (_local3 + 1)) {
myUI.__get__getUIClip().radar_mc.map_info_mc["spawn_" + _local2]._visible = myMap.__get__getMapClip()["soldier_pad_" + _local2].soldier_mc._visible;
_local2++;
}
rootMC.transition_mc.removeMovieClip();
myGameStateManager.__set__setGameState("GS_GAME_");
}
function setupWinRoundState() {
trace("setupWinState");
cleanUpStage();
myStatTracker.submitStat("/games/sponsored/army/reportforduty/roundpassed_" + myLevelManager.__get__getGameLevel());
if (myLevelManager.__get__getGameLevel() == 9) {
trace("You beat the game!");
setupWinState();
} else {
trace("setting up win round state");
if (myLevelManager.__get__getGameLevel() == 3) {
rootMC.gotoAndStop("winGame");
rootMC.end_game_screen.gotoAndStop(1);
} else if (myLevelManager.__get__getGameLevel() == 6) {
rootMC.gotoAndStop("winGame");
rootMC.end_game_screen.gotoAndStop(2);
} else {
rootMC.gotoAndStop("winRoundFrame");
}
soundManager_mc.playSound("win_music", 0, 1);
myGameStateManager.__set__setGameState("GS_END_OF_ROUND_");
}
}
function setupWinState() {
trace("setupWinState");
rootMC.gotoAndStop("winGame");
rootMC.end_game_screen.gotoAndStop(3);
cleanUpStage();
myGameStateManager.__set__setGameState("GS_WIN_");
}
function cleanUpStage() {
trace("cleanUpStage");
myCar.cleanMeUp();
myMap.cleanMeUp();
myUI.cleanMeUp();
soundManager_mc.stopSound("Humvee_driving_loop.wav", 0, 999);
soundManager_mc.stopSound("Humvee_rev_engine.wav", 0, 1);
soundManager_mc.stopSound("Humvee_idle.wav", 0, 999);
myKeyboardManager = null;
}
function nextRoundPrompt() {
trace("setupWinState");
soundManager_mc.stopSound("win_music");
setupRound();
}
function setupLoseState() {
trace("setupLoseState");
rootMC.gotoAndStop("loseFrame");
cleanUpStage();
_tryAgain = true;
soundManager_mc.playSound("loseBuzz", 0, 1);
soundManager_mc.setSoundVolume("setSoundVolume", 50);
myGameStateManager.__set__setGameState("GS_LOSE_");
}
function setupPlayAgainState() {
trace("setupPlayAgainState");
myStatTracker.submitStat("/games/sponsored/army/reportforduty/playagainpressed");
rootMC.gotoAndStop("playFrame");
myGameStateManager.__set__setGameState("GS_GAME_SETUP_");
}
function exampleEvent() {
var _local2 = new com.events.Event(this, "onExampleEvent");
_local2.data = new Object();
_local2.data.butts = true;
dispatchEvent(_local2);
}
function STAGE_BUTTON_Instructions() {
trace("STAGE_BUTTON_Instructions");
setupInstructionsState();
}
function STAGE_BUTTON_GO_TO_SITE() {
trace("STAGE_BUTTON_GO_TO_SITE");
getURL ("http://www.goarmy.com/", "_blank");
myStatTracker.submitStat("/games/sponsored/army/reportforduty/clickedsitebutton");
}
function STAGE_BUTTON_Play() {
trace("STAGE_BUTTON_Play");
setupPlayState();
}
function STAGE_BUTTON_WinRound() {
trace("STAGE_BUTTON_WinRound");
setupWinRoundState();
}
function STAGE_BUTTON_NextRound() {
trace("STAGE_BUTTON_NextRound");
myStatTracker.submitStat("/games/sponsored/army/reportforduty/nextroundpressed");
nextRoundPrompt();
}
function STAGE_BUTTON_Lose() {
trace("STAGE_BUTTON_Lose");
setupLoseState();
}
function STAGE_BUTTON_PlayAgain() {
trace("STAGE_BUTTON_PlayAgain");
setupPlayAgainState();
}
function onSomeEvent(aEvent) {
}
function onIntroGameStateTick(aEvent) {
}
function onInstructionsGameStateTick(aEvent) {
}
function onSetupGameStateTick(aEvent) {
setupGame();
}
function onRoundSetupStateTick(aEvent) {
setupRound();
}
function onMainGameStateTick(aEvent) {
if (myKeyboardManager.getKeyDown(87) || (myKeyboardManager.getKeyDown(38))) {
if (!returnIfCrashing()) {
myCar.speedUp();
if (forwardPressed == false) {
soundManager_mc.playSound("Humvee_driving_loop.wav", 0, 999);
soundManager_mc.setSoundVolume("Humvee_driving_loop.wav", 50);
soundManager_mc.playSound("Humvee_rev_engine.wav", 0, 1);
soundManager_mc.setSoundVolume("Humvee_rev_engine.wav", 50);
forwardPressed = true;
}
} else {
myCar.stopCar();
}
} else {
soundManager_mc.stopSound("Humvee_driving_loop.wav", 0, 999);
soundManager_mc.stopSound("Humvee_rev_engine.wav", 0, 1);
forwardPressed = false;
}
if (myKeyboardManager.getKeyDown(65) || (myKeyboardManager.getKeyDown(37))) {
myCar.rotateLeft();
}
if (myKeyboardManager.getKeyDown(83) || (myKeyboardManager.getKeyDown(40))) {
if (!returnIfBackCrashing()) {
myCar.slowDown();
} else {
myCar.stopCar();
}
returnIfBackCrashing();
}
if (myKeyboardManager.getKeyDown(68) || (myKeyboardManager.getKeyDown(39))) {
myCar.rotateRight();
}
rootMC.rotation_txt.text = myCar.getCarRotation;
var _local5 = myCar.__get__getCarRotation() / 180;
rootMC.ratio_txt.text = _local5;
var _local3 = Math.sin(myCar.__get__getCarRotation() * (Math.PI/180)) * myCar.__get__getTravelSpeed();
var _local2 = (Math.cos(myCar.__get__getCarRotation() * (Math.PI/180)) * myCar.__get__getTravelSpeed()) * -1;
rootMC.xMath_txt.text = _local3;
rootMC.yMath_txt.text = _local2;
myMap.moveMe(_local3, _local2);
myUI.moveRadar(_local3, _local2);
if (returnIfCrashing()) {
myCar.stopCar();
}
if (returnIfBackCrashing()) {
myCar.stopCar();
}
myCar.coast();
checkSoldierCollect();
checkHelipadFinish();
checkTimeLeft();
checkForSpawn();
var _local6 = getTimer() - _crashSoundTimerStartTime;
if (_local6 > _crashSoundTimerLimit) {
_allowedToPlayCrashingNoise = true;
}
if (cycleMessage) {
var _local4 = getTimer() - _messageTimerStartTime;
if (_local4 > _cycleTimerLimit) {
if (_activeMessage == "Return") {
myUI.updatePrompt("No more room in Jeep!");
_activeMessage = "No";
} else if (_activeMessage == "No") {
myUI.updatePrompt("Return to Helipad for drop off!");
_activeMessage = "Return";
}
_messageTimerStartTime = getTimer();
}
}
}
function checkTimeLeft() {
myTimerClass.tickTimer();
var _local2 = Math.ceil(myTimerClass.__get__getTimeLeft() / 1000);
myUI.updateTime(_local2);
rootMC.time_left_txt.text = myTimerClass.getTimeLeft;
if (myTimerClass.__get__getTimeLeft() <= 0) {
trace("YOU LOSE!");
setupLoseState();
}
}
function checkForSpawn() {
if (_soldierAllowedToSpawn) {
myTimerClass.tickSpawnTimer();
if (myTimerClass.__get__getSpawnTimeLeft() <= 0) {
var _local2 = com.utilities.MyRandom.roll(1, 8);
myMap.setupNewSoldier(_local2);
myUI.__get__getUIClip().radar_mc.map_info_mc["spawn_" + _local2]._visible = true;
myTimerClass.resetSpawnTimer();
}
}
}
function checkSoldierCollect() {
var _local3 = 0;
while (_local3 < 9) {
var _local7 = myMap.__get__getMapClip();
var _local4 = _local7["soldier_pad_" + _local3];
var _local5 = myCar.__get__getCarClip().jeep_mc.hit_point_mc;
var _local2 = new Object();
_local2.x = _local5._x;
_local2.y = _local5._y;
myCar.__get__getCarClip().jeep_mc.localToGlobal(_local2);
var _local9 = _local2.x;
var _local8 = _local2.y;
if (_local4.hitTest(_local9, _local8, true)) {
trace("hitting a soldier pad");
if (myCar.__get__getCurrentSoldierNumber() < 4) {
if (_local4.soldier_mc._visible) {
_local4.soldier_mc._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc["spawn_" + _local3]._visible = false;
myCar.addSolider();
if ((numberSoldiersCollected + myCar.__get__getCurrentSoldierNumber()) >= _requiredSoldiersCollected) {
trace("YOU HAVE ALL THE SOLIDERS YOU NEED!");
myMap.hideAllSoliders();
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_1._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_2._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_3._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_4._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_5._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_6._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_7._visible = false;
myUI.__get__getUIClip().radar_mc.map_info_mc.spawn_8._visible = false;
_soldierAllowedToSpawn = false;
}
var _local6 = com.utilities.MyRandom.roll(1, 3);
switch (_local6) {
case 1 :
soundManager_mc.playSound("Army_Pickup-1.aiff", 0, 1);
break;
case 2 :
soundManager_mc.playSound("Army_Pickup-2.aiff", 0, 1);
break;
case 3 :
soundManager_mc.playSound("Army_Pickup-3.aiff", 0, 1);
}
}
} else {
if (_allowedToPlayCrashingNoise) {
soundManager_mc.playSound("loseBuzz", 0, 1);
soundManager_mc.setSoundVolume("loseBuzz", 50);
_allowedToPlayCrashingNoise = false;
_crashSoundTimerStartTime = getTimer();
}
if (cycleMessage == false) {
cycleMessage = true;
myUI.updatePrompt("No more room in Jeep!");
_activeMessage = "No";
_messageTimerStartTime = getTimer();
}
}
}
_local3++;
}
}
function checkHelipadFinish() {
var _local6 = myMap.__get__getMapClip();
var _local5 = _local6.jeep_spawn_mc;
var _local4 = myCar.__get__getCarClip().jeep_mc.hit_point_mc;
var _local2 = new Object();
_local2.x = _local4._x;
_local2.y = _local4._y;
myCar.__get__getCarClip().jeep_mc.localToGlobal(_local2);
var _local8 = _local2.x;
var _local7 = _local2.y;
if (_local5.hitTest(_local8, _local7, true)) {
if (myCar.__get__getCurrentSoldierNumber() > 0) {
trace("more then one solider in the car");
cycleMessage = false;
soundManager_mc.playSound("Boxing_Bell2.wav", 0, 1);
numberSoldiersCollected = numberSoldiersCollected + myCar.emptyCar();
trace("numberSoldiersCollected = " + numberSoldiersCollected);
myUI.updateSoldiers(numberSoldiersCollected, _requiredSoldiersCollected);
if (numberSoldiersCollected >= _requiredSoldiersCollected) {
setupWinRoundState();
} else {
var _local3 = _requiredSoldiersCollected - numberSoldiersCollected;
if (_local3 > 1) {
myUI.updatePrompt(("You need " + _local3) + " more Soldiers!");
} else {
myUI.updatePrompt(("You need " + _local3) + " more Soldier!");
}
}
}
}
}
function returnIfCrashing() {
var _local3 = false;
var _local4 = myCar.__get__getCarClip().jeep_mc.hit_point_mc;
var _local5 = myMap.__get__getMapClip().collision_mc;
var _local2 = new Object();
_local2.x = _local4._x;
_local2.y = _local4._y;
myCar.__get__getCarClip().jeep_mc.localToGlobal(_local2);
var _local8 = _local2.x;
var _local6 = _local2.y;
if (_local5.hitTest(_local8, _local6, true)) {
_local3 = true;
if (_allowedToPlayCrashingNoise) {
var _local7 = com.utilities.MyRandom.roll(1, 3);
switch (_local7) {
case 1 :
soundManager_mc.playSound("jeep_hit1.aiff", 0, 1);
soundManager_mc.setSoundVolume("jeep_hit1.aiff", 50);
break;
case 2 :
soundManager_mc.playSound("jeep_hit2.aiff", 0, 1);
soundManager_mc.setSoundVolume("jeep_hit2.aiff", 50);
break;
case 3 :
soundManager_mc.playSound("jeep_hit3.aiff", 0, 1);
soundManager_mc.setSoundVolume("jeep_hit3.aiff", 50);
}
_allowedToPlayCrashingNoise = false;
_crashSoundTimerStartTime = getTimer();
}
}
return(_local3);
}
function returnIfBackCrashing() {
var _local3 = false;
var _local4 = myCar.__get__getCarClip().jeep_mc.rear_hit_point_mc;
var _local5 = myMap.__get__getMapClip().collision_mc;
var _local2 = new Object();
_local2.x = _local4._x;
_local2.y = _local4._y;
myCar.__get__getCarClip().jeep_mc.localToGlobal(_local2);
var _local8 = _local2.x;
var _local6 = _local2.y;
if (_local5.hitTest(_local8, _local6, true)) {
_local3 = true;
if (_allowedToPlayCrashingNoise) {
var _local7 = com.utilities.MyRandom.roll(1, 3);
switch (_local7) {
case 1 :
soundManager_mc.playSound("jeep_hit1.aiff", 0, 1);
soundManager_mc.setSoundVolume("jeep_hit1.aiff", 50);
break;
case 2 :
soundManager_mc.playSound("jeep_hit2.aiff", 0, 1);
soundManager_mc.setSoundVolume("jeep_hit2.aiff", 50);
break;
case 3 :
soundManager_mc.playSound("jeep_hit3.aiff", 0, 1);
soundManager_mc.setSoundVolume("jeep_hit3.aiff", 50);
}
_allowedToPlayCrashingNoise = false;
_crashSoundTimerStartTime = getTimer();
}
}
return(_local3);
}
function onLoseGameStateTick(aEvent) {
}
function onWinGameStateTick(aEvent) {
}
function get getGameLevel() {
return(level);
}
function set gameLevel(level_inc) {
level = level_inc;
//return(__get__gameLevel());
}
var depths_obj = new Object();
}
Symbol 394 MovieClip [__Packages.com.managers.GameStateManager] Frame 0
class com.managers.GameStateManager
{
var gameEnterframeEngineClipDepth, rootMC, gameState, __get__setGameState;
function GameStateManager (aRootMC, aDepth) {
gameEnterframeEngineClipDepth = aDepth;
rootMC = aRootMC;
com.events.EventDispatcher.initialize(this);
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init() {
rootMC.createEmptyMovieClip("gameEngineEnterframe_MC", gameEnterframeEngineClipDepth);
rootMC.gameEngineEnterframe_MC.ref = this;
rootMC.gameEngineEnterframe_MC.onEnterFrame = function () {
this.ref.gameEngineLoop();
};
gameState = GS_INTRO_;
}
function gameEngineLoop() {
if (gameState == GS_INTRO_) {
var _local2 = new com.events.Event(this, "onIntroGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_GAME_INSTRUCTIONS_) {
var _local2 = new com.events.Event(this, "onInstructionsGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_GAME_SETUP_) {
var _local2 = new com.events.Event(this, "onSetupGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_ROUND_SETUP_) {
var _local2 = new com.events.Event(this, "onRoundSetupStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_GAME_) {
var _local2 = new com.events.Event(this, "onMainGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_END_OF_ROUND_) {
var _local2 = new com.events.Event(this, "onEndOfRoundGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_LOSE_ROUND_) {
var _local2 = new com.events.Event(this, "onLoseRoundGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_SETUP_BONUS_ROUND_) {
var _local2 = new com.events.Event(this, "onSetupBonusRoundGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_BONUS_ROUND_) {
var _local2 = new com.events.Event(this, "onBonusRoundGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_END_OF_BONUS_ROUND_) {
var _local2 = new com.events.Event(this, "onEndOfBonusRoundGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_LOSE_) {
var _local2 = new com.events.Event(this, "onLoseGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_WIN_) {
var _local2 = new com.events.Event(this, "onWinGameStateTick");
dispatchEvent(_local2);
} else if (gameState == GS_PAUSE_) {
var _local2 = new com.events.Event(this, "onPauseGameStateTick");
dispatchEvent(_local2);
}
}
function set setGameState(aGameState) {
trace("setting gameState to " + aGameState);
gameState = this[aGameState];
//return(__get__setGameState());
}
function get getGameState() {
return(gameState);
}
var GS_SETUP_ = 1;
var GS_INTRO_ = 2;
var GS_GAME_INSTRUCTIONS_ = 13;
var GS_GAME_SETUP_ = 3;
var GS_ROUND_SETUP_ = 4;
var GS_GAME_ = 5;
var GS_END_OF_ROUND_ = 6;
var GS_LOSE_ROUND_ = 12;
var GS_SETUP_BONUS_ROUND_ = 7;
var GS_BONUS_ROUND_ = 8;
var GS_END_OF_BONUS_ROUND_ = 9;
var GS_LOSE_ = 10;
var GS_PAUSE_ = 11;
var GS_WIN_ = 14;
}
Symbol 395 MovieClip [__Packages.com.events.EventDispatcher] Frame 0
class com.events.EventDispatcher
{
function EventDispatcher () {
}
static function _removeEventListener(queue, event, handler) {
if (queue != undefined) {
var _local4 = queue.length;
var _local1;
_local1 = 0;
while (_local1 < _local4) {
var _local2 = queue[_local1];
if (_local2 == handler) {
queue.splice(_local1, 1);
return(undefined);
}
_local1++;
}
}
}
static function initialize(object) {
if (isTracing_boolean == true) {
trace(("@@EventDispatcher.initialize (" + object) + ")");
}
if (_fEventDispatcher == undefined) {
_fEventDispatcher = new com.events.EventDispatcher();
}
object.addEventListener = _fEventDispatcher.addEventListener;
object.removeEventListener = _fEventDispatcher.removeEventListener;
object.dispatchEvent = _fEventDispatcher.dispatchEvent;
object.dispatchQueue = _fEventDispatcher.dispatchQueue;
}
function dispatchQueue(queueObj, eventObj) {
var _local7 = "__q_" + eventObj.type;
var _local4 = queueObj[_local7];
if (_local4 != undefined) {
var _local5;
for (_local5 in _local4) {
var _local1 = _local4[_local5];
var _local3 = typeof(_local1);
if ((_local3 == "object") || (_local3 == "movieclip")) {
if (_local1.handleEvent != undefined) {
_local1.handleEvent(eventObj);
}
if (_local1[eventObj.type] != undefined) {
if (exceptions.eventObj.type == undefined) {
_local1[eventObj.type](eventObj);
}
}
} else {
_local1.apply(queueObj, [eventObj]);
}
}
}
}
function dispatchEvent(eventObj) {
if (isTracing_boolean == true) {
trace((("@@" + this) + ".dispatchEvent() type: ") + eventObj.type);
}
if (eventObj.target == undefined) {
eventObj.target = this;
}
this[eventObj.type + "Handler"](eventObj);
dispatchQueue(this, eventObj);
}
function addEventListener(event, handler) {
if (isTracing_boolean == true) {
trace(((((("@@" + this) + ".addEventListener (") + event) + ",") + handler) + ")");
}
var _local3 = "__q_" + event;
if (this[_local3] == undefined) {
this[_local3] = new Array();
}
_global.ASSetPropFlags(this, _local3, 1);
_removeEventListener(this[_local3], event, handler);
this[_local3].push(handler);
}
function removeEventListener(event, handler) {
if (isTracing_boolean == true) {
trace(((((("@@" + this) + ".removeEventListener (") + event) + ",") + handler) + ")");
}
var _local3 = "__q_" + event;
_removeEventListener(this[_local3], event, handler);
}
static var _fEventDispatcher = undefined;
static var exceptions = {move:1, draw:1, load:1};
static var isTracing_boolean = false;
}
Symbol 396 MovieClip [__Packages.com.events.Event] Frame 0
class com.events.Event extends Object
{
var target, type;
function Event (aTarget_obj, aType_str) {
super();
target = aTarget_obj;
type = aType_str;
}
}
Symbol 397 MovieClip [__Packages.com.managers.LevelManager] Frame 0
class com.managers.LevelManager
{
var level, stage, __get__gameLevel, __get__gameStage;
function LevelManager () {
com.events.EventDispatcher.initialize(this);
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init() {
trace("LevelManager init");
level = 0;
stage = 0;
}
function resetLevel() {
var _local2 = level;
var _local3 = stage;
if (_local2 < 4) {
level = 1;
} else if ((_local2 > 3) and (_local2 < 7)) {
level = 4;
} else if ((_local2 < 6) and (_local2 < 9)) {
level = 7;
}
}
function incrementLevel() {
level++;
}
function incrementStage() {
stage++;
}
function exampleEvent() {
var _local2 = new com.events.Event(this, "onExampleEvent");
_local2.data = new Object();
_local2.data.butts = true;
dispatchEvent(_local2);
}
function onSomeEvent(aEvent) {
}
function get getGameLevel() {
return(level);
}
function get getGameStage() {
return(stage);
}
function set gameLevel(aLevel) {
level = aLevel;
//return(__get__gameLevel());
}
function set gameStage(aStage) {
stage = aStage;
//return(__get__gameStage());
}
}
Symbol 398 MovieClip [__Packages.com.managers.KeyboardManager] Frame 0
class com.managers.KeyboardManager
{
var ref, level, __get__gameLevel;
function KeyboardManager () {
com.events.EventDispatcher.initialize(this);
myListener.onKeyUp = onKeyUpEventFunction;
myListener.onKeyDown = onKeyDownEventFunction;
myListener.ref = this;
Key.addListener(myListener);
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init() {
}
function onKeyUpEventFunction() {
var _local2 = new com.events.Event(this, "onKeyUpEvent");
_local2.data = new Object();
_local2.data.keyDownNumber = Key.getCode();
ref.dispatchEvent(_local2);
}
function onKeyDownEventFunction() {
trace(("You pressed " + Key.getCode()) + " key.");
var _local2 = new com.events.Event(this, "onKeyDownEvent");
_local2.data = new Object();
_local2.data.keyDownNumber = Key.getCode();
ref.dispatchEvent(_local2);
}
function exampleEvent() {
var _local2 = new com.events.Event(this, "onExampleEvent");
_local2.data = new Object();
_local2.data.butts = true;
dispatchEvent(_local2);
}
function onSomeEvent(aEvent) {
}
function getKeyDown(aKeyNumber) {
return(Key.isDown(aKeyNumber));
}
function get getGameLevel() {
return(level);
}
function set gameLevel(level_inc) {
level = level_inc;
//return(__get__gameLevel());
}
var myListener = new Object();
}
Symbol 399 MovieClip [__Packages.com.games.reportforduty.Car] Frame 0
class com.games.reportforduty.Car
{
var rootMC, rotationSpeed, _travelSpeed, _maxTravelSpeed, _rotationAccel, _maxRotationAccel, _currentSoldierNumber, __myLevel, __get__gameLevel, __get__setTravelSpeed;
function Car (aStageMC, aDepth) {
trace("Car");
com.events.EventDispatcher.initialize(this);
rootMC = aStageMC;
rootMC.attachMovie("CarMC", "car_mc", aDepth, {_x:275, _y:200});
rotationSpeed = 3;
_travelSpeed = 0;
_maxTravelSpeed = 6;
_rotationAccel = 0;
_maxRotationAccel = 6;
rootMC.car_mc.jeep_mc.soldier_in_jeep_1._visible = false;
rootMC.car_mc.jeep_mc.soldier_in_jeep_2._visible = false;
rootMC.car_mc.jeep_mc.soldier_in_jeep_3._visible = false;
rootMC.car_mc.jeep_mc.soldier_in_jeep_4._visible = false;
rootMC.car_mc.jeep_mc.hit_point_mc._visible = false;
rootMC.car_mc.jeep_mc.rear_hit_point_mc._visible = false;
_currentSoldierNumber = 0;
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init() {
}
function addSolider() {
trace("addSolider");
_currentSoldierNumber++;
rootMC.car_mc.jeep_mc["soldier_in_jeep_" + _currentSoldierNumber]._visible = true;
}
function emptyCar() {
trace("addSolider");
var _local2 = _currentSoldierNumber;
_currentSoldierNumber = 0;
rootMC.car_mc.jeep_mc.soldier_in_jeep_1._visible = false;
rootMC.car_mc.jeep_mc.soldier_in_jeep_2._visible = false;
rootMC.car_mc.jeep_mc.soldier_in_jeep_3._visible = false;
rootMC.car_mc.jeep_mc.soldier_in_jeep_4._visible = false;
return(_local2);
}
function cleanMeUp() {
trace("cleanMeUp( - car");
rootMC.car_mc.removeMovieClip();
}
function rotateLeft() {
_rotationAccel = _rotationAccel + 2;
if (_rotationAccel >= _maxRotationAccel) {
_rotationAccel = _maxRotationAccel;
}
rootMC.car_mc._rotation = rootMC.car_mc._rotation - (rotationSpeed + _rotationAccel);
}
function rotateRight() {
_rotationAccel = _rotationAccel + 2;
if (_rotationAccel >= _maxRotationAccel) {
_rotationAccel = _maxRotationAccel;
}
rootMC.car_mc._rotation = rootMC.car_mc._rotation + (rotationSpeed + _rotationAccel);
}
function speedUp() {
_travelSpeed = _travelSpeed + 1;
if (_travelSpeed >= _maxTravelSpeed) {
_travelSpeed = _maxTravelSpeed;
}
}
function slowDown() {
_travelSpeed = _travelSpeed - 1;
if (_travelSpeed <= ((_maxTravelSpeed / 2) * -1)) {
_travelSpeed = (_maxTravelSpeed / 2) * -1;
}
}
function coast() {
if (_travelSpeed > 0) {
_travelSpeed = _travelSpeed - 0.1;
}
if (_travelSpeed < 0) {
_travelSpeed = _travelSpeed + 0.1;
}
if (_rotationAccel > 0) {
_rotationAccel = _rotationAccel - 1;
}
}
function stopCar() {
_travelSpeed = 0;
}
function exampleEvent() {
var _local2 = new com.events.Event(this, "onExampleEvent");
_local2.data = new Object();
_local2.data.butts = true;
dispatchEvent(_local2);
}
function onSomeEvent(aEvent) {
}
function get getGameLevel() {
return(__myLevel);
}
function get getCarRotation() {
return(rootMC.car_mc._rotation);
}
function get getTravelSpeed() {
return(_travelSpeed);
}
function get getCarClip() {
return(rootMC.car_mc);
}
function get getCurrentSoldierNumber() {
return(_currentSoldierNumber);
}
function set gameLevel(aLevel) {
__myLevel = aLevel;
//return(__get__gameLevel());
}
function set setTravelSpeed(aSpeed) {
_travelSpeed = aSpeed;
//return(__get__setTravelSpeed());
}
}
Symbol 400 MovieClip [__Packages.com.games.reportforduty.Map] Frame 0
class com.games.reportforduty.Map
{
var _rootMC, _Y_speed, _Max_Y_speed, _X_speed, _Max_X_speed, _mapClip, _spawnLocations, __myLevel;
function Map (aMC, aLevel) {
trace("Map");
_rootMC = aMC;
_Y_speed = 0.25;
_Max_Y_speed = 1;
_X_speed = 0.25;
_Max_X_speed = 1;
com.events.EventDispatcher.initialize(this);
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init(aDepth, aLevel) {
_rootMC.attachMovie("MapMC", "map_mc", aDepth);
_mapClip = _rootMC.map_mc;
var _local8 = 0;
switch (aLevel) {
case 1 :
_local8 = 1;
break;
case 2 :
_local8 = 2;
break;
case 3 :
_local8 = 3;
break;
case 4 :
_local8 = 1;
break;
case 5 :
_local8 = 2;
break;
case 6 :
_local8 = 3;
break;
case 7 :
_local8 = 1;
break;
case 8 :
_local8 = 2;
break;
case 9 :
_local8 = 3;
}
_mapClip.gotoAndStop(_local8);
_spawnLocations = [];
var _local15 = 8;
var _local3 = 1;
while (_local3 < (_local15 + 1)) {
var _local2 = _mapClip["spawn_" + _local3];
var _local7 = _local2._x;
var _local5 = _local2._y;
var _local6 = [_local7, _local5];
_spawnLocations.push(_local6);
_local2._visible = false;
_local3++;
}
var _local16 = 8;
_local3 = 1;
while (_local3 < (_local16 + 1)) {
var _local4 = _spawnLocations.splice(0, 1);
var _local9 = _local4[0][0];
var _local10 = _local4[0][1];
_mapClip.attachMovie("SoldierPad", "soldier_pad_" + _local3, _local3, {_x:_local9, _y:_local10});
_mapClip["soldier_pad_" + _local3].parking_spot_mc.gotoAndStop(_local8);
_mapClip["soldier_pad_" + _local3].soldier_mc._visible = false;
_local3++;
}
var _local14 = aLevel + 1;
if (_local14 > 8) {
_local14 = 8;
}
_local3 = 1;
while (_local3 < (_local14 + 1)) {
var _local13 = com.utilities.MyRandom.roll(1, _spawnLocations.length) - 1;
_mapClip["soldier_pad_" + _local3].soldier_mc._visible = true;
_local3++;
}
_mapClip.collision_mc._visible = false;
}
function setupNewSoldier(aNumber) {
if (!_mapClip["soldier_pad_" + aNumber].soldier_mc._visible) {
_mapClip["soldier_pad_" + aNumber].soldier_mc._visible = true;
}
}
function hideAllSoliders() {
var _local3 = 8;
var _local2 = 1;
while (_local2 < (_local3 + 1)) {
_mapClip["soldier_pad_" + _local2].soldier_mc._visible = false;
_local2++;
}
}
function cleanMeUp() {
_rootMC.map_mc.removeMovieClip();
}
function moveMe(aX, aY) {
_rootMC.map_mc._x = _rootMC.map_mc._x + aX;
_rootMC.map_mc._y = _rootMC.map_mc._y + aY;
}
function exampleEvent() {
var _local2 = new com.events.Event(this, "onExampleEvent");
_local2.data = new Object();
_local2.data.butts = true;
dispatchEvent(_local2);
}
function onSomeEvent(aEvent) {
}
function get getGameLevel() {
return(__myLevel);
}
function get getMapClip() {
return(_mapClip);
}
function set gameLevel(aLevel) {
__myLevel = aLevel;
}
function set set_X_speed(aSpeed) {
_X_speed = aSpeed;
}
function set set_Y_speed(aSpeed) {
_Y_speed = aSpeed;
}
}
Symbol 401 MovieClip [__Packages.com.games.reportforduty.TimerClass] Frame 0
class com.games.reportforduty.TimerClass
{
var _timeLeft, _roundTime, _startTime, _spawnTime, _spawnStartTime, _spawnTimeLeft, __myLevel, __get__gameLevel;
function TimerClass () {
trace("TimerClass");
com.events.EventDispatcher.initialize(this);
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init(aRound) {
_timeLeft = (_roundTime = 50000 + (10000 * aRound));
_startTime = getTimer();
}
function guySpawnInit(aRound) {
_spawnTime = 8000 - (aRound * 325);
if (_spawnTime < 1000) {
_spawnTime = 1000;
}
_spawnStartTime = getTimer();
}
function tickTimer() {
var _local2 = getTimer();
var _local3 = _local2 - _startTime;
_timeLeft = _roundTime - _local3;
}
function tickSpawnTimer() {
var _local2 = getTimer();
var _local3 = _local2 - _spawnStartTime;
_spawnTimeLeft = _spawnTime - _local3;
}
function resetSpawnTimer() {
_spawnStartTime = getTimer();
}
function exampleEvent() {
var _local2 = new com.events.Event(this, "onExampleEvent");
_local2.data = new Object();
_local2.data.butts = true;
dispatchEvent(_local2);
}
function onSomeEvent(aEvent) {
}
function get getGameLevel() {
return(__myLevel);
}
function get getTimeLeft() {
return(_timeLeft);
}
function get getSpawnTimeLeft() {
return(_spawnTimeLeft);
}
function set gameLevel(aLevel) {
__myLevel = aLevel;
//return(__get__gameLevel());
}
}
Symbol 402 MovieClip [__Packages.com.games.reportforduty.UIClass] Frame 0
class com.games.reportforduty.UIClass
{
var rootMC, _UIClip, __myLevel, __get__gameLevel;
function UIClass (aStageMC, aDepth) {
trace("UIClass");
rootMC = aStageMC;
rootMC.attachMovie("UIMC", "ui_mc", aDepth, {_x:0, _y:290});
_UIClip = rootMC.ui_mc;
com.events.EventDispatcher.initialize(this);
}
function addEventListener() {
}
function removeEventListener() {
}
function dispatchEvent() {
}
function init() {
}
function exampleEvent() {
var _local2 = new com.events.Event(this, "onExampleEvent");
_local2.data = new Object();
_local2.data.butts = true;
dispatchEvent(_local2);
}
function setupRadar(aNumber) {
trace("setupRadar");
var _local2;
switch (aNumber) {
case 1 :
_local2 = 1;
break;
case 2 :
_local2 = 2;
break;
case 3 :
_local2 = 3;
break;
case 4 :
_local2 = 1;
break;
case 5 :
_local2 = 2;
break;
case 6 :
_local2 = 3;
break;
case 7 :
_local2 = 1;
break;
case 8 :
_local2 = 2;
break;
case 9 :
_local2 = 3;
}
_UIClip.radar_mc.gotoAndStop(_local2);
}
function moveRadar(aX, aY) {
_UIClip.radar_mc.map_info_mc._x = _UIClip.radar_mc.map_info_mc._x + aX;
_UIClip.radar_mc.map_info_mc._y = _UIClip.radar_mc.map_info_mc._y + aY;
}
function cleanMeUp() {
trace("cleanMeUp( - car");
_UIClip.removeMovieClip();
}
function updateLevel(aLevel) {
_UIClip.level_txt.text = aLevel;
}
function updateSoldiers(aSoldiersNeeded, aSoldiersLeft) {
_UIClip.soldiers_txt.text = (aSoldiersNeeded + "/") + aSoldiersLeft;
}
function updateTime(aTime) {
var _local4 = "";
var _local3 = Math.floor(aTime / 60);
var _local2 = aTime - (_local3 * 60);
if (_local2 < 10) {
_local2 = "0" + String(_local2);
}
if (_local3 < 1) {
}
_local4 = (_local3 + ":") + _local2;
_UIClip.time_txt.text = _local4;
}
function updatePrompt(aText) {
_UIClip.prompt_txt.text = "";
_UIClip.stage_prompt_mc.gotoAndPlay(2);
_UIClip.stage_prompt_mc.screen_prompt_txt.text = aText;
}
function onSomeEvent(aEvent) {
}
function get getGameLevel() {
return(__myLevel);
}
function get getUIClip() {
return(_UIClip);
}
function set gameLevel(aLevel) {
__myLevel = aLevel;
//return(__get__gameLevel());
}
}
Symbol 403 MovieClip [__Packages.com.managers.SoundManager] Frame 0
class com.managers.SoundManager extends MovieClip
{
var thisMC, sounds_array, globalSound_snd, theSoundClipMC;
function SoundManager (aSoundRef) {
super();
thisMC = aSoundRef;
sounds_array = new Array();
}
function init() {
}
function addSound(aSoundLinkage_str) {
globalSound_snd = new Sound(this);
var _local6 = ("sndHolder_" + String(sounds_array.length)) + "_mc";
var _local4 = thisMC.getNextHighestDepth();
var _local5 = thisMC.createEmptyMovieClip(_local6, _local4);
theSoundClipMC = _local5;
var _local3 = MovieClip(theSoundClipMC);
var _local2 = new Sound(_local3);
_local2.attachSound(aSoundLinkage_str);
sounds_array.push(_local3);
var _local7 = new com.managers.SoundDataObject(aSoundLinkage_str, _local2);
sounds_array.push(_local7);
}
function getSound(aSoundLinkage_str) {
var _local2;
var _local6 = sounds_array.length;
_local2 = 0;
while (_local2 < _local6) {
var _local3 = sounds_array[_local2];
var _local5 = _local3.__get__name();
if (aSoundLinkage_str == _local5) {
var _local4 = _local3.__get__sound();
return(_local4);
}
_local2++;
}
}
function playSound(aSoundLinkage_str, aOffset_num, aLoopCount_num) {
trace((((("playSound = " + aSoundLinkage_str) + " ") + aOffset_num) + " ") + aLoopCount_num);
stopSound(aSoundLinkage_str);
var _local2 = getSound(aSoundLinkage_str);
_local2.start(aOffset_num, aLoopCount_num);
trace("tSound_snd = " + _local2);
}
function stopSound(aSoundLinkage_str) {
var _local2 = getSound(aSoundLinkage_str);
_local2.stop(aSoundLinkage_str);
}
function setSoundVolume(aSoundLinkage_str, aVolume_num) {
var _local2 = getSound(aSoundLinkage_str);
_local2.setVolume(aVolume_num);
}
function getSoundVolume(aSoundLinkage_str) {
var _local2 = getSound(aSoundLinkage_str);
return(_local2.getVolume());
}
function tweenSoundVolume(aSoundLinkage_str, aTargetVolume_num, aNumberOfFrames) {
trace(((((("*****tweenSoundVolume(" + aSoundLinkage_str) + ",") + aTargetVolume_num) + ",") + aNumberOfFrames) + ")");
trace("aSoundLinkage_str = " + aSoundLinkage_str);
trace("aTargetVolume_num = " + aTargetVolume_num);
trace("aNumberOfFrames = " + aNumberOfFrames);
var _local3 = getSoundVolume(aSoundLinkage_str);
trace("tCurrentVolume = " + _local3);
if (_local3 == undefined) {
trace("tCurrentVolume == undefined");
} else {
var _local5 = aTargetVolume_num;
trace("tTargetVolume = " + _local5);
var _local6 = Math.abs(_local3 - _local5);
if (_local6 < aNumberOfFrames) {
_local6 = aNumberOfFrames;
}
trace("tDifference = " + _local6);
var _local8 = 1;
if (_local3 < _local5) {
_local8 = 1;
} else if (_local3 > _local5) {
_local8 = -1;
} else {
trace("tCurrentVolume == tTargetVolume");
}
var _local7 = _local6 / aNumberOfFrames;
trace("tUnModChangePerFrame = " + _local7);
if (_local7 < 1) {
trace("tUnModChangePerFrame<1");
_local7 = 1;
}
var _local13 = _local7 * _local8;
trace("tChangePerFrame = " + _local13);
var _local12 = ("tweenHolder_" + aSoundLinkage_str) + "_mc";
trace("tSoundTweenHolderName_str = " + _local12);
trace("this = " + this);
var _local11 = thisMC.getNextHighestDepth();
trace("tNextDepth = " + _local11);
var _local14 = thisMC.createEmptyMovieClip(_local12, _local11);
trace("soundMCTweenThing = " + _local14);
var _local2 = MovieClip(_local14);
trace("tTweenMCThing = " + _local2);
_local2.ref = this;
_local2.targetVolume = _local5;
_local2.modNumber = _local8;
_local2.soundLinkage = aSoundLinkage_str;
_local2.changePerFrame = _local13;
_local2.onEnterFrame = function () {
trace("this.soundLinkage " + this.soundLinkage);
var _local2 = this.ref.getSoundVolume(this.soundLinkage);
trace((("this = " + this) + "tCurrentSoundVolume ") + _local2);
if (this.modNumber > 0) {
trace("done: this.modNumber<0");
trace("this.modNumber>0");
if (_local2 > this.targetVolume) {
trace("tCurrentSoundVolume>this.targetVolume");
this.onEnterFrame = null;
}
} else if (this.modNumber < 0) {
trace("done: this.modNumber<0");
if (_local2 < this.targetVolume) {
trace("tCurrentSoundVolume<this.targetVolume");
this.onEnterFrame = null;
}
} else {
trace("this.modNumber == 0 in Sound Manager, something is broken");
}
trace("tCurrentSoundVolume = " + _local2);
var _local3 = _local2 + this.changePerFrame;
trace("tNewSoundVolume = " + _local3);
this.ref.setSoundVolume(aSoundLinkage_str, _local3);
};
}
trace("*****tweenSoundVolume end");
}
function setGlobalVolume(aVolume_num) {
globalSound_snd.setVolume(aVolume_num);
}
}
Symbol 404 MovieClip [__Packages.com.managers.SoundDataObject] Frame 0
class com.managers.SoundDataObject extends Object
{
var name_str, sound_snd;
function SoundDataObject (aSoundName_str, aSound_snd) {
super();
name_str = aSoundName_str;
sound_snd = aSound_snd;
}
function get sound() {
return(sound_snd);
}
function get name() {
return(name_str);
}
}
Symbol 405 MovieClip [__Packages.com.utilities.StatTracker] Frame 0
class com.utilities.StatTracker
{
var _trackingEnabled, __get__setTrackingEnabled;
function StatTracker () {
trace("StatTracker");
_trackingEnabled = false;
}
function init() {
}
function submitStat(aString) {
if (_trackingEnabled) {
var _local2 = ("javascript:urchinTracker('/flashtracking" + aString) + "');";
trace("tUrchinString = " + _local2);
getURL (_local2);
}
}
function set setTrackingEnabled(aBoolean) {
trace("setTrackingEnabled = " + aBoolean);
_trackingEnabled = aBoolean;
//return(__get__setTrackingEnabled());
}
}
Symbol 406 MovieClip [__Packages.com.utilities.MyRandom] Frame 0
class com.utilities.MyRandom
{
function MyRandom () {
}
static function roll(minVal, maxVal) {
return(minVal + Math.floor(Math.random() * ((maxVal + 1) - minVal)));
}
}
Symbol 85 Button
on (press) {
gotoAndPlay ("continue1");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 87 Button
on (release) {
getURL ("http://www.goarmy.com/", "_blank");
}
Symbol 97 Button
on (press) {
gotoAndPlay ("continue2");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 106 Button
on (press) {
gotoAndPlay ("continue3");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 112 Button
on (press) {
gotoAndPlay ("continue4");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 120 Button
on (press) {
gotoAndPlay ("continue5");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 127 Button
on (press) {
gotoAndPlay ("continue6");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 134 Button
on (press) {
gotoAndPlay ("continue7");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 141 Button
on (press) {
gotoAndPlay ("continue8");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 148 Button
on (press) {
gotoAndPlay ("continue9");
_root.myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 153 MovieClip [TransitionMC] Frame 14
stop();
Symbol 153 MovieClip [TransitionMC] Frame 34
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 52
stop();
Symbol 153 MovieClip [TransitionMC] Frame 72
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 90
stop();
Symbol 153 MovieClip [TransitionMC] Frame 110
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 123
stop();
Symbol 153 MovieClip [TransitionMC] Frame 143
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 161
stop();
Symbol 153 MovieClip [TransitionMC] Frame 181
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 199
stop();
Symbol 153 MovieClip [TransitionMC] Frame 219
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 232
stop();
Symbol 153 MovieClip [TransitionMC] Frame 252
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 270
stop();
Symbol 153 MovieClip [TransitionMC] Frame 290
_root.myGameClass.doneWithTransition();
Symbol 153 MovieClip [TransitionMC] Frame 308
stop();
Symbol 153 MovieClip [TransitionMC] Frame 328
_root.myGameClass.doneWithTransition();
Symbol 163 MovieClip Frame 1
stop();
Symbol 163 MovieClip Frame 70
stop();
Symbol 178 MovieClip Frame 1
stop();
Symbol 322 Button
on (press) {
play();
}
Symbol 333 Button
on (press) {
play();
myGameClass.soundManager_mc.playSound("menu_select_one", 0, 1);
}
Symbol 334 Button
on (press) {
myGameClass.STAGE_BUTTON_Play();
}
Symbol 338 Button
on (release) {
myGameClass.STAGE_BUTTON_GO_TO_SITE();
}
Symbol 350 Button
on (press) {
myGameClass.STAGE_BUTTON_Lose();
}
Symbol 352 Button
on (press) {
myGameClass.STAGE_BUTTON_WinRound();
}
Symbol 360 Button
on (press) {
_root.myGameClass.STAGE_BUTTON_NextRound();
}
Symbol 361 MovieClip Frame 18
stop();
Symbol 365 Button
on (press) {
_root.myGameClass.STAGE_BUTTON_PlayAgain();
}
Symbol 366 MovieClip Frame 18
stop();
Symbol 376 Button
on (press) {
_root.myGameClass.STAGE_BUTTON_NextRound();
}
Symbol 384 Button
on (press) {
_root.myGameClass.STAGE_BUTTON_NextRound();
}
Symbol 389 Button
on (press) {
_root.myGameClass.STAGE_BUTTON_PlayAgain();
}