Ciao Ragazzi
ho il seguente codice che mi crea un MovieClip sul quale disegno, con due bottoni.
Uno per la pulizia dello schermo e uno per il salva.
Qualcuno mi sa dire come posso escludere una parte di questo movieclip per far si che sopra non ci si possa disegnare ?codice:import it.sephiroth.mloaderWindow import it.sephiroth.PrintScreen var loader:mloaderWindow = this.createClassObject(mloaderWindow, "loader", 10, {_x:-1000, _y:-1000}) loader.setStyle("borderColor", 0x006699) var listener:Object = new Object(); // copy in progress... listener.onProgress = function(target:MovieClip, loaded:Number, total:Number){ var perc = Math.round((loaded/total)*100) loader.label = "computing... " + perc + "%" loader.value = perc }; // copy is complete, send the result LoadVars to PHP listener.onComplete = function(target:MovieClip, load_var:LoadVars){ loader.label = "sending to php..."; load_var.send("/pixels.php", "_blank", "POST"); loader.close(); }; createEmptyMovieClip("Line",1); Line.lineStyle(1,0x000000,100); onMouseDown = function () { Line.moveTo(_xmouse, _ymouse); onMouseMove = function () { Line.lineTo(_xmouse, _ymouse);} } onMouseUp=function() { onMouseMove=null; } // clear the drawing erase_mc.onRelease = function() { createEmptyMovieClip("Line", 1); Line.lineStyle(1, 0x000000, 100); Line.beginFill(0x000000, 100); Line.moveTo(0, 0); Line.moveTo(0, 180); Line.moveTo(350, 180); Line.moveTo(350, 0); Line.moveTo(0, 0); Line.endFill(); }; // preme tasto salva save_btn.onRelease = function() { print_me(); }; function print_me(){ Line.pause() // first pause the playing video pn = new PrintScreen(); // initialize the PrintScreen class pn.addListener( listener ); // assign a listener pn.print(_root, 0, 0, 600, 500) // copy the _root loader.label = "computing... 0%" loader.open(true, true, true); // open a loader }
Banalmente anche sui bottoni passando con il mouse mi lascia il segno ...
Grazie Mille.

Rispondi quotando