Mah direi che è una foto di dimensioni più grandi dello stage, caricata in modo centrale all'interno di un clip
una volta che l'hai caricata ed effettuato il preload nell'evento init,
target._x = Stage.width/2 - target._width/2
target._y = Stage.height/2 - target._height/2
a questo punto - ma non ho modo di provato - e non credo possa andare perfettamente, cmq
SE VA BENE ESEGUI I CONTROLLI PER GLI SPOSTAMENTI VERTICALIcodice:import mx.transitions.Tween; import mx.transitions.easing.Regular; import mx.transitions.easing.Strong; import mx.transitions.easing.Back; import mx.transitions.easing.Elastic; import mx.transitions.easing.Bounce; import mx.transitions.easing.None; target.onMouseMove=function(){ if(_level0._xmouse > Stage._width/2){ // sposta foto verso sinistra estremoDX = this._x+this._width var Xsx:Tween = new Tween(this, "_x", Elastic.easeIn, estremoDX, Stagw.width, 5, true) } if(_level0._xmouse < Stage._width/2){ // Sposta foto verso destra estremoSX = this._x var Xsx:Tween = new Tween(this, "_x", Elastic.easeIn, estremoSX, 0, 5, true) } }
Ciao Rempox

Rispondi quotando