Bonjour,
débutant en flash je n'ai pas forcément choisi le plus simple pour commencer...
Bref, j'essaye de modifier un script as2 (carrousel d'images que j'ai récupéré sur le net) afin d'afficher (à coté du carrousel dans un autre clip) l'image en grand format avec un effet "_alpha" lorsque celle-ci (au petit format) est cliquée dans le carrousel.
Le carrousel fonctionne très bien, l'image au grand format s'affiche mais pour autant les effets (en l'occurrence ici une augmentation "alpha") ne se voit pas ou ne fonctionne pas (???).

Merci à vous de me dire ce qui manque dans mes modifications afin de réaliser cette effet.

Ci-dessous une partie du code utilisée :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
var clipImage:MovieClip = this.createEmptyMovieClip("afficheur", this.getNextHighestDepth());
clipImage._alpha=0;
clipImage._x=0;
clipImage._y=0;
var label:TextField = afficheur.createTextField("label", 1, 0, 0, 150, 20);
label.text = "Le titre ici";
 
clipImage.onEnterFrame = function(){
    trace("enterFrame");
    this._alpha += 1;
    if (this._alpha>=100) {
        delete this.onEnterFrame;
    }
}
 
clipImage.changerImage = function(newImage){
    clipImage._alpha=0;
    clipImage.loadMovie(newImage);
    clipimage.onEnterFrame();
}
 
 
//chargement du xml
function load_xml(path:String,type:String){
    var xml:XML = new XML();
    xml.ignoreWhite = true;
    xml.onLoad=function(){        
        var nodes = this.firstChild.childNodes;
        numOfItems = nodes.length;
        //je genere le caroussel quand tout est chargé.
        genereCarousel(nodes);    
    }
    xml.load("xml/"+path);        
}
 
 
function genereCarousel(nodes){
    level = home.getNextHighestDepth();
    home.createEmptyMovieClip("carrousel",iCarousel);    
    clipHote = home["carrousel"];
 
    for (var i=0;i<numOfItems;i++){                        
        var t=clipHote.attachMovie("item","item"+i,i+1);        
        t.angle = i* ((Math.PI*2)/numOfItems);        
        t._y=Math.sin(t.angle)*radiusY +centerY;            
        var s:Number = (t._y - perspective)/(centerY + radiusY - perspective)
        t._xscale=t._yscale=s*50;
             t._x=Math.cos(t.angle)*150+centerX;                                    
        t.icon.inner.loadMovie(nodes[i].attributes.image);        
        t.icon.smoothing=true;            
        t.ref.inner.loadMovie(nodes[i].attributes.image);
        t.swapDepths(Math.round(t._xscale) + 100 +i);    
 
        t.onEnterFrame = mover;
 
        //j'associe l'attribut lien du xml au clip
        t.lien=nodes[i].attributes.lien;
        //action au clic qui ouvre le lien de celui ci
 
        //modif 
        t.grandeImage=nodes[i].attributes.grandeImage;
        t.onRelease = function(){
            //this.getURL(this.lien,"_blank");
            this._lockroot = true;
            clipImage.changerImage(this.grandeImage);
        }
        //fin modif 
    }    
}