
El caso es que al final he llegado a la conclusión que tengo que pasar el código de as1 a as3, el programita en cuestión es bastante largo, pero haber si ayudándome con el código de la línea de tiempo principal y uno de los botones luego puedo seguir yo.
En la línea de tiempo principal tenemos este código.
Código :
function initSound() { oSound = new Sound(this); oSound.attachSound("beep"); } // End of the function function checkStatus(oRef) { var _loc1 = oRef; if (_loc1._x >= RadarL._x && RadarR._x >= _loc1._x && (_loc1._x >= FLIRL._x && FLIRR._x >= _loc1._x)) { _loc1.gotoAndStop(1); return; } // end if if (_loc1._x >= RadarL._x && RadarR._x >= _loc1._x) { _loc1.gotoAndStop(2); return; } // end if if (_loc1._x >= FLIRL._x && FLIRR._x >= _loc1._x) { _loc1.gotoAndStop(3); return; } // end if _loc1.gotoAndStop(4); } // End of the function function showRadarScan() { Radarvolume._width = RadarR._x - RadarL._x; Radarvolume._x = RadarL._x + Radarvolume._width / 2; Radarvolume._alpha = 50; } // End of the function function hideRadarScan() { Radarvolume._alpha = 0; } // End of the function function showFLIRScan() { FLIRvolume._width = FLIRR._x - FLIRL._x; FLIRvolume._x = FLIRL._x + FLIRvolume._width / 2; FLIRvolume._alpha = 50; } // End of the function function hideFLIRScan() { FLIRvolume._alpha = 0; } // End of the function iBorder = 10; iBorderLeft = 10; iBorderRight = 411; iHeight = 214; bShowRadarScan = "false"; bShowFLIRScan = "false"; bStatusNextButton = "inactive"; oSound; initSound(); flir_btn.onPress = function() { if(bShowFLIRScan == "false"){ bShowFLIRScan = "true"; }else{ bShowFLIRScan = "false"; } } radar_btn.onPress = function() { if(bShowRadarScan == "false"){ bShowRadarScan = "true"; }else{ bShowRadarScan = "false"; } } stop ();
Y luego uno de los botones.
Código :
onClipEvent (load) { startDragging = function () { var _loc1 = _root; if (this.hitTest(_loc1._xmouse, _loc1._ymouse, true)) { iActiveWidth = _loc1.iBorderRight - _loc1.iBorderLeft; _parent.startDrag(true, _loc1.iBorderLeft, _loc1.iHeight, _loc1.FLIRC._x - _loc1.iBorder * 2.100000E+000, _loc1.iHeight); bDrag = true; } // end if }; stopDragging = function () { _parent.stopDrag(); bDrag = false; }; } onClipEvent (mouseDown) { if (bDrag) { stopDragging(); } else { startDragging(); } // end else if } onClipEvent (mouseMove) { if (bDrag) { iFLIRRX = _root.FLIRC._x + (_root.FLIRC._x - _parent._x); if (iFLIRRX < _root.iBorderRight) { _root.FLIRR._x = _root.flirlineR._x = iFLIRRX; } else { _root.FLIRC._x = _root.flirlineC._x = (_root.iBorderRight - _root.FLIRL._x) / 2 + _root.FLIRL._x; _root.FLIRR._x = _root.flirlineR._x = _root.iBorderRight; if (_root.FLIRC._x != iOldFCX) { _parent.stopDrag(); _parent.startDrag(true, _root.iBorderLeft, _root.iHeight, _root.FLIRC._x - _root.iBorder * 2.100000E+000, _root.iHeight); iOldFCX = _root.FLIRC._x; } // end if } // end else if _root.flirlineL._x = _parent._x; updateAfterEvent(); } // end if }
Cualquier ayuda por poquito que sea me vendrá como agua de mayo.
Muchas gracias a todos.