3 Replies Latest reply on Aug 3, 2010 6:32 PM by kglad

    Have to rewrite for player 6

    juresti Level 1

      I'm using articulate and some things I need to do require I rewrite the code for player 6. Can anyone help me and tell me what I can not do in player 6? My file is good in player 8, not 6 or 7. Any help, hint is appreciated!

       

       

      XMLParser.load("Q_data/Q1_assets/Q1.xml", onFinish, null, false, true)

      function onFinish($success:Boolean, $parsedObject:Object, $xml:XML) {  //This function gets called as soon as the XML loads and gets parsed.
      if ($success) {
      displayResources($parsedObject);
      showImage($parsedObject);
      //trace($parsedObject.question[0].nodeValue);
      } else {
      trace("FAILED to load XML");
      }
      }

      var lo:Object=new Object();
      lo.onLoadInit=function(target:MovieClip){
      target.forceSmoothing=true;
      }

      var mclip:MovieClipLoader=new MovieClipLoader();
      mclip.addListener(lo);

      function displayResources($parsedObject:Object):Void {

      qDetails_txt.text = $parsedObject.question[0].details[0].nodeValue;
      question_txt.text = $parsedObject.question[0].nodeValue;

      var i:Number;
      var title:Array = $parsedObject.title;
      for (i = 0; i < title.length; i++) {
      this["Title_txt"+i].text = title[i].name;
      mclip.loadClip(title[i].image[0].nodeValue, this["holder_mc"+i]);
      //trace(i);

      // BTN_0 -------------------

      BTN_0.onRelease = function() {
      gotoAndStop("ans0");
      Comments_txt0.text = title[0].comments[0].nodeValue;
      toolName_txt0.text = "Tool Name: " + title[0].hidden[0].nodeValue;
      mclip.loadClip(title[0].image[0].nodeValue, holder_mc0);

      if (title[0].answer[0].nodeValue == "yes")
      {
      answer_txt0.text = title[0].yesText[0].nodeValue;
      //TXT_ans0.text = "Click for Next";
      attachMovie("buttonnext", "bn", 1, {_x:270, _y:384});
      }
      else {
      answer_txt0.text = title[0].noText[0].nodeValue;
      //TXT_ans0.text = "Go Back";
      attachMovie("buttonback", "bb", 1, {_x:270, _y:384});
      bb.onRelease = function() {gotoAndStop("q_home"); bb.removeMovieClip();}
      }

      }

      // BTN_1 -------------------
      BTN_1.onRelease = function() {
      gotoAndStop("ans1");
      Comments_txt1.text = title[1].comments[0].nodeValue;
      toolName_txt1.text = "Tool Name: " + title[1].hidden[0].nodeValue;
      mclip.loadClip(title[1].image[0].nodeValue, holder_mc1);

      if (title[1].answer[0].nodeValue =="yes")
      {
      answer_txt1.text = title[1].yesText[0].nodeValue;
      //TXT_ans0.text = "Click for Next";
      attachMovie("buttonnext", "bn", 1, {_x:270, _y:384});
      }
      else {
      answer_txt1.text = title[1].noText[0].nodeValue;
      //TXT_ans0.text = "Go Back";
      attachMovie("buttonback", "bb", 1, {_x:270, _y:384});
      bb.onRelease = function() {gotoAndStop("q_home"); bb.removeMovieClip();}
      }
      }

      // BTN_2 -------------------
      BTN_2.onRelease = function() {
      gotoAndStop("ans2");
      Comments_txt2.text = title[2].comments[0].nodeValue;
      toolName_txt2.text = "Tool Name: " + title[2].hidden[0].nodeValue;
      mclip.loadClip(title[2].image[0].nodeValue, holder_mc2);
      if (title[2].answer[0].nodeValue =="yes")
      {
      answer_txt2.text = title[2].yesText[0].nodeValue;
      //TXT_ans0.text = "Click for Next";
      attachMovie("buttonnext", "bn", 1, {_x:270, _y:384});
      }
      else {
      answer_txt2.text = title[2].noText[0].nodeValue;
      //TXT_ans0.text = "Go Back";
      attachMovie("buttonback", "bb", 1, {_x:270, _y:384});
      bb.onRelease = function() {gotoAndStop("q_home"); bb.removeMovieClip();}
      }

      }

      // BTN_3 -------------------     

      BTN_3.onRelease = function() {
      gotoAndStop("ans3");
      Comments_txt3.text = title[3].comments[0].nodeValue;
      toolName_txt3.text = "Tool Name: " + title[3].hidden[0].nodeValue;
      mclip.loadClip(title[3].image[0].nodeValue, holder_mc3);
      if (title[3].answer[0].nodeValue =="yes")
      {
      answer_txt3.text = title[3].yesText[0].nodeValue;
      //TXT_ans0.text = "Click for Next";
      attachMovie("buttonnext", "bn", 1, {_x:270, _y:384});
      }
      else {
      answer_txt3.text = title[3].noText[0].nodeValue;
      //TXT_ans0.text = "Go Back";
      attachMovie("buttonback", "bb", 1, {_x:270, _y:384});
      bb.onRelease = function() {gotoAndStop("q_home"); bb.removeMovieClip();}
      }

      }
      }}
      stop();