Instance of Symbol 12 MovieClip in Frame 2
onClipEvent (load) {
this.barra._xscale = "1";
_parent.stop();
}
onClipEvent (enterFrame) {
this.barra._xscale = (_parent.getBytesloaded() * 100) / _parent.getBytesTotal();
if (_parent.getBytesLoaded() == _parent.getBytesTotal()) {
_parent.play();
}
}
Frame 3
stop();
Frame 4
stop();
function crearrocas(numeroderocas) {
n = 1;
do {
attachMovie("roca", "rocaMC" + n, n);
n++;
} while (n < (numeroderocas + 1));
}
function destruirrocas(numeroderocas) {
n = 1;
do {
removeMovieClip("rocaMC" + n);
n++;
} while (n < (numeroderocas + 1));
}
crearrocas(2);
Instance of Symbol 48 MovieClip "modulo2MC" in Frame 4
onClipEvent (enterFrame) {
if (hitTest(_root.jugadorMC.areacolision) && (!descenso)) {
enganchado = true;
}
if (enganchado) {
if ((((Math.floor(_root.modulocentralMC._x) - 10) < Math.floor(_x)) && (Math.floor(_x) < (Math.floor(_root.modulocentralMC._x) + 10))) && (_y < _root.modulocentralMC._y)) {
descenso = true;
enganchado = false;
}
_x = _root.jugadorMC._x;
_y = (_root.jugadorMC._y + 40);
}
if (descenso) {
_y = (_y + 3);
_x = _root.modulocentralMC._x;
if (hitTest(_root.modulocentralMC)) {
_visible = false;
_y = 10000;
_root.modulocentralMC.nextFrame();
_root.modulo1MC.activado = true;
}
}
}
Instance of Symbol 50 MovieClip "modulo1MC" in Frame 4
onClipEvent (enterFrame) {
if (activado) {
if (hitTest(_root.jugadorMC.areacolision) && (!descenso)) {
enganchado = true;
}
if (enganchado) {
if ((((Math.floor(_root.modulocentralMC._x) - 10) < Math.floor(_x)) && (Math.floor(_x) < (Math.floor(_root.modulocentralMC._x) + 10))) && (_y < _root.modulocentralMC._y)) {
descenso = true;
enganchado = false;
}
_x = _root.jugadorMC._x;
_y = (_root.jugadorMC._y + 40);
}
if (descenso) {
_y = (_y + 3);
_x = _root.modulocentralMC._x;
if (hitTest(_root.modulocentralMC)) {
_visible = false;
_y = 10000;
_root.modulocentralMC.nextFrame();
_root.gasolinaMC.activado = true;
}
}
}
}
Instance of Symbol 52 MovieClip "gasolinaMC" in Frame 4
onClipEvent (load) {
_x = ((Math.random() * 450) + 50);
velocidad = 4;
descenso = false;
tocasuelo = false;
}
onClipEvent (enterFrame) {
if (activado) {
if ((!descenso) && (!tocasuelo)) {
n = 1;
do {
if (hitTest("_root.areacolisionMC" + n)) {
tocasuelo = true;
}
n++;
} while (n < 5);
_y = (_y + velocidad);
}
if (hitTest(_root.jugadorMC.areacolision) && (!descenso)) {
enganchado = true;
}
if (enganchado) {
if ((((Math.floor(_root.modulocentralMC._x) - 10) < Math.floor(_x)) && (Math.floor(_x) < (Math.floor(_root.modulocentralMC._x) + 10))) && (_y < _root.modulocentralMC._y)) {
descenso = true;
enganchado = false;
}
_x = _root.jugadorMC._x;
_y = (_root.jugadorMC._y + 45);
}
if (descenso) {
_y = (_y + velocidad);
_x = _root.modulocentralMC._x;
if (hitTest(_root.modulocentralMC)) {
_y = ((Math.random() * 1000) * -1);
_x = ((Math.random() * 450) + 50);
_root.modulocentralMC.nextFrame();
_root.gasolinaMC.descenso = false;
_root.gasolinaMC.tocasuelo = false;
}
}
}
}
Instance of Symbol 87 MovieClip "marcadoresMC" in Frame 4
onClipEvent (load) {
function restarvida() {
vidasN--;
vidas = vidasN;
if (vidasN == 0) {
_root.gameoverMC.play();
_root.jugadorMC.stop();
}
}
function sumarnivel() {
NivelN++;
nivel = nivelN;
if (9 < nivelN) {
_root.marcadoresMC.cero._visible = false;
}
}
function sumarpuntos(puntosasumar) {
puntos = puntos + puntosasumar;
}
vidasN = 3;
vidas = vidasN;
nivelN = 1;
nivel = nivelN;
puntos = 0;
}
Symbol 8 MovieClip [roca] Frame 1
stop();
Instance of Symbol 4 MovieClip in Symbol 8 MovieClip [roca] Frame 1
onClipEvent (load) {
_parent._x = Math.floor(Math.random() * 64) * -1;
_parent._y = Math.floor(Math.random() * 300) + 100;
limiteinferior = 414;
limitesuperior = 80;
limitederecho = 600;
limiteizquierdo = 0;
velocidadgiro = 2;
margen = 70;
direccionX = Math.floor(Math.random() * 2);
if (direccionX == 0) {
direccionX = -1;
}
direccionY = 1;
velocidadX = Math.floor(Math.random() * 2) + 3;
velocidadY = Math.floor(Math.random() * 2) + 2;
}
onClipEvent (enterFrame) {
if ((limiteinferior < _parent._y) || (_parent._y < limitesuperior)) {
direccionY = -direccionY;
}
if ((limitederecho + margen) < _parent._x) {
_parent._x = limiteizquierdo - margen;
} else if (_parent._x < (limiteizquierdo - margen)) {
_parent._x = limitederecho + margen;
}
_parent._x = _parent._x + (direccionX * velocidadX);
_parent._y = _parent._y + (direccionY * velocidadY);
_parent._rotation = _parent._rotation + (direccionX * 2);
}
Symbol 20 Button
on (release) {
play();
}
Symbol 46 MovieClip Frame 1
stop();
Symbol 46 MovieClip Frame 2
_root.marcadoresMC.sumarpuntos(100);
Symbol 46 MovieClip Frame 3
_root.marcadoresMC.sumarpuntos(100);
Symbol 46 MovieClip Frame 4
_root.marcadoresMC.sumarpuntos(100);
Symbol 46 MovieClip Frame 5
_root.marcadoresMC.sumarpuntos(100);
Symbol 46 MovieClip Frame 6
_root.gasolinaMC.activado = false;
_root.marcadoresMC.sumarpuntos(100);
Instance of Symbol 38 MovieClip in Symbol 46 MovieClip Frame 6
onClipEvent (enterFrame) {
if (hitTest(_root.jugadorMC.areacolision)) {
_root.jugadorMC._visible = false;
_parent.nextFrame();
}
}
Instance of Symbol 45 MovieClip in Symbol 46 MovieClip Frame 7
onClipEvent (load) {
_root.destruirrocas(_root.marcadoresMC.niveln + 2);
posYinicial = _y;
subir = true;
vuelta = 0;
}
onClipEvent (enterFrame) {
if (subir) {
if (vuelta == 70) {
vuelta = 0;
aceleracion = 0;
subir = false;
bajar = true;
}
vuelta++;
aceleracion++;
_y = (_y - aceleracion);
if (6 < aceleracion) {
aceleracion = 6;
}
}
if (bajar) {
if (vuelta == 70) {
_root.gasolinaMC.activado = true;
_root.marcadoresMC.sumarnivel();
_root.crearrocas(_root.marcadoresMC.niveln + 1);
vuelta = 0;
bajar = false;
_root.jugadorMC._visible = true;
_root.jugadorMC._x = 300;
_root.jugadorMC._y = 400;
_parent.gotoAndStop(3);
}
aceleracion++;
vuelta++;
_y = (_y + aceleracion);
if (6 < aceleracion) {
aceleracion = 6;
}
}
}
Symbol 69 MovieClip Frame 1
stop();
Symbol 79 MovieClip Frame 1
stop();
Instance of Symbol 56 MovieClip in Symbol 79 MovieClip Frame 1
onClipEvent (load) {
limitevelocidad = 6;
}
onClipEvent (load) {
function giro() {
if (derecha) {
setProperty("_parent", _xscale , "100");
} else if (izquierda) {
setProperty("_parent", _xscale , "-100");
}
}
stagewidth = 450;
inercia = 0.8;
inercia = 0.8;
gravedad = 0.8;
velocidadX = 0;
velocidadX = 0;
propulsor = 0.6;
vuela = false;
}
onClipEvent (keyDown) {
if (Key.isDown(Key.SPACE)) {
_root.jugadorMC.brillo._visible = true;
}
if (Key.isDown(Key.UP)) {
_root.jugadorMC.humoMC._visible = true;
vuela = true;
}
if (Key.isDown(Key.RIGHT)) {
derecha = true;
}
if (Key.isDown(Key.LEFT)) {
izquierda = true;
}
}
onClipEvent (keyUp) {
if (!Key.isDown(Key.UP)) {
_root.jugadorMC.humoMC._visible = false;
vuela = false;
}
if (!Key.isDown(Key.SPACE)) {
_root.jugadorMC.brillo._visible = false;
dispara = true;
}
if (!Key.isDown(Key.LEFT)) {
izquierda = false;
}
if (!Key.isDown(Key.RIGHT)) {
derecha = false;
}
}
onClipEvent (enterFrame) {
if (_parent._x < -20) {
_parent._x = 620;
}
if (620 < _parent._x) {
_parent._x = -20;
}
if (velocidadY != 0) {
_root.jugadorMC.patitas.gotoAndStop("quieto");
}
if (vuela) {
velocidadY = velocidadY - propulsor;
_root.jugadorMC.patitas.gotoAndStop("quieto");
}
if (!vuela) {
velocidadY = velocidadY + gravedad;
}
if (derecha) {
if ((!vuela) || (velocidadY == 0)) {
_root.jugadorMC.patitas.gotoAndStop("andando");
}
if (velocidadX < limitevelocidad) {
velocidadX++;
giro();
}
} else if (izquierda) {
if ((!vuela) || (velocidadY == 0)) {
_root.jugadorMC.patitas.gotoAndStop("andando");
}
if ((-limitevelocidad) < velocidadX) {
velocidadX--;
giro();
}
} else if ((!izquierda) && (!derecha)) {
_root.jugadorMC.patitas.gotoAndStop("quieto");
velocidadX = velocidadX * inercia;
if ((-1 < velocidadX) && (velocidadX < 1)) {
velocidadX = 0;
}
}
x = _parent._x + velocidadX;
y = _parent._y + velocidadY;
if (_root.areacolisionMC.hitTest(x, _parent._y, true)) {
_parent._x = x;
} else {
velocidadX = 0;
}
if (_root.areacolisionMC.hitTest(_parent._x, y, true)) {
_parent._y = y;
} else {
velocidadY = 0;
}
nu = 1;
while (nu < (_root.marcadoresMC.niveln + 2)) {
if (_parent.areacolision.hitTest(("_root.rocaMC" + nu) + ".areacolision")) {
_parent.play();
}
nu++;
}
}
Instance of Symbol 73 MovieClip "brillo" in Symbol 79 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
}
onClipEvent (enterFrame) {
if (_visible == true) {
n = 1;
while (n < (_root.marcadoresMC.niveln + 2)) {
if (hitTest(("_root.rocaMC" + n) + ".areacolision")) {
eval ("_root.rocaMC" + n).play();
_root.marcadoresMC.sumarpuntos(50);
}
n++;
}
}
}
Instance of Symbol 76 MovieClip "humoMC" in Symbol 79 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
}
Symbol 79 MovieClip Frame 17
_root.destruirrocas(_root.marcadoresMC.niveln + 2);
Symbol 79 MovieClip Frame 23
_root.marcadoresMC.restarvida();
Symbol 79 MovieClip Frame 25
_root.crearrocas(_root.marcadoresMC.niveln + 1);
_root.jugadorMC._x = 350;
_root.jugadorMC._y = 350;
Symbol 91 MovieClip Frame 1
stop();
Symbol 91 MovieClip Frame 158
_root.gotoAndStop("inicio");