home *** CD-ROM | disk | FTP | other *** search
/ Mobiclic 136 / MOBICLIC136.ISO / pc / DATA / TST136 / TST136_00 / TST136_00.swf / scripts / frame_46 / DoAction.as
Text File  |  2011-07-20  |  3KB  |  119 lines

  1. if(gPCent == undefined)
  2. {
  3.    gBlockST = 1;
  4.    joueSon({nomSon:"C00",actionFin:"RIEN"});
  5. }
  6. lList = ["A","B","C","D","E"];
  7. gListe_W_H = [[151,281],[120,226],[90,168],[42,82]];
  8. var myMax = 0;
  9. var i = 0;
  10. while(i < gListPCent.length)
  11. {
  12.    if(gListPCent[i] > myMax)
  13.    {
  14.       myMax = gListPCent[i];
  15.    }
  16.    i++;
  17. }
  18. gListeCadre = [];
  19. var i = 0;
  20. while(i < gListPCent.length)
  21. {
  22.    gListeCadre[i] = 0;
  23.    this["CONCLU_" + lList[i]]._alpha = 0;
  24.    var myClip = this["CONCLU_" + lList[i]].CONCLU.CONCLU.ACCUEIL;
  25.    if(gSexe == "G")
  26.    {
  27.       myClip.id = "A_" + gModuleName + "_CONCLU_" + lList[i];
  28.    }
  29.    else
  30.    {
  31.       myClip.id = "A_" + gModuleName + "_CONCLU_" + lList[i] + "Z";
  32.    }
  33.    var swfHolderNom = myClip.createEmptyMovieClip("swfHolder_" + (i + 1),chercheDepthPlus(myClip,0));
  34.    this["mclR_C_" + i] = new MovieClipLoader();
  35.    this["mclR_C_" + i].loadClip(_global.gModulePath + moduleInfo.getResourceById(myClip.id).firstChild.attributes.src,swfHolderNom);
  36.    this["mclR_C_" + i].onLoadInit = function(lClip)
  37.    {
  38.       var _loc2_ = lClip._parent._parent._parent._parent;
  39.       var _loc1_ = gListPCent[Number(lClip._name.split("_")[1]) - 1] * 100 / myMax;
  40.       if(_loc1_ == 0)
  41.       {
  42.          _loc1_ = 10;
  43.       }
  44.       var _loc5_ = Number(lClip._name.split("_")[1]) - 1;
  45.       var _loc4_ = gListeCadre[_loc5_];
  46.       cadreWidth = gListe_W_H[_loc4_][0];
  47.       cadreHeight = gListe_W_H[_loc4_][1];
  48.       adapteImage(lClip,1);
  49.       _loc2_._xscale = _loc1_;
  50.       _loc2_._yscale = _loc1_;
  51.       _loc2_._y -= 59 * (100 - _loc1_) / 100;
  52.       _loc2_._alpha = 100;
  53.    };
  54.    myClip._parent._parent.pCent.text = String(gListPCent[i]) + "%";
  55.    var lIB = "";
  56.    var _loc0_ = null;
  57.    if((_loc0_ = gSexe) !== "F")
  58.    {
  59.       lIB = "IB" + lList[i];
  60.    }
  61.    else if(gereTextes.getTextById(XmlIB,"IB" + lList[i] + "Z") !== undefined)
  62.    {
  63.       lIB = "IB" + lList[i] + "Z";
  64.    }
  65.    else
  66.    {
  67.       lIB = "IB" + lList[i];
  68.    }
  69.    this["CONCLU_" + lList[i]].pIB = lIB;
  70.    this["CONCLU_" + lList[i]].pLettre = lList[i];
  71.    this["CONCLU_" + lList[i]].onRollOver = function()
  72.    {
  73.       gereCursor(2);
  74.       this.CONCLU.CONCLU.gotoAndStop("E2");
  75.       gereTextes.afficheIB({X:this._x,Y:this._y - this._yscale / 2,codeIB:this.pIB});
  76.       var _loc3_ = _root.IB;
  77.       var _loc4_ = _loc3_.IB.fond._width;
  78.       _loc3_._x -= _loc4_ / 2;
  79.       joueBruitage({nomSon:"B_" + this.pLettre});
  80.    };
  81.    this["CONCLU_" + lList[i]].onDragOut = _loc0_ = function()
  82.    {
  83.       gereCursor(1);
  84.       this.CONCLU.CONCLU.gotoAndStop("E1");
  85.       gereTextes.masqueIB();
  86.       stopBruitage({nomSon:"B_" + this.pLettre});
  87.    };
  88.    this["CONCLU_" + lList[i]].onRollOut = _loc0_;
  89.    this["CONCLU_" + lList[i]].onPress = function()
  90.    {
  91.       gereCursor(1);
  92.       gereTextes.masqueIB();
  93.       this.CONCLU.CONCLU.gotoAndStop("E1");
  94.       stopBruitage({nomSon:"B_" + this.pLettre});
  95.       if(gSexe == "G")
  96.       {
  97.          gConclu = this.pLettre;
  98.       }
  99.       else
  100.       {
  101.          gConclu = this.pLettre + "Z";
  102.       }
  103.       gPCent = this.CONCLU.pCent.text.split("%")[0];
  104.       gotoAndStop("PROFIL");
  105.    };
  106.    i++;
  107. }
  108. onMcOver({mc:BT_PRINT,codeIB:"IB94"});
  109. BT_PRINT.onPress = function()
  110. {
  111.    onMcOut(this);
  112.    BT_REFAIRE._visible = false;
  113.    this._visible = false;
  114.    _global.ImprimerEcran();
  115.    BT_REFAIRE._visible = true;
  116.    this._visible = true;
  117. };
  118. stop();
  119.