Hola maestros verán me especializo en PHP pero me pidieron algo en Action Script y me propuse hacerlo aunque no lo domine muy bien.
Tengo este codigo:
Código HTML:
Ver originalcarColor = new Color(car);
color1 = new Color(previewbox);
color2 = new Color(chip.chipfill);
//
this.onEnterFrame = function() {
// set c1, c2, c3, hc1, hc2, and hc3 equal to the positions of their respective faders and vice versa
for (i=1; i<=3; i++) {
this["color"+i].setRGB(rgb);
this["hexc"+i+"Text"].onKillFocus = function() {
hexMode = false;
};
this["hexc"+i+"Text"].onSetFocus = function() {
hexMode = true;
};
}
//
// combine c1, c2, and c3 into one variable using bitwise left shift and bitwise OR
rgb = (c1 << 16 | c2 << 8 | c3);
};
//
// make color chip draggable when preview box is clicked
previewBox.onPress = function() {
chip.startDrag(color1);
};
//
// hide color chip and stop dragging when mouse button is released, and set car color if chip is
// droppped on the car or the apply button is clicked
previewBox.onRelease = swatchDrop;
previewBox.onReleaseOutside = swatchDrop;
//
function swatchDrop() {
with (chip) {
if (car.hitTest(_x, _y, true)) {
carColor.setRGB(rgb);
}
_y = -20;
stopDrag();
}
}
apply.onRelease = function() {
carColor.setRGB(rgb);
};
// set color values equal to the color of the clicked button
swatch1.onRelease = function() {
c1 = 127;
c2 = 0;
c3 = 97;
};
swatch2.onRelease = function() {
c1 = 130;
c2 = 0;
c3 = 0;
};
swatch3.onRelease = function() {
c1 = 10;
c2 = 106;
c3 = 0;
};
swatch4.onRelease = function() {
c1 = 0;
c2 = 51;
c3 = 51;
};
swatch5.onRelease = function() {
c1 = 0;
c2 = 51;
c3 = 102;
};
swatch6.onRelease = function() {
c1 = 127;
c2 = 127;
c3 = 127;
};
swatch7.onRelease = function() {
c1 = 80;
c2 = 80;
c3 = 0;
};
verán lo que hace este código es seleccionar un color, arrastrarlo y soltarlo en un movieclip.
MI PROBLEMA ESTA CUANDO LE CAMBIO EL REPRODUCTOR FLASH PLAYER ME DICE QUE HAY FUNCIONES QUE NO ESTAN SOPORTADAS
Desde ya gracias por sus aportes.