Foros del Web » Creando para Internet » Flash y Actionscript »

No me funciona este script en Flash 8

Estas en el tema de No me funciona este script en Flash 8 en el foro de Flash y Actionscript en Foros del Web. Hola a todos, necesito de vuestra sabiduria. Adjunto un script que si lo probais en Flash con FLash Player 6 configurado funciona, a la que ...
  #1 (permalink)  
Antiguo 24/07/2008, 10:04
 
Fecha de Ingreso: julio-2008
Mensajes: 4
Antigüedad: 15 años, 8 meses
Puntos: 0
Exclamación No me funciona este script en Flash 8

Hola a todos, necesito de vuestra sabiduria.

Adjunto un script que si lo probais en Flash con FLash Player 6 configurado funciona, a la que pongo el 8, ya que trabajo con Flash 8 no va, con CS3 tampoco funciona, alguien sabe decirme porqué?

SCRIPT (si haceis copy-paste vereis que funciona):

_global.LARG_2 = Stage.width / 2;
_global.HAUT_2 = Stage.height / 1.75;
//em coloca la figura al centre de la pantalla
_global.PIsur180 =(Math.PI / 180);
_global.nbr_boles = 110;
// ------------------------------------------------------
MovieClip.prototype._3D = function(c_X, c_Y, s_X, s_Y) {
var tmp = this.z * c_Y - this.x * s_Y;
var n_X = this.z * s_Y + this.x * c_Y;
var n_Z = this.y * s_X + tmp * c_X;
var n_Y = this.y * c_X - tmp * s_X;
var p = 300 / (310 + n_Z);
//this._x = this.jumeau._x = LARG_2 + n_X * p;
//this._y = this.jumeau._y = HAUT_2 + n_Y * p;
this._x = LARG_2 + n_X * p;
this._y = HAUT_2 + n_Y * p;
var gros = (100 + 100 * p);
//this._xscale = this.jumeau._xscale = gros;
//this._yscale = this.jumeau._yscale = gros;
this._xscale = gros;
this._yscale = gros;
var rang = Math.ceil(2000 - n_Z * 50);
this.swapDepths(rang);
//this.jumeau.swapDepths((rang + 99));
};
// ------------------------------------------------------
for (i = 0; i < nbr_boles; i++) {
C = createEmptyMovieClip("MC" + i, i);
C.lineStyle(31);
C.lineTo(0, 1);
//D = createEmptyMovieClip("MC" + i, i + 10000);
//D.lineStyle(28, 0x998877 * ((i + 1) * 1024), 100);
//D.lineTo(0, 1);
C.lineStyle(28, 0xFFFFFF* ((1)),100)//((i + 1) * 0000), 100);
C.lineTo(0, 0);
//C.jumeau = D;
C.x = 95 * Math.cos((k * 30 + decalage) * PIsur180);
C.y = 95 * Math.sin((k * 30 + decalage) * PIsur180);
//modifica la separacio entre boles
C.z = -150 + 20 * k;
if (k == 15) {
decalage +=60;
k = 0;
} else {
k++;
}
}
// ------------------------------------------------------
frein = 1;
// ------------------------------------------------------
onMouseMove = function () {
frein = 1;
updateAfterEvent();
};
// ------------------------------------------------------
onEnterFrame = function () {
pX -= (_root._ymouse - HAUT_2) / 20* frein;
pY -= (_root._xmouse - LARG_2) / 20 * frein;
var cosX = Math.cos(pX * PIsur180);
var sinX = Math.sin(pX * PIsur180);
var cosY = Math.cos(pY * PIsur180);
var sinY = Math.sin(pY * PIsur180);
frein *= 0.996;
for (var i = 0; i < nbr_boles; i++) {
angle = ang++ / 10;
this["MC" + i].x *= (1 - Math.sin(angle) / 60);
this["MC" + i].y *= (1 - Math.cos(angle) / 60);
this["MC" + i]._3D(cosX, cosY, sinX, sinY);
}
};

SI alguien me lo soluciona....mil gracias.

Hasta otra.
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 13:35.