Frame 1
stop();
Instance of Symbol 15 MovieClip in Frame 1
onClipEvent (load) {
var nSpeed = 2;
var nCurrLoad = 0;
var nRealLoad = 0;
}
onClipEvent (enterFrame) {
nRealLoad = (this._parent.getBytesLoaded() / this._parent.getBytesTotal()) * 100;
if (nRealLoad > (nCurrLoad + nSpeed)) {
nCurrLoad = nCurrLoad + nSpeed;
} else {
nCurrLoad = nRealLoad;
}
mcTitle.gotoAndStop(nCurrLoad + 1);
if ((nCurrLoad == 100) && (this._parent.getBytesTotal() > 100)) {
_root.gotoAndStop("Game");
}
}
Frame 20
new Main(this);
stop();
Symbol 117 MovieClip [__Packages.Main] Frame 0
class Main
{
static var oCTRL;
var mcRef, oLevel, oHud, oTitle, bGameOn;
function Main (_mcRef) {
mcRef = _mcRef;
oCTRL = this;
var _local2 = mcRef.createEmptyMovieClip("mcSound" + mcRef.getNextHighestDepth(), mcRef.getNextHighestDepth());
new library.SoundManager(_local2);
oLevel = new Level(mcRef.mcLevel);
oHud = new Hud(mcRef.mcHud);
oTitle = new Title(mcRef.mcTitle, library.Delegate.create(this, start));
mcRef.onEnterFrame = library.Delegate.create(this, enterFrame);
}
function init() {
bGameOn = false;
}
function enterFrame() {
if (bGameOn) {
bGameOn = !oHud.enterFrame(bGameOn);
}
oLevel.enterFrame(bGameOn, oHud.__get__level());
}
function start() {
bGameOn = true;
oTitle.hide();
oLevel.start();
oHud.start();
library.SoundManager.__get__Instance().playSong(sMUSIC_GAME);
}
function end() {
bGameOn = false;
oTitle.show();
oLevel.end();
oHud.end();
}
static function get Instance() {
return(oCTRL);
}
function get hud() {
return(oHud);
}
function get level() {
return(oLevel);
}
static var bSOUND_ON = true;
static var bSINGLE_MIDDLE_TEST = false;
static var bMIDDLE_TEST = false;
static var NX_SIZE = 640;
static var NY_SIZE = 600;
static var sMUSIC_GAME = "";
}
Symbol 118 MovieClip [__Packages.Hud] Frame 0
class Hud
{
var mcRef, nHighScore, nLevel, nKills, nScore;
function Hud (_mcRef) {
mcRef = _mcRef;
nHighScore = 0;
end();
}
function enterFrame() {
}
function start() {
nLevel = 1;
nKills = 0;
nScore = 0;
mcRef.txtScore.text = "000";
mcRef.txtHighScore.text = nHighScore;
mcRef.txtLevel.text = nLevel;
}
function end() {
nLevel = 1;
nKills = 0;
}
function addKill(_nScore) {
nScore = nScore + _nScore;
nHighScore = Math.max(nHighScore, nScore);
nKills++;
nLevel = Math.ceil((nKills + 1) / nKILLS_PER_LEVEL);
mcRef.txtScore.text = nScore;
mcRef.txtHighScore.text = nHighScore;
mcRef.txtLevel.text = nLevel;
}
function nextLevel() {
nLevel++;
}
function get level() {
return(nLevel);
}
static var nKILLS_PER_LEVEL = 10;
}
Symbol 119 MovieClip [__Packages.Level] Frame 0
class Level
{
var mcRef, oPlayer, aBullets, aVictims, aEasterEggs, aEnnemies, oControls, nNextSpawn;
function Level (_mcRef) {
mcRef = _mcRef;
oPlayer = new Player(mcRef.mcPlayer, library.Delegate.create(this, fireBullet), library.Delegate.create(this, unStunned));
aBullets = new Array();
aVictims = new Array();
aEasterEggs = new Array();
var _local2;
_local2 = 1;
while (_local2 <= nTOTAL_VICTIMS) {
aVictims.push(new Victim(mcRef.mcVictim["mcVictim" + _local2]));
_local2++;
}
aEasterEggs.push(new EasterEgg(mcRef.mcEasterEggSign));
aEnnemies = new Array();
oControls = new Controls();
}
function enterFrame(_bGameOn, _nLevel) {
if (_bGameOn) {
oPlayer.move(oControls.getMovement());
if (oControls.mousePressed()) {
oPlayer.shoot();
}
} else {
oPlayer.moveDemo(aEnnemies);
}
oPlayer.enterFrame();
var _local2;
var _local3;
_local2 = 0;
while (_local2 < aBullets.length) {
aBullets[_local2].enterFrame();
if (aBullets[_local2].active) {
if (aBullets[_local2].Mc._y < -100) {
aBullets[_local2].Mc.removeMovieClip();
aBullets.splice(_local2, 1);
}
} else if (aBullets[_local2].Mc._name == undefined) {
aBullets.splice(_local2, 1);
}
_local2++;
}
var _local5;
var _local6;
if (oControls.__get__movingLeft()) {
_local5 = -1;
_local2 = aEnnemies.length - 1;
_local6 = -1;
} else {
_local5 = aEnnemies.length;
_local2 = 0;
_local6 = 1;
}
while (_local2 != _local5) {
_local3 = 0;
while (_local3 != aBullets.length) {
if (aEnnemies[_local2].bulletHit(aBullets[_local3].Mc._x, aBullets[_local3].Mc._y)) {
aBullets[_local3].setHit();
if (_bGameOn) {
library.SoundManager.__get__Instance().playSFX("splash");
Main.__get__Instance().__get__hud().addKill(aEnnemies[_local2].score);
}
aVictims[aEnnemies[_local2].victim].ennemyDisappear();
break;
}
_local3++;
}
if (aEnnemies[_local2].playerHit(oPlayer.__get__Mc()._x, oPlayer.__get__lastPosX(), oPlayer.__get__Mc()._y, oControls.__get__stunned())) {
if (aEnnemies[_local2].isStunned) {
oPlayer.setStun(aEnnemies[_local2].stunTime);
} else {
oPlayer.setMeleeAttack(aEnnemies[_local2].stunTime, aEnnemies[_local2].Mc._x);
oControls.__set__setPosX(oPlayer.__get__Mc()._x);
}
aVictims[aEnnemies[_local2].victim].ennemyDisappear();
Main.__get__Instance().__get__hud().addKill(aEnnemies[_local2].meleeScore);
oControls.__set__stunned(true);
}
aEnnemies[_local2].enterFrame();
if (aEnnemies[_local2].Mc._name == undefined) {
aEnnemies.splice(_local2, 1);
}
_local2 = _local2 + _local6;
}
_local2 = 0;
while (_local2 < aEasterEggs.length) {
_local3 = 0;
while (_local3 != aBullets.length) {
if (aEasterEggs[_local2].tryShot(aBullets[_local3].Mc._x, aBullets[_local3].Mc._y)) {
aBullets[_local3].setSignHit();
}
_local3++;
}
_local2++;
}
_local2 = 0;
while (_local2 < nTOTAL_VICTIMS) {
aVictims[_local2].enterFrame();
_local2++;
}
trySpawn(_nLevel);
}
function start() {
oControls.start();
oPlayer.start();
while (aBullets.length > 0) {
aBullets[0].Mc.removeMovieClip();
aBullets.splice(0, 1);
}
while (aEnnemies.length > 0) {
aEnnemies[0].Mc.removeMovieClip();
aEnnemies.splice(0, 1);
}
var _local2;
_local2 = 0;
while (_local2 < nTOTAL_VICTIMS) {
aVictims[_local2].start();
_local2++;
}
nextSpawn(1);
}
function end() {
oControls.end();
oPlayer.end();
}
function ennemyEnd(_nVictim) {
aVictims[_nVictim].ennemyHit();
}
function unStunned() {
oControls.__set__stunned(false);
}
function fireBullet() {
var _local2 = mcRef.mcBullet.attachMovie("mcBullet", "mcBullet" + mcRef.mcBullet.getNextHighestDepth(), mcRef.mcBullet.getNextHighestDepth());
_local2._x = oPlayer.__get__Mc()._x;
_local2._y = oPlayer.__get__Mc()._y;
aBullets.push(new Bullet(_local2));
}
function trySpawn(_nLevel) {
if (!Main.bSINGLE_MIDDLE_TEST) {
if (getTimer() >= nNextSpawn) {
nextSpawn(_nLevel);
var _local4 = nTOTAL_VICTIMS;
if (Main.bMIDDLE_TEST) {
_local4 = _local4 - 2;
}
if (aEnnemies.length < _local4) {
var _local6 = mcRef.mcFoe.attachMovie("mcFoe1", "mcFoe1" + mcRef.mcFoe.getNextHighestDepth(), mcRef.mcFoe.getNextHighestDepth());
var _local2;
var _local5;
do {
_local2 = Math.floor(Math.random() * _local4);
if (Main.bMIDDLE_TEST) {
_local2++;
}
} while (!aVictims[_local2].getEnnemy());
_local6._x = aVictims[_local2].Mc._x;
_local6._y = -100;
_local5 = Ennemy1.nSPEEDX + (_nLevel * Ennemy1.nSPEEDX_INCREASE);
var _local8 = false;
var _local3;
_local3 = 0;
while (_local3 < aEnnemies.length) {
if (_local2 < aEnnemies[_local3].victim) {
break;
}
_local3++;
}
aEnnemies.splice(_local3, 0, new Ennemy1(_local6, _local5, _local2));
}
}
} else if (aEnnemies.length == 0) {
var _local6 = mcRef.mcFoe.attachMovie("mcFoe1", "mcFoe1" + mcRef.mcFoe.getNextHighestDepth(), mcRef.mcFoe.getNextHighestDepth());
_local6._x = aVictims[4].Mc._x;
_local6._y = -100;
var _local5 = Ennemy1.nSPEEDX + (_nLevel * Ennemy1.nSPEEDX_INCREASE);
aEnnemies.splice(0, 0, new Ennemy1(_local6, _local5, 4));
}
}
function nextSpawn(_nLevel) {
nNextSpawn = ((getTimer() + (Math.random() * (nHIGH_SPAWN - nLOW_SPAWN))) + nLOW_SPAWN) - (nLEVEL_CHANGE * _nLevel);
}
static var nLOW_SPAWN = 1000;
static var nHIGH_SPAWN = 1400;
static var nLEVEL_CHANGE = 100;
static var nTOTAL_VICTIMS = 8;
}
Symbol 120 MovieClip [__Packages.library.State] Frame 0
class library.State
{
var mcRef, sState;
function State (_mcRef) {
mcRef = _mcRef;
}
function setState(_sState) {
sState = _sState;
mcRef.gotoAndStop(sState);
loadState(sState);
}
function setMc(_mcRef) {
mcRef = _mcRef;
setState(sState);
}
function pause() {
mcRef.mcState.stop();
}
function resume() {
mcRef.mcState.play();
}
function enterFrame() {
this["do" + sState]();
}
function loadState(_sState) {
this["start" + sState]();
}
function isStateComplete() {
if (mcRef.mcState._currentframe == mcRef.mcState._totalframes) {
this["end" + sState]();
}
return(mcRef.mcState._currentframe == mcRef.mcState._totalframes);
}
function get Mc() {
return(mcRef);
}
}
Symbol 121 MovieClip [__Packages.Player] Frame 0
class Player extends library.State
{
var fShoot, fUnstunned, bMouseDown, bGameOn, nStunTime, setState, bShooting, isStateComplete, mcRef, nLastPosX, nLastPosAttack;
function Player (_mcRef, _fShoot, _fUnstunned) {
super(_mcRef);
fShoot = _fShoot;
fUnstunned = _fUnstunned;
bMouseDown = false;
bGameOn = false;
nStunTime = 0;
setState(sSTATE_IDLE);
}
function startShoot() {
bShooting = true;
}
function startDashShoot() {
bShooting = true;
}
function startIdle() {
bShooting = false;
fUnstunned();
}
function startDash() {
bShooting = false;
fUnstunned();
}
function doIdle() {
}
function doShoot() {
if (isStateComplete()) {
setState(sSTATE_IDLE);
}
}
function doDashShoot() {
if (isStateComplete()) {
setState(sSTATE_DASH);
}
}
function doStun() {
if (isStateComplete()) {
mcRef.mcState.gotoAndStop(mcRef._totalframes - 1);
}
if (getTimer() >= nStunTime) {
setState(sSTATE_IDLE);
start();
}
}
function doSideAttack() {
if (isStateComplete()) {
nStunTime = getTimer();
setState(sSTATE_IDLE);
}
}
function start() {
}
function end() {
mcRef.onMouseDown = undefined;
mcRef.onMouseUp = undefined;
}
function setStun(_nStunTime) {
nStunTime = getTimer() + _nStunTime;
setState(sSTATE_STUNNED);
}
function setMeleeAttack(_nStunTime, _nX) {
if (_nX > nLastPosX) {
mcRef._x = _nX;
mcRef._xscale = 100;
} else {
mcRef._x = _nX;
mcRef._xscale = -100;
}
nStunTime = getTimer() + _nStunTime;
setState(sSTATE_SIDE_ATTACK);
}
function moveDemo(_aEnnemies) {
var _local5;
var _local4 = 0;
var _local2;
_local2 = 0;
while (_local2 < _aEnnemies.length) {
if (_local4 < _aEnnemies[_local2].Mc._y) {
_local4 = _aEnnemies[_local2].Mc._y;
_local5 = _local2;
}
_local2++;
}
var _local6 = _aEnnemies[_local5].Mc._y > 150;
move(_aEnnemies[_local5].Mc._x);
if (_local6 && (nLastPosAttack != mcRef._x)) {
shoot();
nLastPosAttack = mcRef._x;
}
}
function move(_nX) {
nLastPosX = mcRef._x;
if (nStunTime <= getTimer()) {
var _local3 = (_nX - mcRef._x) / Math.abs(_nX - mcRef._x);
updateState(Math.abs(mcRef._x - _nX));
if (nMOVE_SPEED <= Math.abs(mcRef._x - _nX)) {
mcRef._x = mcRef._x + (_local3 * nMOVE_SPEED);
} else {
mcRef._x = _nX;
}
mcRef._xscale = _local3 * 100;
}
}
function shoot() {
library.SoundManager.__get__Instance().playSFX("stroke");
bShooting = true;
updateState(-1);
fShoot();
}
function updateState(_nSpeed) {
if (bShooting) {
if (_nSpeed <= nDASH_STATE_SPEED) {
setState(sSTATE_SHOOT);
} else {
setState(sSTATE_DASHSHOOT);
}
} else if (_nSpeed <= nDASH_STATE_SPEED) {
setState(sSTATE_IDLE);
} else {
setState(sSTATE_DASH);
}
}
function get lastPosX() {
return(nLastPosX);
}
static var sSFX_SHOOT = "stroke";
var nMOVE_SPEED = 30;
var nDASH_STATE_SPEED = 5;
var sSTATE_IDLE = "Idle";
var sSTATE_SHOOT = "Shoot";
var sSTATE_SIDE_ATTACK = "SideAttack";
var sSTATE_STUNNED = "Stun";
var sSTATE_DASH = "Dash";
var sSTATE_DASHSHOOT = "DashShoot";
}
Symbol 122 MovieClip [__Packages.library.SoundManager] Frame 0
class library.SoundManager
{
static var oCTRL;
var mcRef, oSound, nFade, nVolume, sCurrentSong;
function SoundManager (_mcRef) {
mcRef = _mcRef;
oSound = new Sound();
oCTRL = this;
nFade = 0;
nVolume = 100;
mcRef.onEnterFrame = library.Delegate.create(this, enterFrame);
}
function enterFrame() {
if (nFade != 0) {
nVolume = nVolume + nFade;
nVolume = Math.min(nVolume, 100);
nVolume = Math.max(nVolume, 0);
oSound.setVolume(nVolume);
if (nVolume == 0) {
nFade = 6;
oSound.stop();
delete oSound;
oSound = new Sound();
oSound.attachSound(sCurrentSong);
oSound.start(0, 9999);
} else if (nVolume == 100) {
nFade = 0;
}
}
}
function playSong(_sCurrentSong) {
if (Main.bSOUND_ON) {
if (sCurrentSong != undefined) {
nFade = -6;
} else {
oSound.attachSound(_sCurrentSong);
oSound.start(0, 9999);
}
sCurrentSong = _sCurrentSong;
}
}
function playSFX(_sSFX) {
if (Main.bSOUND_ON) {
var _local1 = new Sound();
_local1.attachSound(_sSFX);
_local1.start(0, 1);
}
}
static function get Instance() {
return(oCTRL);
}
}
Symbol 123 MovieClip [__Packages.library.Delegate] Frame 0
class library.Delegate extends Object
{
var func;
function Delegate (f) {
super();
func = f;
}
static function create(obj, func) {
var _local2 = function () {
var _local3 = arguments.callee.target;
var _local4 = arguments.callee.func;
var _local2 = arguments.callee.arg;
_local2 = _local2.concat(arguments);
return(_local4.apply(_local3, _local2));
};
_local2.target = obj;
_local2.func = func;
_local2.arg = arguments.slice(2);
return(_local2);
}
function createDelegate(obj) {
return(create(obj, func));
}
}
Symbol 124 MovieClip [__Packages.Controls] Frame 0
class Controls
{
var bStunned, bGameOn, bMouseDown, bMousePressed, nPosX, nLastPosX, __get__setPosX;
function Controls () {
bStunned = false;
bGameOn = false;
}
function start() {
bGameOn = true;
bStunned = false;
bMouseDown = false;
bMousePressed = false;
_root.onMouseDown = library.Delegate.create(this, mouseDown);
_root.onMouseUp = library.Delegate.create(this, mouseUp);
}
function end() {
bGameOn = false;
_root.onMouseDown = undefined;
_root.onMouseUp = undefined;
}
function getMovement() {
if (bGameOn) {
mouseMove();
}
return(nPosX);
}
function mouseMove() {
if (!bStunned) {
var _local3 = _root._xmouse;
_local3 = Math.max(Math.min(_local3, nRIGHT_EDGE), nLEFT_EDGE);
nLastPosX = nPosX;
nPosX = _local3;
} else {
nLastPosX = nPosX;
}
}
function mouseDown() {
var _local2 = false;
if (!bStunned) {
if (!bMouseDown) {
bMousePressed = true;
bMouseDown = true;
}
}
}
function mouseUp() {
bMouseDown = false;
}
function mousePressed() {
var _local2 = bMousePressed;
bMousePressed = false;
return(_local2);
}
function get stunned() {
return(bStunned);
}
function set stunned(_bStunned) {
bStunned = _bStunned;
//return(stunned);
}
function set setPosX(_nPosX) {
nPosX = _nPosX;
nLastPosX = _nPosX;
//return(__get__setPosX());
}
function get lastPosX() {
return(nLastPosX);
}
function get movingLeft() {
return(nPosX < nLastPosX);
}
static var nLEFT_EDGE = 60;
static var nRIGHT_EDGE = 567;
}
Symbol 125 MovieClip [__Packages.Victim] Frame 0
class Victim extends library.State
{
var bEnnemy, setState, nHealth, nLastTimer, nLevel;
function Victim (_mcRef) {
super(_mcRef);
bEnnemy = false;
setState(sSTATE_IDLE);
}
function startDead() {
Main.__get__Instance().end();
}
function doSex1() {
nHealth = nHealth - (getTimer() - nLastTimer);
nLastTimer = getTimer();
if (nHealth <= 0) {
nHealth = nHealth + nHEALTH_PER_LEVEL;
nLevel++;
setState(sSTATE_SEX2);
}
}
function doSex2() {
nHealth = nHealth - (getTimer() - nLastTimer);
nLastTimer = getTimer();
if (nHealth <= 0) {
nHealth = nHealth + nHEALTH_PER_LEVEL;
nLevel++;
setState(sSTATE_SEX3);
}
}
function doSex3() {
nHealth = nHealth - (getTimer() - nLastTimer);
nLastTimer = getTimer();
if (nHealth <= 0) {
setState(sSTATE_DEAD);
}
}
function getEnnemy() {
var _local2 = false;
if (!bEnnemy) {
bEnnemy = true;
_local2 = true;
}
return(_local2);
}
function ennemyHit() {
switch (nLevel) {
case 1 :
setState(sSTATE_SEX1);
break;
case 2 :
setState(sSTATE_SEX2);
break;
case 3 :
setState(sSTATE_SEX3);
}
nLastTimer = getTimer();
}
function ennemyDisappear() {
bEnnemy = false;
setState(sSTATE_IDLE);
}
function start() {
nHealth = nHEALTH_PER_LEVEL;
setState(sSTATE_IDLE);
bEnnemy = false;
nLevel = 1;
}
static var nTOTAL_LEVELS = 3;
static var nHEALTH_PER_LEVEL = 1200;
var sSTATE_IDLE = "Idle";
var sSTATE_SEX1 = "Sex1";
var sSTATE_SEX2 = "Sex2";
var sSTATE_SEX3 = "Sex3";
var sSTATE_DEAD = "Dead";
}
Symbol 126 MovieClip [__Packages.EasterEgg] Frame 0
class EasterEgg extends library.State
{
var setState, mcRef;
function EasterEgg (_mcRef) {
super(_mcRef);
setState(sSTATE_HIDDEN);
}
function tryShot(_nX, _nY) {
var _local2 = false;
if (mcRef.hitTest(_nX, _nY)) {
setState(sSTATE_IDLE);
_local2 = true;
}
return(_local2);
}
static var sSTATE_IDLE = "Idle";
static var sSTATE_HIDDEN = "Hidden";
}
Symbol 127 MovieClip [__Packages.Bullet] Frame 0
class Bullet extends library.State
{
var setState, bActive, mcRef, isStateComplete;
function Bullet (_mcRef) {
super(_mcRef);
setState(sSTATE_IDLE);
}
function startIdle() {
bActive = true;
mcRef.mcState.gotoAndStop(Math.ceil(Math.random() * mcRef.mcState._totalframes));
}
function startHit() {
bActive = false;
}
function startSignHit() {
bActive = false;
}
function doIdle() {
mcRef._y = mcRef._y - nSPEED_Y;
}
function doHit() {
mcRef._y = mcRef._y - (nSPEED_Y / 10);
if (isStateComplete()) {
mcRef.removeMovieClip();
}
}
function doSignHit() {
mcRef._y = mcRef._y - (nSPEED_Y / 10);
if (isStateComplete()) {
mcRef.removeMovieClip();
}
}
function setHit() {
setState(sSTATE_HIT);
bActive = false;
}
function setSignHit() {
setState(sSTATE_SIGN_HIT);
bActive = false;
}
function get active() {
return(bActive);
}
static var nSPEED_Y = 25;
static var sSTATE_IDLE = "Idle";
static var sSTATE_HIT = "Hit";
static var sSTATE_SIGN_HIT = "SignHit";
}
Symbol 128 MovieClip [__Packages.Ennemy] Frame 0
class Ennemy extends library.State
{
var nSpeedX, aScore, nMeleeScore, nHitZone, nVictim, setState, mcRef, isStateComplete, sState;
function Ennemy (_mcRef, _nSpeedX, _nHitZone, _aScore, _nMeleeScore, _nVictim) {
super(_mcRef);
nSpeedX = _nSpeedX;
aScore = _aScore;
nMeleeScore = _nMeleeScore;
nHitZone = _nHitZone;
nVictim = _nVictim;
setState(sSTATE_WALK);
}
function doWalk() {
mcRef._y = mcRef._y + nSpeedX;
if (mcRef._y >= nEDGE_Y) {
mcRef._y = nEDGE_Y;
setState(sSTATE_SEX);
Main.__get__Instance().__get__level().ennemyEnd(nVictim);
}
}
function doStunned() {
if (isStateComplete()) {
mcRef.removeMovieClip();
}
}
function startDie() {
}
function doDie() {
if (isStateComplete()) {
mcRef.removeMovieClip();
}
}
function doMeleeDie() {
if (isStateComplete()) {
mcRef.removeMovieClip();
}
}
function bulletHit(_nX, _nY) {
var _local2 = false;
if (sState == sSTATE_WALK) {
if ((((mcRef._y + nHitZone) > _nY) && ((mcRef._x - (mcRef._width / 2)) <= _nX)) && ((mcRef._x + (mcRef._width / 2)) >= _nX)) {
setState(sSTATE_DIE);
_local2 = true;
}
}
return(_local2);
}
function playerHit(_nX, _nX2, _nY, _bStunned) {
var _local2 = false;
if (!_bStunned) {
var _local3 = Math.min(_nX, _nX2);
var _local4 = Math.max(_nX, _nX2);
if (sState == sSTATE_WALK) {
if ((((mcRef._y + mcRef._height) >= _nY) && ((mcRef._x - (mcRef._width / 2)) <= _local4)) && ((mcRef._x + (mcRef._width / 2)) >= _local3)) {
if ((mcRef._y + nHitZone) <= _nY) {
setState(sSTATE_STUNNED);
_local2 = true;
} else if (((mcRef._x - (mcRef._width / 2)) <= _local4) && ((mcRef._x + (mcRef._width / 2)) >= _local3)) {
setState(sSTATE_MELEE_DIE);
_local2 = true;
}
}
} else if (sState == sSTATE_SEX) {
if (((mcRef._x - (mcRef._width / 2)) <= _local4) && ((mcRef._x + (mcRef._width / 2)) >= _local3)) {
_local2 = true;
setState(sSTATE_MELEE_DIE);
}
}
if ((sState == sSTATE_MELEE_DIE) && (_local2)) {
if (mcRef._x > _nX2) {
mcRef._xscale = -100;
}
}
}
return(_local2);
}
function get score() {
var _local4 = 0;
var _local2 = mcRef._y - nSCORE_GRADATION;
var _local3 = 0;
while (_local2 > 0) {
_local2 = _local2 - nSCORE_GRADATION;
_local3++;
}
return(aScore[_local3]);
}
function get meleeScore() {
return(nMeleeScore);
}
function get victim() {
return(nVictim);
}
function get stunTime() {
return(1000);
}
function get isStunned() {
return(sState == sSTATE_STUNNED);
}
var nSCORE_GRADATION = 170;
var nEDGE_Y = 475;
var sSTATE_WALK = "Walk";
var sSTATE_SEX = "Sex";
var sSTATE_DIE = "Die";
var sSTATE_STUNNED = "Stunned";
var sSTATE_MELEE_DIE = "MeleeDie";
}
Symbol 129 MovieClip [__Packages.Ennemy1] Frame 0
class Ennemy1 extends Ennemy
{
function Ennemy1 (_mcRef, _nSpeed, _nVictim) {
super(_mcRef, _nSpeed, nHIT_ZONE, aSCORE, nMELEE_SCORE, _nVictim, nSTUN_TIME, nSTUN_TIME_INCREASE);
}
function get stunTime() {
return(nSTUN_TIME + (nSTUN_TIME_INCREASE * Main.__get__Instance().__get__hud().__get__level()));
}
static var nSPEEDX = 3;
static var nSPEEDX_INCREASE = 1;
static var nHIT_ZONE = 60;
static var aSCORE = new Array(100, 300, 500);
static var nMELEE_SCORE = 50;
static var nSTUN_TIME = 1000;
static var nSTUN_TIME_INCREASE = 100;
}
Symbol 130 MovieClip [__Packages.Title] Frame 0
class Title extends library.State
{
var fFunction, mcRef;
function Title (_mcRef, _fFunction) {
super(_mcRef);
fFunction = _fFunction;
mcRef.onMouseDown = library.Delegate.create(this, mouseDown);
}
function mouseDown() {
fFunction();
}
function show() {
mcRef._visible = true;
mcRef.onMouseDown = library.Delegate.create(this, mouseDown);
}
function hide() {
mcRef._visible = false;
mcRef.onMouseDown = undefined;
delete mcRef.onMouseDown;
}
}