Frame 1
pjw = 640;
pjh = 480;
Frame 2
play();
Frame 3
scoversion = 0;
varXML = "";
varXML = varXML + "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<quiz>\r\n\t<general version=\"120\">\r\n\t\t<quizid>10001</quizid>\r\n\t\t<title>Christmas Trivia Quiz</title>\r\n\t\t<size width=\"640\" height=\"480\"></size>\r\n\t\t<login userid=\"0\" password=\"0\" presetpassword=\"1\" passwordvalue=\"\" passwordurl=\"http://www.quiz-builder.com/test/login.php\" getmethod=\"1\"></login>\r\n\t\t<introduction show=\"1\" img=\"y\">How much do you know about Christmas? Test your knowledge with 30 trivia questions. \r\n\r\nClick the start button to begin. </introduction>\r\n\t\t<reporting enable=\"0\" level=\"0\" method=\"2\" scriptscoreurl=\"http://www.quiz-builder.com/test/reportscore.php\" scriptscoreget=\"1\" scriptinteractionurl=\"http://www.quiz-builder.com/test/reportinteraction.php\" scriptinteractionget=\"1\"></reporting>\r\n\t\t<design version=\"120\">\r\n\t\t\t<rbstyle>Classic</rbstyle>\r\n\t\t\t<cbstyle>Classic</cbstyle>\r\n\t\t\t<tfont name=\"Comic Sans MS\" size=\"14\" color=\"0\" bold=\"1\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></tfont>\r\n\t\t\t<lfont name=\"Comic Sans MS\" size=\"11\" color=\"0\" bold=\"1\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></lfont>\r\n\t\t\t<qfont name=\"Comic Sans MS\" size=\"14\" color=\"0\" bold=\"1\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></qfont>\r\n\t\t\t<afont name=\"Comic Sans MS\" size=\"14\" color=\"0\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></afont>\r\n\t\t\t<qbfont name=\"Comic Sans MS\" size=\"14\" color=\"16777215\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></qbfont>\r\n\t\t\t<sfont name=\"Comic Sans MS\" size=\"16\" color=\"0\" bold=\"1\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></sfont>\r\n\t\t\t<mfont name=\"Comic Sans MS\" size=\"12\" color=\"0\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></mfont>\r\n\t\t\t<ifont name=\"Comic Sans MS\" size=\"18\" color=\"0\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></ifont>\r\n\t\t\t<tocfont name=\"Comic Sans MS\" size=\"12\" color=\"0\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></tocfont>\r\n\t\t\t<toctfont name=\"Comic Sans MS\" size=\"11\" color=\"16777215\" bold=\"0\" italic=\"0\" backenable=\"1\" backcolor=\"8421504\"></toctfont>\r\n\t\t\t<ffont name=\"Comic Sans MS\" size=\"14\" color=\"3158835\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></ffont>\r\n\t\t\t<takecfont name=\"Comic Sans MS\" size=\"11\" color=\"6710886\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></takecfont>\r\n\t\t\t<takefont name=\"Comic Sans MS\" size=\"12\" color=\"0\" bold=\"0\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></takefont>\r\n\t\t\t<timerfont name=\"Comic Sans MS\" size=\"12\" color=\"16777215\" bold=\"0\" italic=\"0\" backenable=\"1\" backcolor=\"8421504\"></timerfont>\r\n\t\t\t<bfont name=\"Comic Sans MS\" size=\"14\" color=\"0\" bold=\"1\" italic=\"0\" backenable=\"0\" backcolor=\"0\"></bfont>\r\n\t\t\t<backcolor color=\"16711680\"></backcolor>\r\n\t\t\t<qback enable=\"1\" border=\"0\" fill=\"16777215\" round=\"0\" shadow=\"1\"></qback>\r\n\t\t\t<qbback enable=\"1\" border=\"16777215\" fill=\"16711680\" round=\"0\" shadow=\"1\"></qbback>\r\n\t\t\t<tocback enable=\"1\" border=\"0\" fill=\"15658734\" round=\"0\" shadow=\"1\"></tocback>\r\n\t\t\t<rollover color=\"52224\">1</rollover>\r\n\t\t\t<toc display=\"0\" icons=\"1\" points=\"1\"></toc>\r\n\t\t\t<qbdisplay points=\"0\" cscore=\"0\" numbering=\"1\" audio=\"1\" info=\"1\" infoemail=\"feedback@onemorelevel.com\" infoweb=\"www.onemorelevel.com\" numberingstyle=\"3\"></qbdisplay>\r\n\t\t\t<finishdisplay passfailmessages=\"1\" review=\"1\" email=\"0\" print=\"0\" passmessage=\"Congratulations, you are a true Christmas buff!\" failmessage=\"Go drink some more egg nog and try again.\" emailaddress=\"\"></finishdisplay>\r\n\t\t</design>\r\n\t\t<language value=\"english\">\r\n\t\t\t<bar>\r\n\t\t\t\t<item id=\"loginbar\" description=\"Login\">Please enter your login info</item>\r\n\t\t\t\t<item id=\"introductionbar\" description=\"Introduction\">Brought to you by OneMoreLevel.com</item>\r\n\t\t\t\t<item id=\"questionnumbering1bar\" description=\"Question Numbering Style 1\">%s</item>\r\n\t\t\t\t<item id=\"questionnumbering2bar\" description=\"Question Numbering Style 2\">Question %s</item>\r\n\t\t\t\t<item id=\"questionnumbering3bar\" description=\"Question Numbering Style 3\">%s of %s</item>\r\n\t\t\t\t<item id=\"questionnumbering4bar\" description=\"Question Numbering Style 4\">Question %s of %s</item>\r\n\t\t\t\t<item id=\"pointsbar\" description=\"Points\">%s pts</item>\r\n\t\t\t\t<item id=\"cscorebar\" description=\"Cumulative score\">%s so far</item>\r\n\t\t\t\t<item id=\"delimiterbar\" description=\"Delimiter\"> \\ </item>\r\n\t\t\t\t<item id=\"pausebar\" description=\"15 Minutes break\">PAUSE</item>\r\n\t\t\t\t<item id=\"correctbar\" description=\"Review : Correct\">Question %s \\ CORRECT</item>\r\n\t\t\t\t<item id=\"incorrectbar\" description=\"Review : Incorrect\">Question %s \\ INCORRECT</item>\r\n\t\t\t\t<item id=\"incompletebar\" description=\"Review : Incomplete\">Question %s \\ INCOMPLETE</item>\r\n\t\t\t\t<item id=\"passedbar\" description=\"Finish : Passed\">PASSED</item>\r\n\t\t\t\t<item id=\"failedbar\" description=\"Finish : Failed\">FAILED</item>\r\n\t\t\t</bar>\r\n\t\t\t<TOC>\r\n\t\t\t\t<item id=\"toctitle\" description=\"Title\">Table of Contents</item>\r\n\t\t\t</TOC>\r\n\t\t\t<login>\r\n\t\t\t\t<item id=\"loginlabel\" description=\"User ID\">User ID</item>\r\n\t\t\t\t<item id=\"passwordlabel\" description=\"Password\">Password</item>\r\n\t\t\t</login>\r\n\t\t\t<question>\r\n\t\t\t\t<item id=\"scenariol\" description=\"Scenario\">Scenario</item>\r\n\t\t\t\t<item id=\"wordbank\" description=\"Word Bank\">Drag and drop the correct answer here.</item>\r\n\t\t\t\t<item id=\"shortanswerreview\" description=\"Short answer : Review \">List of correct answers :</item>\r\n\t\t\t</question>\r\n\t\t\t<15_minutes_break>\r\n\t\t\t\t<item id=\"checktake\" description=\"Check box\">Take a 15 minutes break AFTER this question</item>\r\n\t\t\t\t<item id=\"infotake\" description=\"Message\">You're on a 15 minutes break. Click the "Continue" button to continue the quiz. The quiz will automatically continue from the point where you left off when the time has expired</item>\r\n\t\t\t\t<item id=\"remainingtake\" description=\"Timer\">%s remaining</item>\r\n\t\t\t</15_minutes_break>\r\n\t\t\t<time_limited>\r\n\t\t\t\t<item id=\"timeremaining\" description=\"Timer\">%s remaining</item>\r\n\t\t\t</time_limited>\r\n\t\t\t<messages>\r\n\t\t\t\t<item id=\"userid\" description=\"Empty User ID\">Please enter your User ID.</item>\r\n\t\t\t\t<item id=\"connectionfaillogin\" description=\"Login : connection failed\">Cannot connect to server.</item>\r\n\t\t\t\t<item id=\"connectionfailreportscore\" description=\"Report score : connection failed\">Cannot connect to server to report score.</item>\r\n\t\t\t\t<item id=\"connectionfailreportinteraction\" description=\"Report interaction : connection failed\">Cannot connect to server to report interaction.</item>\r\n\t\t\t\t<item id=\"password\" description=\"Incorrect Password\">Incorrect Password. Please enter your password.</item>\r\n\t\t\t\t<item id=\"msgimcomplete\" description=\"Incomplete Answer\">You must answer the question before continuing.</item>\r\n\t\t\t\t<item id=\"submitallnotification\" description=\"Submit All : Notification\">One or more questions is incomplete. Please complete all questions to continue.</item>\r\n\t\t\t\t<item id=\"submitallincomplete\" description=\"Submit All : Incomplete answer\">There are unanswered questions left in the quiz. Would you like to submit anyway?</item>\r\n\t\t\t\t<item id=\"submitallcomplete\" description=\"Submit All : Complete answer\">Are you sure you are ready to submit your answers for scoring?</item>\r\n\t\t\t\t<item id=\"msgtimer\" description=\"Time expired\">Your time has expired !</item>\r\n\t\t\t\t<item id=\"imagehint\" description=\"Click to enlarge\">Click to enlarge</item>\r\n\t\t\t</messages>\r\n\t\t\t<buttons>\r\n\t\t\t\t<item id=\"btnlogin\" description=\"Login\">Login</item>\r\n\t\t\t\t<item id=\"btnstart\" description=\"Start\">Start</item>\r\n\t\t\t\t<item id=\"btncontinue\" description=\"Continue\">Continue</item>\r\n\t\t\t\t<item id=\"btnback\" description=\"Previous question\">Back</item>\r\n\t\t\t\t<item id=\"btnnext\" description=\"Next question\">Next</item>\r\n\t\t\t\t<item id=\"btnsubmit\" description=\"Submit answer\">Submit</item>\r\n\t\t\t\t<item id=\"btnsubmitall\" description=\"Submit all questions\">Submit All</item>\r\n\t\t\t\t<item id=\"btnreviewfinish\" description=\"Review : Go to finish\">Results</item>\r\n\t\t\t\t<item id=\"btnfeedcontinue\" description=\"Feedback : Continue\">Continue</item>\r\n\t\t\t\t<item id=\"btnfeedretry\" description=\"Feedback : Retry\">Retry</item>\r\n\t\t\t\t<item id=\"btnfeedignore\" description=\"Feedback : Ignore\">Ignore</item>\r\n\t\t\t\t<item id=\"btnfeedyes\" description=\"Feedback : Yes\">Yes</item>\r\n\t\t\t\t<item id=\"btnfeedno\" description=\"Feedback : No\">No</item>\r\n\t\t\t\t<item id=\"btnfinish\" description=\"Finish\">OML.com</item>\r\n\t\t\t</buttons>\r\n\t\t\t<finish>\r\n\t\t\t\t<item id=\"yslabel\" description=\"Your score\">Your Score</item>\r\n\t\t\t\t<item id=\"pslabel\" description=\"Passing score\">Passing Score</item>\r\n\t\t\t\t<item id=\"pointslabel\" description=\"Points\">%s points</item>\r\n\t\t\t</finish>\r\n\t\t\t<reporting>\r\n\t\t\t\t<item id=\"reportpassed\" description=\"Report score : Passed\">passed</item>\r\n\t\t\t\t<item id=\"reportfailed\" description=\"Report score : Failed\">failed</item>\r\n\t\t\t\t<item id=\"reportincomplete\" description=\"Report score : Incomplete\">incomplete</item>\r\n\t\t\t\t<item id=\"reporticorrect\" description=\"Report interaction : Correct\">correct</item>\r\n\t\t\t\t<item id=\"reportiincorrect\" description=\"Report interaction : Incorrect\">wrong</item>\r\n\t\t\t\t<item id=\"reportiincomplete\" description=\"Report interaction : Incomplete\">incomplete</item>\r\n\t\t\t\t<item id=\"emailsubject\" description=\"EMail : Subject\">quiz results (%s)</item>\r\n\t\t\t\t<item id=\"emailquizid\" description=\"EMail : Column - quiz id\">Quiz ID</item>\r\n\t\t\t\t<item id=\"emailuserid\" description=\"EMail : Column - user id\">User ID</item>\r\n\t\t\t\t<item id=\"emailstatus\" description=\"EMail : Column - status\">Status</item>\r\n\t\t\t\t<item id=\"emailuserpoints\" description=\"EMail : Column - user points\">User Points</item>\r\n\t\t\t\t<item id=\"emailpassedpoints\" description=\"EMail : Column - passing points\">Passing Points</item>\r\n\t\t\t\t<item id=\"emailmaxpoints\" description=\"EMail : Column - max points\">Max Points</item>\r\n\t\t\t\t<item id=\"emailuserscore\" description=\"EMail : Column - user score\">User Score(%)</item>\r\n\t\t\t\t<item id=\"emailpassedscore\" description=\"EMail : Column - passing score\">Passing Score(%)</item>\r\n\t\t\t\t<item id=\"emailtimeelapsed\" description=\"EMail : Column - elapsed time\">Elapsed Time</item>\r\n\t\t\t\t<item id=\"emaildate\" description=\"EMail : Column - date\">Date</item>\r\n\t\t\t\t<item id=\"emailtime\" description=\"EMail : Column - time\">Time</item>\r\n\t\t\t\t<item id=\"emailinteractionid\" description=\"EMail : Column - interaction ID\">Interaction ID</item>\r\n\t\t\t\t<item id=\"emailinteractiontype\" description=\"EMail : Column - interaction type\">Interaction type</item>\r\n\t\t\t\t<item id=\"emailinteractionuserresponse\" description=\"EMail : Column - interaction user response\">User response</item>\r\n\t\t\t\t<item id=\"emailinteractionresult\" description=\"EMail : Column - interaction result\">Result</item>\r\n\t\t\t\t<item id=\"emailinteractionpoints\" description=\"EMail : Column - interaction points\">Points</item>\r\n\t\t\t\t<item id=\"emailinteractionweight\" description=\"EMail : Column - interaction weight\">Weight</item>\r\n\t\t\t\t<item id=\"emailinteractionlatency\" description=\"EMail : Column - interaction latency\">Latency</item>\r\n\t\t\t\t<item id=\"emailbegin\" description=\"EMail : Body - header\">My results are </item>\r\n\t\t\t\t<item id=\"emailend\" description=\"EMail : Body - footer\">Thank you</item>\r\n\t\t\t</reporting>\r\n\t\t\t<print>\r\n\t\t\t\t<item id=\"passedprint\" description=\"Passed\">PASSED</item>\r\n\t\t\t\t<item id=\"failedprint\" description=\"Failed\">FAILED</item>\r\n\t\t\t\t<item id=\"userprint\" description=\"Header : User\">USER</item>\r\n\t\t\t\t<item id=\"dateprint\" description=\"Header : Date\">DATE</item>\r\n\t\t\t\t<item id=\"elapsedprint\" description=\"Header : Time\">Time Elapsed</item>\r\n\t\t\t\t<item id=\"userscoreprint\" description=\"Header : User score\">USER SCORE</item>\r\n\t\t\t\t<item id=\"passedscoreprint\" description=\"Header : Passing score\">PASSING SCORE</item>\r\n\t\t\t\t<item id=\"nocolprint\" description=\"Column : No\">NO</item>\r\n\t\t\t\t<item id=\"questionscolprint\" description=\"Column : Questions\">QUESTIONS</item>\r\n\t\t\t\t<item id=\"pointsprint\" description=\"Column : Points\">POINTS</item>\r\n\t\t\t\t<item id=\"statuscolprint\" description=\"Column : Status\">STATUS</item>\r\n\t\t\t\t<item id=\"pointscolprint\" description=\"Column : Points\">POINTS</item>\r\n\t\t\t\t<item id=\"scenarioprint\" description=\"Scenario\">SCENARIO</item>\r\n\t\t\t\t<item id=\"correctprint\" description=\"Question status : Correct\">CORRECT</item>\r\n\t\t\t\t<item id=\"incorrectprint\" description=\"Question status : Incorrect\">INCORRECT</item>\r\n\t\t\t\t<item id=\"incompleteprint\" description=\"Questions status : Incomlete\">INCOMPLETE</item>\r\n\t\t\t\t<item id=\"month01print\" description=\"January\">January</item>\r\n\t\t\t\t<item id=\"month02print\" description=\"February\">February</item>\r\n\t\t\t\t<item id=\"month03print\" description=\"March\">March</item>\r\n\t\t\t\t<item id=\"month04print\" description=\"April\">April</item>\r\n\t\t\t\t<item id=\"month05print\" description=\"May\">May</item>\r\n\t\t\t\t<item id=\"month06print\" description=\"June\">June</item>\r\n\t\t\t\t<item id=\"month07print\" description=\"July\">July</item>\r\n\t\t\t\t<item id=\"month08print\" description=\"August\">August</item>\r\n\t\t\t\t<item id=\"month09print\" description=\"September\">September</item>\r\n\t\t\t\t<item id=\"month10print\" description=\"October\">October</item>\r\n\t\t\t\t<item id=\"month11print\" description=\"November\">November</item>\r\n\t\t\t\t<item id=\"month12print\" description=\"December\">December</item>\r\n\t\t\t</print>\r\n\t\t</language>\r\n\t\t<qoptions>\r\n\t\t\t<all nrquestions=\"3\" randomize=\"0\">1</all>\r\n\t\t\t<submitone finish=\"0\" take=\"0\">1</submitone>\r\n\t\t</qoptions>\r\n\t\t<finish>\r\n\t\t\t<score value=\"60\"></score>\r\n\t\t\t<time limited=\"0\" hh=\"0\" mm=\"5\" ss=\"0\" show=\"1\"></time>\r\n\t\t\t<actionpass swf=\"\" url=\"http://www.onemorelevel.com\" exe=\"\">1</actionpass>\r\n\t\t\t<actionfail swf=\"\" url=\"http://www.onemorelevel.com\" exe=\"\">1</actionfail>\r\n\t\t</finish>\r\n\t</general>\r\n\t<items>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"24\" interactionid=\"I0024\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Where did the real St. Nicholas live?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>In Holland</answer>\r\n\t\t\t<answer>At the North Pole</answer>\r\n\t\t\t<answer correct=\"y\">In Turkey</answer>\r\n\t\t\t<answer>In Germany</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"25\" interactionid=\"I0025\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What American state was the first to make Christmas an official holiday?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Connecticut</answer>\r\n\t\t\t<answer correct=\"y\">Alabama</answer>\r\n\t\t\t<answer>Alaska</answer>\r\n\t\t\t<answer>North Carolina</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"26\" interactionid=\"I0026\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What is the shape of the candy cane modeled after?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>A fish hook</answer>\r\n\t\t\t<answer>A star constellation</answer>\r\n\t\t\t<answer>The cane St. Nicholas used</answer>\r\n\t\t\t<answer correct=\"y\">A shepard's crook</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"27\" interactionid=\"I0027\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What was the name of the dog that belonged to the Grinch in Dr. Seuss' book "How the Grinch Stole Christmas"?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Rudolph</answer>\r\n\t\t\t<answer>Toto</answer>\r\n\t\t\t<answer correct=\"y\">Max</answer>\r\n\t\t\t<answer>Cerbeus</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"28\" interactionid=\"I0028\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Which star led the Three Kings to Jesus?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Star of David</answer>\r\n\t\t\t<answer>North Star</answer>\r\n\t\t\t<answer correct=\"y\">Star of Bethlehem</answer>\r\n\t\t\t<answer>Angel Star</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"29\" interactionid=\"I0029\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What was the name of Scrooges' dead business partner in "A Christmas Carol"?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer correct=\"y\">Jacob Marley</answer>\r\n\t\t\t<answer>Bob Crachit</answer>\r\n\t\t\t<answer>Tiny Tim</answer>\r\n\t\t\t<answer>Bill Sykes</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"30\" interactionid=\"I0030\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What brought Frosty the Snowman to life?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Pixie Dust</answer>\r\n\t\t\t<answer correct=\"y\">An old silk hat</answer>\r\n\t\t\t<answer>A kiss</answer>\r\n\t\t\t<answer>A fresh snowfall</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"31\" interactionid=\"I0031\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">When you go Wassailing, what is it that you are doing?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Giving out gifts to your friends & neighbors</answer>\r\n\t\t\t<answer>Going out in the woods to cut down your Christmas tree</answer>\r\n\t\t\t<answer>Challenging as many of your neighbors as you can to a snowball fight</answer>\r\n\t\t\t<answer correct=\"y\">Going to visit neighbors and receiving goodies!</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"32\" interactionid=\"I0032\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\"> In the movie "It's A Wonderful Life" how do you know that an angel has received his wings?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>A light flashes</answer>\r\n\t\t\t<answer>It starts snowing</answer>\r\n\t\t\t<answer>A trumpet sounds</answer>\r\n\t\t\t<answer correct=\"y\">A bell rings</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"33\" interactionid=\"I0033\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\"> Who was the author of "A Christmas Carol"?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Hans Christian Anderson</answer>\r\n\t\t\t<answer correct=\"y\">Charles Dickens</answer>\r\n\t\t\t<answer>Thomas M. Sawyer</answer>\r\n\t\t\t<answer>Mark Twain</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"34\" interactionid=\"I0034\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What was pictured on the first stamp printed for the Christmas season?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Santa Claus</answer>\r\n\t\t\t<answer>An Angel</answer>\r\n\t\t\t<answer>A Star</answer>\r\n\t\t\t<answer correct=\"y\">A Rose</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"35\" interactionid=\"I0035\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">The poem commonly known as "The Night Before Christmas" was originally titled:</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>The Night Before Christmas</answer>\r\n\t\t\t<answer>Santa Claus is Coming to Town</answer>\r\n\t\t\t<answer correct=\"y\">A Visit from Saint Nicholas</answer>\r\n\t\t\t<answer>The Night Visitor</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"36\" interactionid=\"I0036\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Electric Christmas tree lights were first used in what year?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>1925</answer>\r\n\t\t\t<answer>1700</answer>\r\n\t\t\t<answer correct=\"y\">1895</answer>\r\n\t\t\t<answer>2007</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"37\" interactionid=\"I0037\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">At Christmas, it is customary to exchange kisses beneath a sprig of which plant?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Holly</answer>\r\n\t\t\t<answer correct=\"y\">Mistletoe</answer>\r\n\t\t\t<answer>Ivy</answer>\r\n\t\t\t<answer>Pine</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"38\" interactionid=\"I0038\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Which of these events did NOT occur on Christmas Day?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Hong Kong fell to the Japanese in WWII.</answer>\r\n\t\t\t<answer correct=\"y\">Ebenezer Scrooge was visited by four ghosts.</answer>\r\n\t\t\t<answer>King Arthur pulled Excalibur from the stone.</answer>\r\n\t\t\t<answer>Charlemagne was crowned Holy Roman Emperor.</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"39\" interactionid=\"I0039\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">In Tchaikovsky's ballet The Nutcracker, the nutcracker's main enemy is:</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>A girl named Clara</answer>\r\n\t\t\t<answer correct=\"y\">The King of Mice</answer>\r\n\t\t\t<answer>Drosselmeyer the Magician</answer>\r\n\t\t\t<answer>Dr. Almond</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"40\" interactionid=\"I0040\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Good King Wenceslas was king of which country?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Hungary</answer>\r\n\t\t\t<answer correct=\"y\">Bohemia</answer>\r\n\t\t\t<answer>Poland</answer>\r\n\t\t\t<answer>Czechoslavakia</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"41\" interactionid=\"I0041\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">When was Christmas first celebrated?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>The year after Jesus was crucified</answer>\r\n\t\t\t<answer>Around 100 AD</answer>\r\n\t\t\t<answer correct=\"y\">In the 4th century</answer>\r\n\t\t\t<answer>1935</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"42\" interactionid=\"I0042\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Why was December 25th chosen as Christmas Day?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>The birth of Jesus</answer>\r\n\t\t\t<answer correct=\"y\">To compete with a Pagan celebration at that time</answer>\r\n\t\t\t<answer>Christmas trees are in season</answer>\r\n\t\t\t<answer>The bible commands it</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"43\" interactionid=\"I0043\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What country did poinsettias originally come from?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>The U.S.</answer>\r\n\t\t\t<answer>Cuba</answer>\r\n\t\t\t<answer correct=\"y\">Mexico</answer>\r\n\t\t\t<answer>Brazil</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"44\" interactionid=\"I0044\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\"> How did Xmas originate as an abbreviation for Christmas?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Atheists refused to accept "Christ" as part of the word</answer>\r\n\t\t\t<answer>The early popes were lazy so they tended to shorten everything</answer>\r\n\t\t\t<answer correct=\"y\">The Greek word for Christ is Xristos</answer>\r\n\t\t\t<answer>From Latin terminology for any holy day</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"45\" interactionid=\"I0045\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">How many reindeer does Santa Claus have?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>8</answer>\r\n\t\t\t<answer>9</answer>\r\n\t\t\t<answer>0. They are caribou.</answer>\r\n\t\t\t<answer correct=\"y\">Santa has a whole herd of reindeer-- we only know about his favorite ones.</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"46\" interactionid=\"I0046\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What comes after '8 maids a-milking' in the song 'The 12 Days of Christmas'?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>9 pipers piping</answer>\r\n\t\t\t<answer>9 lords a-leaping</answer>\r\n\t\t\t<answer>9 drummers drummer</answer>\r\n\t\t\t<answer correct=\"y\">9 ladies dancing</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"47\" interactionid=\"I0047\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">When are the '12 Days of Christmas'?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>The 12 days before Christmas: December 14 to December 25</answer>\r\n\t\t\t<answer correct=\"y\">The 12 days after Christmas: December 26 to January 6</answer>\r\n\t\t\t<answer>The 12 days around Christmas: Christmas Eve to January 4</answer>\r\n\t\t\t<answer>The 12 days beginning with the winter solstice: December 21 to January 1</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"48\" interactionid=\"I0048\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Which of the following holidays DOES NOT occur in December?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer correct=\"y\">Candlemas</answer>\r\n\t\t\t<answer>Kwanzaa</answer>\r\n\t\t\t<answer>Feast of St. Nicholas</answer>\r\n\t\t\t<answer>Boxing Day</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"49\" interactionid=\"I0049\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Santa's only female sleigh-pulling reindeer, Vixen, has antlers. True or false?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>False. Only the male reindeer have antlers.</answer>\r\n\t\t\t<answer correct=\"y\"> True. Both male and female reindeer have antlers.</answer>\r\n\t\t\t<answer>True. But they are really no bigger than slight bumps on their heads.</answer>\r\n\t\t\t<answer>False. Some females have been known to have antlers, but that is extremely rare.</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"50\" interactionid=\"I0050\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">How many sides does a snowflake have?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer correct=\"y\">6</answer>\r\n\t\t\t<answer>8</answer>\r\n\t\t\t<answer>10</answer>\r\n\t\t\t<answer>12</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"51\" interactionid=\"I0051\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">What is the most popular holiday plant decoration in the United States?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Pine branches or evergreen boughs</answer>\r\n\t\t\t<answer>Mistletoe</answer>\r\n\t\t\t<answer>Holly</answer>\r\n\t\t\t<answer correct=\"y\">Poinsettia</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"53\" interactionid=\"I0053\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\"> In the movie 'Miracle on 34th Street', Kris Kringle is hired to play Santa Claus in what large department store?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>Sears</answer>\r\n\t\t\t<answer>Gimble's</answer>\r\n\t\t\t<answer correct=\"y\">Macy's</answer>\r\n\t\t\t<answer>Marshell Field's</answer>\r\n\t\t</item>\r\n\t\t<item>\r\n\t\t\t<type>mc</type>\r\n\t\t\t<question id=\"54\" interactionid=\"I0054\" points=\"10\" shuffle=\"y\" feedback=\"n\" feedbackok=\"Correct !\" feedbackwrong=\"Incorrect !\" attempts=\"9999\" expanded=\"1\">Speaking of 'Good King Wenceslas'... he looked out 'on the Feast of Stephen'. When is the 'Feast of Stephen'?</question>\r\n\t\t\t<scenario scinclude=\"0\"></scenario>\r\n\t\t\t<answer>December 6</answer>\r\n\t\t\t<answer>December 12</answer>\r\n\t\t\t<answer correct=\"y\">December 26</answer>\r\n\t\t\t<answer>January 6</answer>\r\n\t\t</item>\r\n\t</items>\r\n</quiz>\r\n";
email = "feedback@onemorelevel.com";
website = "http://www.onemorelevel.com";
function onQuizDataClass(success) {
var _local8 = myData.firstChild;
var _local4 = 0;
var _local3 = _local8.childNodes[0];
while (_local3.childNodes[_local4]) {
switch (_local3.childNodes[_local4].nodeName) {
case "reporting" :
_global.rep_enable = Boolean(Number(_local3.childNodes[_local4].attributes.enable));
_global.rep_level = Number(_local3.childNodes[_local4].attributes.level);
_global.rep_method = Number(_local3.childNodes[_local4].attributes.method);
_global.rep_scriptscoreurl = _local3.childNodes[_local4].attributes.scriptscoreurl;
_global.rep_scriptscoreget = Boolean(Number(_local3.childNodes[_local4].attributes.scriptscoreget));
_global.rep_scriptinteractionurl = _local3.childNodes[_local4].attributes.scriptinteractionurl;
_global.rep_scriptinteractionget = Boolean(Number(_local3.childNodes[_local4].attributes.scriptinteractionget));
_global.rep_emailtoemail = _local3.childNodes[_local4].attributes.toemail;
_global.rep_emailqbphphost = Boolean(Number(_local3.childNodes[_local4].attributes.qbphphost));
_global.rep_emailphpurl = _local3.childNodes[_local4].attributes.phpurl;
break;
case "quizid" :
_global.quizid = _global.RemoveCR(_local3.childNodes[_local4].firstChild);
break;
case "title" :
_global.title = _global.RemoveCR(_local3.childNodes[_local4].firstChild);
break;
case "login" :
_global.askuserid = Boolean(Number(_local3.childNodes[_local4].attributes.userid));
_global.askpassword = Boolean(Number(_local3.childNodes[_local4].attributes.password));
_global.presetpassword = Boolean(Number(_local3.childNodes[_local4].attributes.presetpassword));
_global.passwordvalue = _global.RemoveCR(_local3.childNodes[_local4].attributes.passwordvalue);
if ((_global.passwordvalue == "null") || (_global.passwordvalue == undefined)) {
_global.passwordvalue = "";
}
_global.passwordurl = _global.RemoveCR(_local3.childNodes[_local4].attributes.passwordurl);
if ((_global.passwordurl == "null") || (_global.passwordurl == undefined)) {
_global.passwordurl = "";
}
break;
case "size" :
_global.width = _local3.childNodes[_local4].attributes.width;
_global.height = _local3.childNodes[_local4].attributes.height;
_global.toc_width = Math.floor(_global.width / 3);
mccortina._width = _global.width;
mccortina._height = _global._height;
break;
case "design" :
_global.design.LoadFromXML(_local3.childNodes[_local4]);
break;
case "language" :
_global.lang.LoadFromXML(_local3.childNodes[_local4]);
break;
case "introduction" :
_global.introduction = _global.RemoveCR(_local3.childNodes[_local4].firstChild);
if ((_global.introduction == "null") || (_global.introduction == undefined)) {
_global.introduction = "";
}
_global.quizimg = _local3.childNodes[_local4].attributes.img;
_global.showintroduction = Boolean(Number(_local3.childNodes[_local4].attributes.show));
break;
case "qoptions" :
_global.qoptions.LoadFromXML(_local3.childNodes[_local4]);
break;
case "finish" :
_global.finish.LoadFromXML(_local3.childNodes[_local4]);
}
_local4++;
}
vtitle = _global.title;
_local4 = 0;
var _local6 = _local8.childNodes[1];
while (_local6.childNodes[_local4]) {
var _local5 = _local6.childNodes[_local4];
_qtype = _local5.childNodes[0].firstChild.nodeValue;
if (_qtype == "ed") {
_global.quizItems[_local4] = new TQEdit(_qtype);
}
if ((((_qtype == "tf") || (_qtype == "mc")) || (_qtype == "mr")) || (_qtype == "wb")) {
_global.quizItems[_local4] = new TQBase(_qtype);
}
if (_qtype == "mdd") {
_global.quizItems[_local4] = new TQMatchdd(_qtype);
}
if (_qtype == "cz") {
_global.quizItems[_local4] = new TQClickZone(_qtype);
}
if (_qtype == "odd") {
_global.quizItems[_local4] = new TQOrderdd(_qtype);
}
_global.quizItems[_local4].LoadFromXML(_local5);
_local4++;
}
if (_global.qoptions.all == true) {
_global.qoptions.nrquestions = _global.quizItems.length;
}
if (_global.qoptions.nrquestions > _global.quizItems.length) {
_global.qoptions.nrquestions = _global.quizItems.length;
}
if (_global.qoptions.randomize == true) {
_global.quizItems.sort(function () {
return(random(5) - 1);
});
}
var _local7 = new ContextMenu();
_local7.hideBuiltInItems();
if (_global.design.dinfo == true) {
var _local9 = new ContextMenuItem("Go to Tanida Quiz Builder website", WebHandler);
_local7.customItems.push(_local9);
}
this.menu = _local7;
}
function WebHandler(obj, menuItem) {
getURL ("http://www.quiz-builder.com", "_blank");
}
function Pad(avalue) {
if (length(avalue) == 1) {
return("0" + avalue);
}
return(avalue);
}
function GetDateAsString(date) {
if (date == 0) {
return(date);
}
var _local2;
_local2 = (((Pad(date.getMonth() + 1) + "/") + Pad(date.getDate())) + "/") + date.getFullYear();
return(_local2);
}
function GetTimeAsString(date) {
if (date == 0) {
return(date);
}
var _local2;
_local2 = (((Pad(date.getHours()) + ":") + Pad(date.getMinutes())) + ":") + Pad(date.getSeconds());
return(_local2);
}
_global.RemoveCR = function (astring) {
var _local2;
var _local7;
var _local4;
var _local5;
var _local8;
var _local1;
var _local6;
_local2 = new String(astring);
_local5 = new String(_local2);
var _local3 = ["&", "&", "<", "<", ">", ">", "'", "'", """, "\"", "²", "\u00B2", "³", "\u00B3", "™", "T"];
_local1 = 0;
while (_local1 < _local3.length) {
_local5 = _local5.split(_local3[_local1]).join(_local3[_local1 + 1]);
_local1 = _local1 + 2;
}
_local2 = _local5;
_local7 = String.fromCharCode(13) + String.fromCharCode(10);
_local8 = _local2.indexOf(_local7);
if (_local8 != -1) {
_local4 = new String();
_local1 = 0;
while (_local1 < _local2.length) {
_local6 = _local2.charCodeAt(_local1);
if (_local6 != 13) {
_local4 = _local4 + _local2.charAt(_local1);
}
_local1++;
}
return(String(_local4));
}
return(String(_local2));
};
_global.GoToQuestion = function (aindex) {
_global.currentQuestionNumber = aindex;
if (_global.qoptions.submitone == true) {
_global.qreview = _global.quizItems[aindex - 1].completed;
} else {
_global.qreview = false;
}
if ((aindex > 0) && (aindex <= _global.qoptions.nrquestions)) {
} else {
_global.currentQuestionNumber = 1;
}
gotoAndStop ("process");
};
_global.CumulativeScore = function () {
var _local2;
var _local3;
_local3 = 0;
_local2 = 0;
while (_local2 < _global.qoptions.nrquestions) {
_local3 = _local3 + _global.quizItems[_local2].ResultPoints();
_local2++;
}
return(_local3);
};
_global.ComputeUserScore = function () {
var _local2;
var _local3;
_local3 = 0;
_global.userpoints = 0;
_local2 = 0;
while (_local2 < _global.qoptions.nrquestions) {
_local3 = _local3 + _global.quizItems[_local2].points;
_global.userpoints = _global.userpoints + _global.quizItems[_local2].ResultPoints();
_local2++;
}
_global.totalpoints = _local3;
_global.passedpoints = Math.round((_global.passedscore * _local3) / 100);
if (_local3 == 0) {
_global.userscore = 0;
} else {
_global.userscore = (100 * _global.userpoints) / _local3;
}
_global.userscore = Math.round(100 * _global.userscore) / 100;
if (_global.userscore >= _global.passedscore) {
_global.passed = true;
} else {
_global.passed = false;
}
};
onLoadScore = function (success) {
if (success == false) {
mcfeed.Show(_global.GetText("connectionfailreportscore"), "btnfeedcontinue", false);
}
};
onLoadXML = function (success) {
if (success == false) {
mcfeed.Showynretry("connectionfailreportscore");
}
};
_global.SendXML = function () {
var _local2;
if (_global.rep_emailqbphphost == true) {
_local2 = "http://quiz-builder.com/report/postxml_errooooooo.php";
} else {
_local2 = _global.rep_emailphpurl;
}
var _local3 = new XML();
_local3.onLoad = onLoadXML;
_global.my_xml.sendAndLoad(_local2, _local3);
};
XMLAddNode = function (my_xml, node_parent, node_name, node_value) {
var _local1 = my_xml.createElement(node_name);
var _local2 = my_xml.createTextNode(node_value);
_local1.appendChild(_local2);
node_parent.appendChild(_local1);
};
ReportScore = function () {
if (_global.rep_enable == true) {
switch (_global.rep_method) {
case 0 :
case 1 :
var _local5;
if (_global.IsAnswered == false) {
_local5 = _global.GetText("reportincomplete");
} else if (_global.passed == true) {
_local5 = _global.GetText("reportpassed");
} else {
_local5 = _global.GetText("reportfailed");
}
_local5 = (_local5 + ";") + _global.userscore;
_local5 = (_local5 + ";0;100;") + _global.passedscore;
_local5 = (_local5 + ";") + (_global.userscore / 100);
fscommand ("ReportScore", _local5);
break;
case 2 :
l1.elapsedtime = _global.FormatTime(_global.timeelapsed);
l1.passingscore = _global.passedscore;
l1.userscore = _global.userscore;
l1.maxpoints = _global.totalpoints;
l1.passingpoints = _global.passedpoints;
l1.userpoints = _global.userpoints;
if (_global.IsAnswered == false) {
l1.status = _global.GetText("reportincomplete");
} else if (_global.passed == true) {
l1.status = _global.GetText("reportpassed");
} else {
l1.status = _global.GetText("reportfailed");
}
l1.userid = _global.userid;
l1.quizid = _global.quizid;
l1.timestamp = new Date().getTime();
l1.sessionid = _global.sessionid;
var _local10;
_local10 = "GET";
if (_global.rep_scriptscoreget == false) {
_local10 = "POST";
}
l2.onLoad = onLoadScore;
l1.sendAndLoad(_global.rep_scriptscoreurl, l2, _local10);
break;
case 3 :
_global.my_xml = new XML("");
_global.my_xml.contentType = "text/xml";
_global.my_xml.ignoreWhite = true;
var _local7 = _global.my_xml.createElement("quiz");
_global.my_xml.appendChild(_local7);
var _local8 = _global.my_xml.createElement("user");
_local7.appendChild(_local8);
XMLAddNode(_global.my_xml, _local8, "emailto", _global.rep_emailtoemail);
XMLAddNode(_global.my_xml, _local8, "emaillicensed", "test@test.com");
var _local4 = _global.my_xml.createElement("general");
_local7.appendChild(_local4);
XMLAddNode(_global.my_xml, _local4, "quizid", _global.quizid);
XMLAddNode(_global.my_xml, _local4, "quiztitle", _global.title);
XMLAddNode(_global.my_xml, _local4, "userid", _global.userid);
var _local11;
if (_global.passed == true) {
_local11 = _global.GetText("reportpassed");
} else {
_local11 = _global.GetText("reportfailed");
}
XMLAddNode(_global.my_xml, _local4, "status", _local11);
XMLAddNode(_global.my_xml, _local4, "userpoints", _global.userpoints);
XMLAddNode(_global.my_xml, _local4, "passingpoints", _global.passedpoints);
XMLAddNode(_global.my_xml, _local4, "maxpoints", _global.totalpoints);
XMLAddNode(_global.my_xml, _local4, "userscore", _global.userscore);
XMLAddNode(_global.my_xml, _local4, "passingscore", _global.passedscore);
XMLAddNode(_global.my_xml, _local4, "timeelapsed", _global.FormatTime(_global.timeelapsed));
var _local9 = new Date();
XMLAddNode(_global.my_xml, _local4, "date", GetDateAsString(_local9));
XMLAddNode(_global.my_xml, _local4, "time", GetTimeAsString(_local9));
if (_global.rep_level == 1) {
var _local6 = _global.my_xml.createElement("interactions");
_local7.appendChild(_local6);
var _local2;
_local2 = 0;
while (_local2 < _global.qoptions.nrquestions) {
var _local3 = _global.my_xml.createElement("interaction");
_local6.appendChild(_local3);
_global.quizItems[_local2].GenerateXML(_global.my_xml, _local3);
_local2++;
}
}
_global.SendXML();
}
}
};
onLoadInteraction = function (success) {
if (success == false) {
mcfeed.Show(_global.GetText("connectionfailreportinteraction"), "btnfeedcontinue", false);
}
};
ReportInteraction = function (aindex) {
if (_global.rep_level == 1) {
if (_global.rep_enable == true) {
var _local3;
_local3 = _global.quizItems[aindex];
switch (_global.rep_method) {
case 0 :
case 1 :
_global.response_separator = _global.response_separator_scorm2004;
if (_global.scoversion == 0) {
_global.response_separator = _global.response_separator_scorm12;
}
var _local2;
_local2 = "";
_local2 = (_local2 + _local3.interactionid) + _global.interaction_separator;
_local2 = (_local2 + _local3.GetTypeAsStringLMS()) + _global.interaction_separator;
_local2 = (_local2 + _local3.GetCorrectResponseAsStringLMS()) + _global.interaction_separator;
_local2 = (_local2 + "1") + _global.interaction_separator;
_local2 = (_local2 + _local3.GetResponseAsStringLMS()) + _global.interaction_separator;
if (_local3.IsAnswered() == false) {
_local2 = _local2 + _global.GetText("reportiincomplete");
} else if (_local3.UserResponse() == true) {
_local2 = _local2 + "correct";
} else if (_global.scoversion == 1) {
_local2 = _local2 + "incorrect";
} else {
_local2 = _local2 + "wrong";
}
_local2 = _local2 + _global.interaction_separator;
_local2 = (_local2 + _local3.latency) + _global.interaction_separator;
_local2 = (_global.nointeraction + _global.interaction_separator) + _local2;
fscommand ("ReportInteraction", _local2);
_global.nointeraction = _global.nointeraction + 1;
break;
case 2 :
_global.response_separator = _global.response_separator_script;
l3.latency = _local3.GetLatency();
l3.weight = 1;
l3.points = _local3.ResultPoints();
if (_local3.IsAnswered() == false) {
l3.result = _global.GetText("reportiincomplete");
} else if (_local3.UserResponse() == true) {
l3.result = _global.GetText("reporticorrect");
} else {
l3.result = _global.GetText("reportiincorrect");
}
l3.userresponse = _local3.GetResponseAsString();
l3.interactiontype = _local3.GetTypeAsString();
l3.interactionid = _local3.interactionid;
l3.time = _local3.GetTimeAsString();
l3.date = _local3.GetDateAsString();
l3.userid = _global.userid;
l3.quizid = _global.quizid;
l3.timestamp = new Date().getTime();
l3.sessionid = _global.sessionid;
var _local4;
_local4 = "GET";
if (_global.rep_scriptinteractionget == false) {
_local4 = "POST";
}
if (_global.qoptions.submitone == true) {
l4.onLoad = onLoadInteraction;
l3.sendAndLoad(_global.rep_scriptinteractionurl, l4, _local4);
} else {
l3.sendAndLoad(_global.rep_scriptinteractionurl, l5, _local4);
}
}
}
}
};
_global.IsAnswered = function () {
var _local2;
_local2 = 0;
while (_local2 < _global.qoptions.nrquestions) {
if (_global.quizItems[_local2].IsAnswered() == false) {
return(false);
}
_local2++;
}
return(true);
};
_global.NextQuestion = function () {
var _local2;
var _local3;
_local3 = _global.currentQuestionNumber;
if (_local3 < _global.qoptions.nrquestions) {
_local2 = _local3;
while (_local2 < _global.qoptions.nrquestions) {
if (_global.quizItems[_local2].completed == false) {
_global.currentQuestionNumber = _local2 + 1;
return(undefined);
}
_local2++;
}
}
_local2 = 0;
while (_local2 < _global.qoptions.nrquestions) {
if (_global.quizItems[_local2].IsAnswered() == false) {
_global.currentQuestionNumber = _local2 + 1;
return(undefined);
}
_local2++;
}
_global.currentQuestionNumber = _global.qoptions.nrquestions + 1;
};
_global.settextformat = function (aitem, atext) {
var _local1;
_local1 = aitem.getTextFormat();
_local1.font = atext.name;
_local1.size = atext.size;
_local1.color = atext.color;
_local1.bold = atext.bold;
_local1.italic = atext.italic;
aitem.setTextFormat(_local1);
};
_global.setbuttontextformat = function (item) {
_global.settextformat(item.t, _global.design.bfont);
if (item.b.enabled == false) {
var _local3;
_local3 = item.t.getTextFormat();
_local3.color = _global.cldisable;
item.t.setTextFormat(_local3);
}
item.t._width = item.b._width;
item.t.wordWrap = false;
item.t.autoSize = "left";
item.t._x = Math.floor((item.b._width - item.t._width) / 2);
item.t._y = Math.floor((item.b._height - item.t._height) / 2) + 1;
};
_global.setbuttons = function () {
if (_global.review == false) {
if (_global.qoptions.submitone == true) {
bsubmit._visible = !_global.qreview;
bsubmitall._visible = false;
brevprev._visible = false;
brevnext._visible = false;
brevprev.b.enabled = false;
brevnext.b.enabled = false;
} else {
bsubmit._visible = false;
bsubmitall._visible = true;
brevprev._visible = true;
brevnext._visible = true;
brevprev.b.enabled = _global.currentQuestionNumber != 1;
brevnext.b.enabled = _global.currentQuestionNumber != _global.qoptions.nrquestions;
}
} else {
bsubmit._visible = false;
bsubmitall._visible = true;
brevprev._visible = true;
brevnext._visible = true;
brevprev.b.enabled = _global.currentQuestionNumber != 1;
brevnext.b.enabled = _global.currentQuestionNumber != _global.qoptions.nrquestions;
}
if (_global.qoptions.submitone == true) {
if (_global.design.dtoc == false) {
if (((_global.qoptions.take == true) && (_global.review == false)) && (_global.currentQuestionNumber < _global.qoptions.nrquestions)) {
take._visible = true;
} else {
take._visible = false;
}
take.Uncheck();
} else {
take.Uncheck();
take._visible = false;
}
} else {
take._visible = false;
}
if (_global.design.dtoc == true) {
btoc._visible = true;
take.Uncheck();
take._visible = false;
} else {
btoc._visible = false;
}
if (_global.paused == true) {
bsubmit._visible = false;
take._visible = false;
btoc._visible = false;
}
};
_global.ResizeTitle = function () {
var _local4 = 0;
if (mctable._minimize == false) {
_local4 = _global.toc_width;
}
mccortina._width = _global.width;
mccortina._height = _global._height;
title._x = _local4 + _global.title_x;
title._y = _global.title_y;
title._xscale = 100;
title._yscale = 100;
title._width = ((_global.width - title._x) - _global.border) - 5;
if (timer._visible == true) {
title._width = title._width - (_global.width - timer._x);
}
_global.settextformat(title, _global.design.tfont);
title.wordWrap = false;
title.autoSize = false;
cback._width = _global.width;
cback._height = _global.height;
var _local19 = new Color(cback);
_local19.setRGB(_global.design.backcolor);
layoutback._x = _local4;
_global.drawback(layoutback, _global.width - _local4, _global.height, "box", _global.design.qback);
layoutup._x = _local4 + _global.border;
layoutup._y = (title._y + title._height) + _global.layoutup_dy;
var _local5;
var _local18;
var _local2;
var _local17;
_local5 = (_global.width - _local4) - (2 * _global.border);
info._x = layoutup._x + _global.info_dx;
info._width = _local5 - _global.info_dx;
if (_global.review == false) {
if (_global.currentlabel == "q") {
if (_global.design.dnumbering == true) {
switch (_global.design.numberingstyle) {
case "0" :
infotext = _global.FormatText(_global.GetText("questionnumbering1bar"), _global.currentQuestionNumber);
break;
case "1" :
infotext = _global.FormatText(_global.GetText("questionnumbering2bar"), _global.currentQuestionNumber);
break;
case "2" :
infotext = _global.FormatText(_global.FormatText(_global.GetText("questionnumbering3bar"), _global.currentQuestionNumber), _global.qoptions.nrquestions);
break;
default :
infotext = _global.FormatText(_global.FormatText(_global.GetText("questionnumbering4bar"), _global.currentQuestionNumber), _global.qoptions.nrquestions);
}
} else {
infotext = "";
}
if (_global.design.dpoints == true) {
if (infotext != "") {
infotext = infotext + _global.GetText("delimiterbar");
}
infotext = infotext + _global.FormatText(_global.GetText("pointsbar"), currentQuizItem.points);
}
if (_global.design.dcscore == true) {
if (infotext != "") {
infotext = infotext + _global.GetText("delimiterbar");
}
infotext = infotext + _global.FormatText(_global.GetText("cscorebar"), _global.CumulativeScore());
}
if (_global.paused == true) {
infotext = _global.GetText("pausebar");
}
} else if (_global.currentlabel == "login") {
infotext = _global.GetText("loginbar");
} else {
infotext = _global.GetText("introductionbar");
}
} else if (_global.currentlabel == "summary") {
if (_global.passed == true) {
infotext = _global.GetText("passedbar");
} else {
infotext = _global.GetText("failedbar");
}
} else if (_global.quizItems[_global.currentQuestionNumber - 1].completed == false) {
infotext = _global.FormatText(_global.GetText("incompletebar"), _global.currentQuestionNumber);
} else if (_global.quizItems[_global.currentQuestionNumber - 1].UserResponse() == true) {
infotext = _global.FormatText(_global.GetText("correctbar"), _global.currentQuestionNumber);
} else {
infotext = _global.FormatText(_global.GetText("incorrectbar"), _global.currentQuestionNumber);
}
_global.settextformat(info, _global.design.qbfont);
info.wordWrap = false;
info.autoSize = true;
_local2 = info._height + 24;
var _local10;
_local10 = Math.max(binfo._height, bsoundon._height);
if (bprint != undefined) {
_local10 = Math.max(_local10, bprint._height);
}
if (bemail != undefined) {
_local10 = Math.max(_local10, bemail._height);
}
if (breview != undefined) {
_local10 = Math.max(_local10, breview._height);
}
if (_local2 < (_local10 + 16)) {
_local2 = _local10 + 16;
}
_local17 = _local2;
_local18 = _local5;
if (_global.review == false) {
_global.drawback(layoutup, _local5, _local2, _global.qb, _global.design.qbback);
} else {
if (_global.currentlabel == "summary") {
if (_global.passed == true) {
_global.design.qbback2.fill = _global.clgreen;
} else {
_global.design.qbback2.fill = _global.clred;
}
} else if (_global.quizItems[_global.currentQuestionNumber - 1].completed == true) {
if (_global.quizItems[_global.currentQuestionNumber - 1].UserResponse() == true) {
_global.design.qbback2.fill = _global.clgreen;
} else {
_global.design.qbback2.fill = _global.clred;
}
} else {
_global.design.qbback2.fill = _global.clyellow;
}
_global.drawback(layoutup, _local5, _local2, _global.qb, _global.design.qbback2);
}
info._y = layoutup._y + ((_local2 - info._height) / 2);
var _local6;
var _local13;
_local13 = (layoutup._y + Math.floor((_local2 - binfo._height) / 2)) - 1;
_local6 = (layoutup._x + _local5) - _global.binfo_dx;
if (_global.design.dinfo == true) {
binfo._x = _local6 - binfo._width;
binfo._y = _local13;
binfo._visible = true;
_local6 = (binfo._x - _global.bar_spacebtn) + 6;
} else {
binfo._visible = false;
}
if (_global.design.daudio == true) {
bsoundon._visible = _global.audioon == true;
bsoundoff._visible = _global.audioon != true;
bsoundon._y = _local13;
bsoundon._x = _local6 - bsoundon._width;
bsoundoff._y = bsoundon._y;
bsoundoff._x = bsoundon._x;
_local6 = bsoundon._x - _global.bar_spacebtn;
} else {
bsoundon._visible = false;
bsoundoff._visible = false;
}
if (_global.design.print == true) {
bprint._visible = true;
bprint._y = _local13;
bprint._x = _local6 - bprint._width;
_local6 = bprint._x - _global.bar_spacebtn;
} else {
bprint._visible = false;
}
if (_global.design.email == true) {
bemail._visible = true;
bemail._y = _local13 - 1;
bemail._x = _local6 - bemail._width;
_local6 = bemail._x - _global.bar_spacebtn;
} else {
bemail._visible = false;
}
if (_global.design.review == true) {
breview._visible = true;
breview._y = _local13;
breview._x = _local6 - breview._width;
_local6 = breview._x - _global.bar_spacebtn;
} else {
breview._visible = false;
}
if (scenariol._visible == true) {
scenariol._x = layoutup._x;
scenariol._y = (layoutup._y + _local2) - 2;
scenariol.t.text = _global.GetText("scenariol");
_global.settextformat(scenariol.t, _global.design.qbfont);
scenariol.t._height = scenariol.t.textHeight + 4;
scenariol.t._x = _global.info_dx;
scenariol.t._y = _global.scenario_dy;
scenariol.t.wordWrap = false;
scenariol.autoSize = true;
_local5 = (scenariol.t.textWidth + 15) + _global.question_dx1;
_local2 = scenariol.t.textHeight + 15;
_global.drawback(scenariol, _local5, _local2, "box", _global.design.qbback);
scenario._x = (scenariol._x + _local5) + 5;
scenario.t.wordWrap = true;
scenario.t._width = (_global.width - scenario._x) - _global.question_dx2;
_global.settextformat(scenario.t, _global.design.sfont);
scenario.t.autoSize = true;
scenario._y = scenariol._y + 4;
vquestion._y = (scenariol._y + Math.max(_local2, scenario._height)) + _global.question_dy;
} else {
vquestion._y = (layoutup._y + _local2) + _global.question_dy;
}
vquestion._x = _local4 + _global.question_dx1;
_global.settextformat(vquestion, _global.design.qfont);
vquestion.autoSize = true;
vquestion.wordWrap = true;
vquestion._width = (_global.width - vquestion._x) - _global.question_dx2;
_global.setbuttons();
if (bcontinue != undefined) {
bcontinue._x = (_global.width - _global.buttons_dx) - bcontinue._width;
bcontinue._y = (_global.height - _global.buttons_dy) - bcontinue._height;
if (_global.currentlabel == "login") {
bcontinue.t.text = _global.GetText("btnlogin");
} else {
bcontinue.t.text = _global.GetText("btnstart");
}
_global.setbuttontextformat(bcontinue);
}
if (bsubmit != undefined) {
bsubmit._x = (_global.width - _global.buttons_dx) - bsubmit.b._width;
bsubmit._y = (_global.height - _global.buttons_dy) - bsubmit.b._height;
bsubmit.t.text = _global.GetText("btnsubmit");
_global.setbuttontextformat(bsubmit);
}
if (brevnext != undefined) {
brevnext._x = (_global.width - _global.buttons_dx) - brevnext._width;
brevnext._y = (_global.height - _global.buttons_dy) - brevnext._height;
brevnext.t.text = _global.GetText("btnnext");
_global.setbuttontextformat(brevnext);
brevprev._y = brevnext._y;
brevprev._x = brevnext._x - brevprev._width;
brevprev.t.text = _global.GetText("btnback");
_global.setbuttontextformat(brevprev);
bsubmitall._y = brevprev._y;
bsubmitall._x = (brevprev._x - bsubmitall._width) - _global.bsubmitall_dx;
if (_global.review == true) {
bsubmitall.t.text = _global.GetText("btnreviewfinish");
} else {
bsubmitall.t.text = _global.GetText("btnsubmitall");
}
_global.setbuttontextformat(bsubmitall);
}
if (bfinish != undefined) {
bfinish._x = (_global.width - _global.buttons_dx) - bfinish._width;
bfinish._y = (_global.height - _global.buttons_dy) - bfinish._height;
bfinish.t.text = _global.GetText("btnfinish");
_global.setbuttontextformat(bfinish);
}
if (btoc._visible == true) {
btoc._x = (_local4 + _global.buttons_dx) + 10;
btoc._y = ((_global.height - _global.buttons_dy) - 30) + 2;
}
if (take._visible == true) {
take.Resize();
take._x = _local4 + _global.buttons_dx;
take._y = (_global.height - _global.buttons_dy) - take._height;
}
layoutdown._x = layoutup._x + 5;
layoutdown._y = (_global.height - _global.layoutdown_dy) - layoutdown._height;
layoutdown.clear();
layoutdown.lineStyle(1, 0, 100);
layoutdown.moveTo(0, 0);
layoutdown.lineTo(((_global.width - _local4) - (2 * _global.border)) - 14, 0);
scroll._xscale = 100;
scroll._yscale = 100;
scroll.contentMain._xscale = 100;
scroll.contentMain._yscale = 100;
scroll._y = (vquestion._y + vquestion._height) + _global.scroll_dy;
scroll._x = _local4 + _global.scroll_dx1;
_global.scroll_w = (_global.width - scroll._x) - _global.scroll_dx2;
_global.scroll_h = (layoutdown._y - scroll._y) - 3;
scroll.Resize();
intro._x = layoutup._x + _global.intro_dx;
intro._y = (layoutup._y + _local2) + _global.intro_dy;
if (_global.quizimg == "y") {
intro.t._width = ((_local5 - (2 * _global.intro_dx)) - quizimg._width) - 20;
quizimg._y = intro._y;
quizimg._x = (intro._x + intro._width) + _global.intro_dx;
quizimg._visible = true;
} else {
intro.t._width = (_local5 - (2 * _global.intro_dx)) - 4;
quizimg._visible = false;
}
intro.t._height = ((layoutdown._y - intro._y) - layoutdown._height) - 2;
_global.settextformat(intro.t, _global.design.ifont);
if (_global.currentlabel == "login") {
var _local16;
var _local15;
var _local12;
var _local9;
var _local11;
_local16 = 5;
_local15 = 20;
if (_global.askuserid == true) {
loginl._visible = true;
logind._visible = true;
loginl.text = _global.GetText("loginlabel");
_global.settextformat(loginl, _global.design.lfont);
loginl.wordWrap = false;
loginl.autoSize = true;
} else {
loginl._visible = false;
logind._visible = false;
}
if (_global.askpassword == true) {
passwordl._visible = true;
passwordd._visible = true;
passwordl.text = _global.GetText("passwordlabel");
_global.settextformat(passwordl, _global.design.lfont);
passwordl.wordWrap = false;
passwordl.autoSize = true;
} else {
passwordl._visible = false;
passwordd._visible = false;
}
if ((_global.askuserid == true) && (_global.askpassword == true)) {
_local12 = Math.max(loginl._width, passwordl._width);
_local9 = Math.max(loginl._height, logind._height);
} else if ((_global.askuserid == false) && (_global.askpassword == false)) {
_local12 = 0;
_local9 = 0;
} else if (_global.askuserid == true) {
_local12 = loginl._width;
_local9 = loginl._height;
} else {
_local12 = passwordl._width;
_local9 = passwordl._height;
}
loginl._x = Math.floor((((_global.width - _local12) - _local15) - logind._width) / 2.5);
logind._x = (loginl._x + _local12) + _local15;
passwordl._x = loginl._x;
passwordd._x = logind._x;
_local11 = (layoutup._y + _local2) + Math.floor(((((layoutdown._y - layoutup._y) - _local2) - (2 * _local9)) - _local16) / 4);
loginl._y = (_local11 + Math.floor((_local9 - loginl._height) / 2)) - 2;
logind._y = _local11 + Math.floor((_local9 - logind._height) / 2);
if (_global.askuserid == true) {
_local11 = (_local11 + _local16) + _local9;
}
passwordl._y = (_local11 + Math.floor((_local9 - passwordl._height) / 2)) + 2;
passwordd._y = _local11 + Math.floor((_local9 - passwordd._height) / 2);
}
if (_global.paused == true) {
mctake.Resize();
}
mcfeed.Resize();
if (mcend != undefined) {
if (_global.passedscore == 0) {
mcend._visible = false;
} else {
mcend._visible = true;
}
mcend.lyour.text = _global.GetText("yslabel");
mcend.lpassed.text = _global.GetText("pslabel");
mcend.vuserpoints.text = _global.FormatText(_global.GetText("pointslabel"), _global.userpoints);
mcend.vpassedpoints.text = _global.FormatText(_global.GetText("pointslabel"), _global.passedpoints);
mcend.vuserscore.text = _global.userscore + " %";
mcend.vpassedscore.text = _global.passedscore + " %";
_global.settextformat(mcend.lyour, _global.design.ffont);
var _local8;
_local8 = mcend.lyour.getTextFormat();
_local8.bold = true;
mcend.lyour.setTextFormat(_local8);
mcend.lyour.wordWrap = false;
mcend.lyour.autoSize = true;
_global.settextformat(mcend.lpassed, _global.design.ffont);
_local8 = mcend.lpassed.getTextFormat();
_local8.bold = true;
mcend.lpassed.setTextFormat(_local8);
mcend.lpassed.wordWrap = false;
mcend.lpassed.autoSize = true;
_global.settextformat(mcend.vuserpoints, _global.design.ffont);
mcend.vuserpoints.wordWrap = false;
mcend.vuserpoints.autoSize = true;
_global.settextformat(mcend.vuserscore, _global.design.ffont);
mcend.vuserscore.wordWrap = false;
mcend.vuserscore.autoSize = true;
_global.settextformat(mcend.vpassedpoints, _global.design.ffont);
mcend.vpassedpoints.wordWrap = false;
mcend.vpassedpoints.autoSize = true;
_global.settextformat(mcend.vpassedscore, _global.design.ffont);
mcend.vpassedscore.wordWrap = false;
mcend.vpassedscore.autoSize = true;
var _local3;
var _local7;
_local3 = Math.max(mcend.lyour._width, mcend.vuserpoints._width);
_local3 = Math.max(_local3, mcend.vuserscore._width);
_local7 = Math.max(mcend.lpassed._width, mcend.vpassedpoints._width);
_local7 = Math.max(_local7, mcend.vpassedscore._width);
_local3 = Math.max(_local3, _local7);
_local3 = _local3 + 23;
_local7 = 3;
mcend.lyour._x = 0;
mcend.lyour._y = 0;
mcend.vuserpoints._x = 0;
mcend.vuserpoints._y = (mcend.lyour._y + mcend.lyour._height) + _local7;
mcend.vuserscore._x = 0;
mcend.vuserscore._y = (mcend.vuserpoints._y + mcend.vuserpoints._height) + _local7;
mcend.lpassed._x = _local3 + 1;
mcend.lpassed._y = 0;
mcend.vpassedpoints._x = _local3 + 1;
mcend.vpassedpoints._y = (mcend.lpassed._y + mcend.lpassed._height) + _local7;
mcend.vpassedscore._x = _local3 + 1;
mcend.vpassedscore._y = (mcend.vpassedpoints._y + mcend.vpassedpoints._height) + _local7;
mcend.vmessage._visible = _global.design.passfailmessages;
if (_global.passed == true) {
mcend.vmessage.text = _global.design.passmessage;
} else {
mcend.vmessage.text = _global.design.failmessage;
}
_global.settextformat(mcend.vmessage, _global.design.ffont);
_local8 = mcend.vmessage.getTextFormat();
if (_global.passed == true) {
_local8.color = clgreen;
} else {
_local8.color = clred;
}
mcend.vmessage.setTextFormat(_local8);
mcend.vmessage._width = 2 * _local3;
mcend.vmessage.autoSize = true;
mcend.vmessage._x = 0;
mcend.vmessage._y = (mcend.vpassedscore._y + mcend.vpassedscore._height) + (2 * _local7);
mcend.clear();
mcend.lineStyle(1, 6710886, 100);
mcend.moveTo(0, mcend.vuserpoints._y - 5);
mcend.lineTo((2 * _local3) + 1, mcend.vuserpoints._y - 5);
mcend.moveTo(_local3 - 1, mcend.vuserpoints._y - 5);
mcend.lineTo(_local3 - 1, mcend.vmessage._y - 5);
}
var _local14;
_local14 = (layoutup._y + _local17) - 2;
mcend._y = _local14 + 30;
_local14 = layoutup._x;
mcend._x = _local14 + Math.floor((_local18 - mcend._width) / 2);
};
_global.FormatTime = function (atime) {
var _local2;
var _local3;
var _local4;
var _local5;
var _local1;
_local1 = "";
_local2 = Math.round(atime / 1000);
_local3 = (_local2 - (_local2 % 3600)) / 3600;
_local2 = _local2 - (_local3 * 3600);
_local4 = (_local2 - (_local2 % 60)) / 60;
_local5 = _local2 % 60;
if (_local3 < 10) {
_local1 = "0";
}
_local1 = (_local1 + _local3) + ":";
if (_local4 < 10) {
_local1 = _local1 + "0";
}
_local1 = (_local1 + _local4) + ":";
if (_local5 < 10) {
_local1 = _local1 + "0";
}
_local1 = _local1 + _local5;
return(String(_local1));
};
_global.FormatText = function (AText, AValue) {
var _local1;
_local1 = AText.indexOf("%s");
if (_local1 < 0) {
return(AText);
}
var _local2;
if (_local1 > 0) {
_local2 = AText.substr(0, _local1);
} else {
_local2 = "";
}
_local2 = (_local2 + AValue) + AText.substr(_local1 + 2, (AText.length - _local1) - 2);
return(_local2);
};
_global.GetText = function (AId) {
return(_global.lang.GetText(AId));
};
_global.newchunk = function (aitemp, aimg, alevel, aback, atitlecolor) {
var _local1 = aitemp.duplicateMovieClip("chunk" + alevel, alevel);
level++;
_local1.attachMovie(aimg, "b", 10);
var _local3 = new Color(_local1.b.fill);
_local3.setRGB(aback.fill);
_local3 = new Color(_local1.b.border);
_local3.setRGB(aback.border);
_local1.b.shadow._visible = aback.shadow;
if (atitlecolor != undefined) {
_local3 = new Color(_local1.b.titleback);
_local3.setRGB(atitlecolor);
}
return(_local1);
};
_global.drawback = function (aitem, aw, ah, aimg, aback, ady, atitlecolor) {
var itemp = aitem.mcback.chunk;
var w;
var h;
var dx;
var dy;
var dy1;
var level;
var w1;
var w2;
var h1;
var h2;
var wrect;
var hrect;
var i;
var nr = 300;
if (aitem.mcback.maxlevel != undefined) {
i = 5;
while (i < aitem.mcback.maxlevel) {
item = eval ((aitem.mcback + ".chunk") + Number(i));
item.removeMovieClip();
i++;
}
}
if (aback.enable == false) {
itemp._visible = false;
return(undefined);
}
w = aw;
h = ah;
dx = 10;
dy = 10;
if (ady == undefined) {
dy1 = 10;
} else {
dy1 = ady;
}
level = 5;
var item = _global.newchunk(itemp, aimg, level, aback, atitlecolor);
level++;
wrect = item.b._width;
hrect = item.b._height;
if ((wrect == 0) || (hrect == 0)) {
return(undefined);
}
item.m._width = dx;
item.m._height = dy1;
item.m.swapDepths(11);
item.m._visible = false;
item.b.setMask(item.m);
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
item.m._width = dx;
item.m._height = dy;
item.m._y = hrect - dy;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._y = h - hrect;
w1 = w - (2 * dx);
w2 = wrect - (2 * dx);
if (w <= wrect) {
var item = _global.newchunk(itemp, aimg, level, aback, atitlecolor);
level++;
item.m._width = w1;
item.m._height = dy1;
item.m._x = dx;
item.m.swapDepths(11);
item.b.setMask(item.m);
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
item.m._width = w1;
item.m._height = dy;
item.m._x = dx;
item.m._y = hrect - dy;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._y = h - hrect;
} else {
w2 = w2 - dx;
nr = Math.floor(w1 / w2);
i = 1;
while (i <= (nr + 1)) {
var item = _global.newchunk(itemp, aimg, level, aback, atitlecolor);
level++;
if (i <= nr) {
item.m._width = w2;
} else {
item.m._width = w1 - (nr * w2);
}
item.m._height = dy1;
item.m._x = dx;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._x = (i - 1) * w2;
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
if (i <= nr) {
item.m._width = w2;
} else {
item.m._width = w1 - (nr * w2);
}
item.m._height = dy;
item.m._x = dx;
item.m._y = hrect - dy;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._x = (i - 1) * w2;
item._y = h - hrect;
i++;
}
w2 = w2 + dx;
}
var item = _global.newchunk(itemp, aimg, level, aback, atitlecolor);
level++;
item.m._width = dx;
item.m._height = dy1;
item.m._x = wrect - dx;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._x = w - wrect;
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
item.m._width = dx;
item.m._height = dy;
item.m._x = wrect - dx;
item.m._y = hrect - dy;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._x = w - wrect;
item._y = h - hrect;
h1 = (h - dy) - dy1;
h2 = (hrect - dy) - dy1;
if (h <= hrect) {
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
item.m._width = dx;
item.m._height = h1;
item.m._y = dy1;
item.m.swapDepths(11);
item.b.setMask(item.m);
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
item.m._width = dx;
item.m._height = h1;
item.m._y = dy1;
item.m._x = wrect - dx;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._x = w - wrect;
} else {
nr = Math.floor(h1 / h2);
i = 1;
while (i <= (nr + 1)) {
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
if (i <= nr) {
item.m._height = h2;
} else {
item.m._height = h1 - (nr * h2);
}
item.m._width = dx;
item.m._y = dy1;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._y = (i - 1) * h2;
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
if (i <= nr) {
item.m._height = h2;
} else {
item.m._height = h1 - (nr * h2);
}
item.m._width = dx;
item.m._x = wrect - dx;
item.m._y = dy1;
item.m.swapDepths(11);
item.b.setMask(item.m);
item._y = (i - 1) * h2;
item._x = w - wrect;
i++;
}
}
var item = _global.newchunk(itemp, aimg, level, aback);
level++;
var xx1;
var yy1;
item.m._width = dx;
item.m._height = dy;
xx1 = Math.floor((wrect - dx) / 2);
yy1 = Math.floor((hrect - dy) / 2);
item.m._x = xx1;
item.m._y = yy1;
item.m.swapDepths(11);
item.b.setMask(item.m);
if (w1 <= dx) {
item.m._width = w1;
item._x = (-xx1) + dx;
} else {
item._xscale = (100 * w1) / dx;
item._x = ((((100 - item._xscale) * xx1) / 100) - xx1) + dx;
}
if (h1 <= dy) {
item.m._height = h1;
item._y = (-yy1) + dy1;
} else {
item._yscale = (100 * (h1 + 1)) / dy;
item._y = (((((100 - item._yscale) * yy1) / 100) - yy1) + dy1) - 1;
}
itemp._visible = false;
aitem.mcback.maxlevel = level;
};
_global.StartSound = function (asound) {
if (_global.design.daudio == false) {
return(undefined);
}
if (_global.audioon == true) {
if (asound == "sover") {
return(undefined);
}
var _local2 = new Sound();
_local2.attachSound(asound);
_local2.start(0, 1);
}
};
mccortina._visible = true;
_global.width = 770;
_global.height = 550;
_global.toc_width = 200;
_global.toc_height = 455;
_global.toct_height = 28;
_global.toc_y = 71;
_global.border = 5;
_global.toc_btnclosedy = _global.border + 15;
_global.toc_headerdy = 10;
_global.title_x = _global.border + 5;
_global.title_y = _global.border + 10;
_global.layoutup_dy = 10;
_global.qb = "box";
_global.info_dx = 10;
_global.intro_dx = 5;
_global.intro_dy = 5;
_global.binfo_dx = 13;
_global.bar_spacebtn = 7;
_global.scenario_dy = 5;
_global.question_dx1 = 5 + _global.border;
_global.question_dx2 = 5 + _global.border;
_global.question_dy = 5;
_global.buttons_dx = _global.border + 10;
_global.buttons_dy = _global.border + 13;
_global.bsubmitall_dx = 20;
_global.layoutdown_dy = 50;
_global.scroll_dy = 20;
_global.scroll_dx1 = 5 + _global.border;
_global.scroll_dx2 = 10 + _global.border;
_global.scroll_w = 700;
_global.scroll_h = 300;
_global.imgview_dx = 5;
_global.rb_dy = 5;
_global.rb_dx = 55;
_global.clred = 13369344 /* 0xCC0000 */;
_global.clgreen = 39168;
_global.clyellow = 16750848 /* 0xFF9900 */;
_global.cldisable = 6710886 /* 0x666666 */;
_global.emailbefore = "%22";
_global.emailafter = "%22,";
_global.emailfinish = "%22%0D%0A";
_global.crlf = "%0D%0A";
_global.emailbefore_1 = "%22";
_global.emailafter_1 = "%22,";
_global.emailfinish_1 = "%22%0D%0A";
_global.crlf_1 = "%0D%0A";
_global.emailbefore_2 = "\"";
_global.emailafter_2 = "\",";
_global.emailfinish_2 = "\"\n";
_global.crlf_2 = newline;
_global.response_separator = "[,]";
_global.response_separator_scorm12 = ",";
_global.response_separator_scorm2004 = "[,]";
_global.response_separator_script = ";";
_global.interaction_separator = "$$TQB$$";
_global.review = false;
_global.qreview = false;
_global.jump = "process";
_global.currentQuizItem;
_global.quizItems = new Array();
_global.currentQuestionNumber;
_global.starttime = 0;
_global.timeelapsed = 0;
_global.currentlabel = "load";
_global.quizid = "";
_global.title = "";
_global.introduction = "";
_global.showintroduction = false;
_global.quizimg = "n";
_global.qoptions = new TQOptions();
_global.finish = new TQFinish();
_global.design = new TQDesign();
_global.lang = new TQLanguage();
_global.userpoints = 0;
_global.userscore = 0;
_global.passedscore = 80;
_global.passedpoints = 0;
_global.totalpoints = 0;
_global.passed = false;
_global.paused = false;
_global.pausedtime = 0;
_global.my_xml = undefined;
_global.askuserid = false;
_global.askpassword = false;
_global.presetpassword = true;
_global.passwordvalue = new String();
_global.passwordurl = new String();
_global.passwordgetmethod = true;
_global.logged = false;
_global.userid = "";
_global.reporting = false;
_global.rep_enable = false;
_global.rep_level = 0;
_global.rep_method = 0;
_global.rep_scriptscoreurl = "";
_global.rep_scriptscoreget = true;
_global.rep_scriptintereactionurl = "";
_global.rep_scriptintereactionget = true;
_global.rep_emailtoemail = "";
_global.rep_emailqbphphost = true;
_global.rep_emailphpurl = "";
_global.scoversion = scoversion;
l1 = new LoadVars();
l2 = new LoadVars();
l3 = new LoadVars();
l4 = new LoadVars();
l5 = new LoadVars();
_global.audioon = true;
_global.nointeraction = 0;
_global.finished = false;
_global.qbegintime = 0;
intro._visible = false;
vtitle._visible = false;
Stage.scaleMode = "noScale";
y = "";
var myData = new XML();
myData.ignoreWhite = true;
myData.parseXML(varXML);
onQuizDataClass();
var x;
if ((_global.introduction != "") || (_global.quizimg == "y")) {
if (_global.showintroduction == true) {
x = "initial";
} else {
x = "start";
}
} else {
x = "start";
}
_global.StartSound("intro");
_global.ResizeTitle();
if ((_global.askuserid == true) || (_global.askpassword == true)) {
_global.logged = false;
this.gotoAndStop("login");
} else {
_global.logged = true;
this.gotoAndPlay(x);
}
Instance of Symbol 10036 MovieClip "qbinfo" in Frame 3
onClipEvent (load) {
_visible = false;
this.show = function () {
var _local1 = _global;
_x = 0;
_y = 0;
bb._width = _local1.width;
bb._height = _local1.height;
mcb._x = int((_local1.width - mcb._width) / 2);
mcb._y = int((_local1.height - mcb._height) / 2);
_visible = true;
};
onMouseMove = function () {
cursor._x = (_parent._xmouse + bb._x) - 10;
cursor._y = (_parent._ymouse + bb._y) - 10;
};
}
Instance of Symbol 95 MovieClip "mcfeed" in Frame 3
onClipEvent (load) {
feedbg.useHandCursor = false;
_visible = false;
var _useshowyn = false;
var _useretry = false;
var _btn = "btnfeedcontinue";
var _msg = "";
var _start;
var _wait = 10;
this._jump = false;
this.Show = function (amessage, abtntext, ajump) {
_jump = ajump;
_usesshowyn = false;
_useretry = false;
feedwin.tfeedtext = amessage;
_btn = abtntext;
_global.StartSound("message");
Resize();
_visible = true;
feedbg.gotoAndPlay(1);
};
this.Showyn = function (amessage) {
_useshowyn = true;
_useretry = false;
_msg = amessage;
_global.StartSound("message");
Resize();
_visible = true;
feedbg.gotoAndPlay(1);
};
this.Showynretry = function (amessage) {
_useshowyn = true;
_useretry = true;
_msg = amessage;
_start = getTimer();
_global.StartSound("message");
Resize();
_visible = true;
feedbg.gotoAndPlay(1);
};
this.SetButtonsText = function () {
var _local2;
if (_useretry == false) {
feedwin.byes.t.text = _global.GetText("btnfeedyes");
feedwin.bno.t.text = _global.GetText("btnfeedno");
} else {
_local2 = Math.round((getTimer() - _start) / 1000);
_local2 = _wait - _local2;
feedwin.byes.t.text = ((_global.GetText("btnfeedretry") + "(") + _local2) + ")";
feedwin.bno.t.text = _global.GetText("btnfeedignore");
}
_global.setbuttontextformat(feedwin.byes);
_global.setbuttontextformat(feedwin.bno);
};
this.Resize = function () {
this._x = 0;
this._y = 0;
feedwin._x = _global.width / 2;
feedwin._y = _global.height / 2;
feedbg._x = 0;
feedbg._y = 0;
feedbg._width = _global.width;
feedbg._height = _global.height;
if (_useshowyn == true) {
feedwin.tfeedtext = _global.GetText(_msg);
}
_global.settextformat(feedwin.tfeed, _global.design.mfont);
feedwin.byes._visible = _useshowyn;
feedwin.bno._visible = _useshowyn;
feedwin.bfeed._visible = !_useshowyn;
feedwin.bfeed.t.text = _global.GetText(_btn);
_global.setbuttontextformat(feedwin.bfeed);
this.SetButtonsText();
};
}
Instance of Symbol 125 MovieClip "enlarge" in Frame 3
onClipEvent (load) {
this._visible = false;
this.showimage = function (aimage) {
back._width = _global.width;
back._height = _global.height;
var _local3 = scrollimg.contentMain.attachMovie(aimage, "img", 10);
if ((_local3._width <= _global.width) && (_local3._height <= _global.height)) {
_local3._x = Math.floor((_global.width - _local3._width) / 2);
_local3._y = Math.floor((_global.height - _local3._height) / 2);
} else {
_local3._x = 0;
_local3._y = 0;
}
scrollimg.Resize();
this._visible = true;
};
}
Instance of Symbol 133 MovieClip "mctake" in Frame 3
onClipEvent (load) {
_visible = false;
var _starttime;
var _elapsedtime;
this.Resize = function () {
this._x = _global.question_dx1 - 2;
if (_parent.scenariol._visible == true) {
this._y = _parent.scenariol._y;
} else {
this._y = _parent.vquestion._y;
}
this.back._width = (_global.width - (2 * _global.question_dx1)) + 2;
this.back._height = _parent.layoutdown._y - this._y;
xx = new Color(this.back);
if (_global.design.qback.enable == true) {
xx.setRGB(_global.design.qback.fill);
} else {
xx.setRGB(_global.design.backcolor);
}
this.info._width = this.back._width - 20;
this.info._x = 10;
this.info._y = 10;
this.info.text = _global.GetText("infotake");
_global.settextformat(this.info, _global.design.takefont);
this.info.wordWrap = true;
this.info.autoSize = true;
this.bcont._x = _parent.bsubmit._x - this._x;
this.bcont._y = _parent.bsubmit._y - this._y;
this.bcont.t.text = _global.GetText("btncontinue");
_global.setbuttontextformat(bcont);
};
this.Show = function () {
_visible = true;
_global.paused = true;
_elapsedtime = 0;
_starttime = getTimer();
_global.ResizeTitle();
_parent.take._visible = false;
_parent.bsubmit._visible = false;
this.Resize();
timer.Start();
};
this.UnShow = function () {
delete timer.onEnterFrame;
_global.pausedtime = _global.pausedtime + _elapsedtime;
_visible = false;
_global.paused = false;
_parent.gotoAndPlay("process");
};
}
Frame 6
if ((_global.askuserid == false) && (_global.askpassword == false)) {
this.gotoAndPlay(x);
}
_global.currentlabel = "login";
_global.ResizeTitle();
passwordd.t.password = true;
if (_global.askuserid == true) {
Selection.setFocus(logind.t);
} else {
Selection.setFocus(passwordd.t);
}
mccortina._visible = false;
stop();
Frame 9
if (_global.logged == false) {
this.gotoAndStop("login");
} else if (x == "initial") {
intro.t.text = _global.introduction;
if (_global.quizimg == "y") {
var imgwidth = 200;
var imgheight = 250;
var iimg = quizimg.mcimg.attachMovie("quizimg", "img", 10);
if ((iimg._width > imgwidth) || (iimg._height > imgheight)) {
var xscale;
var yscale;
var scale;
xscale = (100 * imgwidth) / iimg._width;
yscale = (100 * imgheight) / iimg._height;
scale = xscale;
if (yscale < scale) {
scale = yscale;
}
iimg._xscale = scale;
iimg._yscale = scale;
quizimg.onPress = function () {
enlarge.showimage("quizimg");
};
}
}
intro._visible = true;
mccortina._visible = false;
_global.currentlabel = "intro";
_global.ResizeTitle();
stop();
} else {
gotoAndPlay ("start");
}
Instance of Symbol 170 MovieClip "mctable" in Frame 12
onClipEvent (load) {
this._minimize = true;
table._visible = false;
_items = 0;
_populate = false;
this.Resize = function () {
if (this._x == 0) {
if (_populate == false) {
this.Populate();
}
table.header.Resize();
table.scroll._y = _global.toct_height;
table.scroll.Resize();
table.bg.Resize();
}
};
this.Minimize = function () {
_minimize = !_minimize;
if (_minimize == true) {
table._visible = false;
_parent.splitter._visible = false;
_parent.splitter._x = -_parent.splitter._width;
this._x = -table._width;
} else {
this._x = 0;
this._y = (_global.title_y + _parent.title._height) + _global.layoutup_dy;
_global.toc_height = ((_global.height - _global.layoutdown_dy) - _parent.layoutdown._height) - this._y;
_parent.splitter._y = this._y;
_parent.splitter._height = _global.toc_height;
Resize();
table._visible = true;
_parent.splitter._x = _global.toc_width - _parent.splitter._width;
_parent.splitter._visible = true;
}
_global.ResizeTitle();
};
this.Populate = function () {
table.scroll.contentMain._visible = false;
table.scroll.contentMain.setMask(null);
table.scroll.contentMain.list.Populate();
table.scroll.Update();
table.scroll.contentMain.setMask(table.scroll.maskedView);
table.scroll.contentMain._visible = true;
_populate = true;
};
this.Update = function () {
table.scroll.contentMain._visible = false;
table.scroll.contentMain.setMask(null);
if (_populate == false) {
table.scroll.contentMain.list.Populate();
table.scroll.Update();
_populate = true;
}
table.scroll.contentMain.list.Update();
table.scroll.contentMain.setMask(table.scroll.maskedView);
table.scroll.contentMain._visible = true;
};
}
Instance of Symbol 171 MovieClip "splitter" in Frame 12
onClipEvent (load) {
_visible = false;
_dragged = false;
this.onPress = function () {
this.startDrag(false, Math.floor(_global.width / 4), this._y, Math.floor(_global.width / 2), this._y);
_dragged = true;
};
this.SetTocWidth = function () {
_global.toc_width = ((this._x - _global.border) + this._width) + 5;
};
this.onMouseMove = function () {
if (_dragged == true) {
_parent.cursor._x = _parent._xmouse;
_parent.cursor._y = _parent._ymouse;
SetTocWidth();
_parent.mctable.Resize();
_global.ResizeTitle();
}
};
this.onRelease = function () {
onRollOut();
this.stopDrag();
_dragged = false;
SetTocWidth();
_parent.mctable.Resize();
_global.ResizeTitle();
};
this.onReleaseOutside = this.onRelease;
this.onRollOver = function () {
_parent.cursor._visible = true;
Mouse.hide();
_parent.cursor._x = _parent._xmouse;
_parent.cursor._y = _parent._ymouse;
};
this.onRollOut = function () {
_parent.cursor._visible = false;
Mouse.show();
};
}
Instance of Symbol 174 MovieClip "cursor" in Frame 12
onClipEvent (load) {
_visible = false;
}
Frame 13
_global.currentQuestionNumber = 1;
_global.starttime = getTimer();
_global.currentlabel = "start";
_global.sessionid = ((_global.quizid + _global.userid) + new Date().getTime()) + random(10000000);
if (_global.design.dtoc == true) {
mctable.Populate();
btoc._visible = true;
} else {
btoc._visible = false;
}
vquestion._visible = true;
gotoAndPlay ("process");
Instance of Symbol 178 MovieClip "timer" in Frame 13
onClipEvent (load) {
if ((_global.finish.timelimited == false) || (_global.review == true)) {
this._visible = false;
delete this.onEnterFrame;
} else {
var totaltime;
this._visible = _global.finish.showtime;
totaltime = _global.finish.time;
this.onEnterFrame = function () {
var _local5;
if (_global.paused == true) {
return(undefined);
}
if (_global.finished == true) {
delete this.onEnterFrame;
return(undefined);
}
_local5 = (getTimer() - _global.starttime) - _global.pausedtime;
if (_local5 <= totaltime) {
_local5 = totaltime - _local5;
hhmmss.text = _global.FormatText(_global.GetText("timeremaining"), _global.FormatTime(_local5));
_global.settextformat(hhmmss, _global.design.timerfont);
hhmmss.wordWrap = false;
hhmmss.autoSize = true;
hhmmss.background = true;
hhmmss.backgroundColor = _global.design.timerfont.backcolor;
this._y = _parent.title._y;
this._x = ((_global.width - hhmmss._width) - _global.border) - 10;
} else {
_global.jump = "summary";
this._visible = false;
delete this.onEnterFrame;
var _local4;
_local4 = 0;
while (_local4 < _global.qoptions.nrquestions) {
if (_global.quizItems[_local4].IsAnswered() == true) {
_global.quizItems[_local4].completed = true;
}
_local4++;
}
_parent.mcfeed.Show(_global.GetText("msgtimer"), "btnfeedcontinue", true);
}
};
}
}
Instance of Symbol 189 MovieClip "take" in Frame 13
onClipEvent (load) {
_checked = false;
mccheck._visible = false;
mcuncheck._visible = true;
this.onRelease = function () {
_global.StartSound("sclick");
_checked = !_checked;
mccheck._visible = _checked;
mcuncheck._visible = !_checked;
};
this.onReleaseOutside = this.onRelease;
this.Uncheck = function () {
_checked = false;
mccheck._visible = _checked;
mcuncheck._visible = !_checked;
};
this.Resize = function () {
t._x = (mccheck._x + mccheck._width) + 2;
t._y = 2;
t.text = _global.GetText("checktake");
_global.settextformat(t, _global.design.takecfont);
t.wordWrap = false;
t.autoSize = true;
t._width = t.textWidth + 4;
t.autoSize = false;
mccheck._y = Math.floor((t._height - mccheck._height) / 2) + 2;
mcuncheck._y = mccheck._y;
bg._width = t._x + t._width;
bg._height = t._height;
var _local2 = new Color(bg);
if (_global.design.qback.enable == true) {
_local2.setRGB(_global.design.qback.fill);
} else {
_local2.setRGB(_global.design.backcolor);
}
};
}
Frame 16
_global.currentlabel = "process";
if (_global.design.dtoc == true) {
mctable.Populate();
}
_global.setbuttons();
vquestion._visible = true;
mccortina._visible = false;
gotoAndStop ("q");
Instance of Symbol 282 MovieClip "scroll" in Frame 19
onClipEvent (load) {
var contentHeight;
var contentWidth;
var maskWidth;
var maskHeight;
var initPositionV;
var initPositionH;
var finalContentPosV;
var finalContentPosH;
var bottom;
var right;
var dy;
var dx;
var speed;
var moveValV;
var moveValH;
Resize = function () {
maskedView._width = _global.scroll_w;
maskedView._height = _global.scroll_h;
contentMain.imgview._x = ((_global.scroll_w - VTrack._width) - contentMain.imgview._width) - _global.imgview_dx;
contentMain.Resize();
Update();
};
Update = function () {
hasV = true;
hasH = true;
if (contentMain._height <= (maskedView._height - corner._height)) {
hasV = false;
} else if (contentMain._height > maskedView._height) {
hasV = true;
} else if (contentMain._width <= (maskedView._width - corner._width)) {
hasV = false;
} else {
hasV = true;
}
if (contentMain._width <= (maskedView._width - corner._width)) {
hasH = false;
} else if (contentMain._width > maskedView._width) {
hasH = true;
} else if (hasV == true) {
hasH = false;
} else {
hasH = false;
}
if (hasH) {
maskHeight = maskedView._height - corner._height;
} else {
maskHeight = maskedView._height;
}
if (hasV) {
maskWidth = maskedView._width - corner._width;
} else {
maskWidth = maskedView._width;
}
contentHeight = contentMain._height;
contentWidth = contentMain._width;
VFace._visible = hasV;
VTrack._visible = hasV;
VUp._visible = hasV;
VDown._visible = hasV;
VUp.enabled = hasV;
VDown.enabled = hasV;
if (hasV == true) {
VUp._x = maskWidth;
VUp._y = 0;
VTrack._x = VUp._x;
VTrack._y = VUp._y + VUp._height;
VTrack._height = (maskHeight - VUp._height) - VDown._height;
VFace._x = VTrack._x;
VFace._y = VTrack._y;
VDown._x = VTrack._x;
VDown._y = VTrack._y + VTrack._height;
VFace.back._height = VTrack._height * (maskHeight / contentHeight);
VFace.ef._y = (VFace.back._height - VFace.ef._height) / 2;
if (VFace.back._height <= VFace.ef._height) {
VFace.ef._visible = false;
} else {
VFace.ef._visible = true;
}
VFace.ef._visible = false;
}
HFace._visible = hasH;
HTrack._visible = hasH;
HLeft._visible = hasH;
HRight._visible = hasH;
HLeft.enabled = hasH;
Hright.enabled = hasH;
if (hasH == true) {
HLeft._x = 0;
HLeft._y = maskHeight;
HTrack._y = HLeft._y;
HTrack._x = HLeft._x + HLeft._width;
HTrack._width = (maskWidth - HLeft._width) - HRight._width;
HFace._x = HTrack._x;
HFace._y = HTrack._y;
HRight._y = HTrack._y;
HRight._x = HTrack._x + HTrack._width;
HFace._width = HTrack._width * (maskWidth / contentWidth);
}
if (hasV && (hasH)) {
corner._visible = true;
corner._x = maskWidth;
corner._y = maskHeight;
} else {
corner._visible = false;
}
initPositionV = (VFace._y = VTrack._y);
finalContentPosV = maskHeight - contentHeight;
bottom = (VTrack._height - VFace._height) + VTrack._y;
dy = 0;
speed = 10;
moveValV = (contentHeight - maskHeight) / (VTrack._height - VFace._height);
initPositionH = (HFace._x = HTrack._x);
finalContentPosH = maskWidth - contentWidth;
right = (HTrack._width - HFace._width) + HTrack._x;
dx = 0;
moveValH = (contentWidth - maskWidth) / (HTrack._width - HFace._width);
};
VFace.onPress = function () {
startDrag (this, false, VTrack._x, VTrack._y, VTrack._x, bottom);
this.onMouseMove = function () {
dy = Math.abs(initPositionV - this._y);
contentMain._y = Math.round((dy * -1) * moveValV);
};
};
VFace.onMouseUp = function () {
stopDrag();
delete this.onMouseMove;
};
HFace.onPress = function () {
startDrag (this, false, HTrack._x, HTrack._y, right, HTrack._y);
this.onMouseMove = function () {
dx = Math.abs(initPositionH - this._x);
contentMain._x = Math.round((dx * -1) * moveValH);
};
};
HFace.onMouseUp = function () {
stopDrag();
delete this.onMouseMove;
};
VUp.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._y + speed) < maskedView._y) {
if (VFace._y <= VTrack._y) {
VFace._y = VTrack._y;
} else {
VFace._y = VFace._y - (speed / moveValV);
}
contentMain._y = contentMain._y + speed;
} else {
VFace._y = VTrack._y;
contentMain._y = maskedView._y;
delete this.onEnterFrame;
}
};
};
VUp.onDragOut = function () {
delete this.onEnterFrame;
};
VUp.onRelease = function () {
delete this.onEnterFrame;
};
HLeft.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._x + speed) < maskedView._x) {
if (HFace._x <= HTrack._x) {
HFace._x = HTrack._x;
} else {
HFace._x = HFace._x - (speed / moveValH);
}
contentMain._x = contentMain._x + speed;
} else {
HFace._x = HTrack._x;
contentMain._x = maskedView._x;
delete this.onEnterFrame;
}
};
};
HLeft.onDragOut = function () {
delete this.onEnterFrame;
};
HLeft.onRelease = function () {
delete this.onEnterFrame;
};
VDown.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._y - speed) > finalContentPosV) {
if (VFace._y >= bottom) {
VFace._y = bottom;
} else {
VFace._y = VFace._y + (speed / moveValV);
}
contentMain._y = contentMain._y - speed;
} else {
VFace._y = bottom;
contentMain._y = finalContentPosV;
delete this.onEnterFrame;
}
};
};
VDown.onRelease = function () {
delete this.onEnterFrame;
};
VDown.onDragOut = function () {
delete this.onEnterFrame;
};
HRight.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._x - speed) > finalContentPosH) {
if (HFace._x >= right) {
HFace._x = right;
} else {
HFace._x = HFace._x + (speed / moveValH);
}
contentMain._x = contentMain._x - speed;
} else {
HFace._x = right;
contentMain._x = finalContentPosH;
delete this.onEnterFrame;
}
};
};
HRight.onRelease = function () {
delete this.onEnterFrame;
};
HRight.onDragOut = function () {
delete this.onEnterFrame;
};
Update();
}
Frame 20
_global.currentlabel = "q";
if (_global.currentQuestionNumber > _global.qoptions.nrquestions) {
var i;
var all;
if (_global.qoptions.submitone == true) {
all = true;
i = 0;
while (i < _global.qoptions.nrquestions) {
if (_global.quizItems[i].IsAnswered() == false) {
_global.currentQuestionNumber = i + 1;
all = false;
break;
}
i++;
}
if (all == true) {
gotoAndStop ("summary");
stop();
}
} else if (review == false) {
_global.currentQuestionNumber = 1;
} else {
gotoAndStop ("summary");
stop();
}
}
currentQuizItem = _global.quizItems[_global.currentQuestionNumber - 1];
if (currentQuizItem.scenario == "") {
scenariol._visible = false;
scenario._visible = false;
} else {
scenariol._visible = true;
scenario._visible = true;
scenario.t.text = currentQuizItem.scenario;
}
vquestiontext = currentQuizItem.question;
currentQuizItem.SetDateTime();
_global.qbegintime = getTimer();
scroll.contentMain._visible = false;
scroll.contentMain.setMask(null);
if (currentQuizItem.HasImage() == true) {
scroll.contentMain.imgview._xscale = 100;
scroll.contentMain.imgview._yscale = 100;
scroll.contentMain.imgview._img = currentQuizItem.img;
scroll.contentMain.imgview.loadimage();
} else {
scroll.contentMain.imgview._xscale = 0;
scroll.contentMain.imgview._yscale = 0;
scroll.contentMain.imgview._visible = false;
}
_global.ResizeTitle();
vimgw = 0;
vimgh = 0;
if (currentQuizItem.HasImage() == true) {
vimgw = scroll.contentMain.imgview._width;
vimgh = scroll.contentMain.imgview._height;
}
scroll.contentMain.rb._visible = false;
scroll.contentMain.cb._visible = false;
scroll.contentMain.odd._visible = false;
scroll.contentMain.wb._visible = false;
scroll.contentMain.mdd._visible = false;
scroll.contentMain.ed._visible = false;
scroll.contentMain.cz._visible = false;
if (currentQuizItem._type == "tf") {
scroll.contentMain.rb.AddItems(currentQuizItem, vimgw, vimgh);
}
if (currentQuizItem._type == "mc") {
scroll.contentMain.rb.AddItems(currentQuizItem, vimgw, vimgh);
}
if (currentQuizItem._type == "mr") {
scroll.contentMain.cb.AddItems(currentQuizItem, vimgw, vimgh);
}
if (currentQuizItem._type == "ed") {
scroll.contentMain.ed.AddItem(currentQuizItem, vimgw, vimgh);
}
if (currentQuizItem._type == "wb") {
scroll.contentMain.wb.AddItems(currentQuizItem, vimgw, vimgh);
}
if (currentQuizItem._type == "mdd") {
scroll.contentMain.mdd.AddItems(currentQuizItem, vimgw, vimgh);
}
if (currentQuizItem._type == "cz") {
scroll.contentMain.cz.loadimg(currentQuizItem);
}
if (currentQuizItem._type == "odd") {
scroll.contentMain.odd.AddItems(currentQuizItem, vimgw, vimgh);
}
scroll.Update();
scroll.contentMain.setMask(scroll.maskedView);
scroll.contentMain._visible = true;
_global.ResizeTitle();
stop();
Instance of Symbol 319 MovieClip "mcprint" in Frame 25
onClipEvent (load) {
var pw;
var ph;
var dx;
var dy;
_visible = false;
pw = 575;
ph = 818;
dx = 10;
dy = 10;
this.Print = function () {
var _local2 = new PrintJob();
var _local3 = _local2.start();
if (_local3) {
ph = _local2.pageHeight - 1;
pw = _local2.pageWidth - 1;
this._x = 0;
this._visible = true;
this.header.Print(_local2, pw, ph, dx, dy);
}
this._visible = false;
};
}
Frame 26
_global.currentlabel = "summary";
if (_global.review == false) {
_global.StartSound("finish");
_global.timeelapsed = (getTimer() - _global.starttime) - _global.pausedtime;
_global.ComputeUserScore();
ReportScore();
}
_global.review = true;
bsubmit._visible = false;
bsubmitall._visible = false;
brevnext._visible = false;
brevprev._visible = false;
_global.finished = true;
vquestion._visible = false;
scenariol._visible = false;
scenario._visible = false;
_global.ResizeTitle();
stop();
Symbol 10009 MovieClip Frame 1
function preload() {
var _local1 = _parent;
if (doneLoading == 0) {
total = _local1._parent.getBytesTotal();
isloaded = _local1._parent.getBytesLoaded();
percent = 100 * (isloaded / total);
bytes = ((int(isloaded / 1024) add " KB of ") add int(total / 1024)) add " KB";
percentPrint = int(percent) add "% LOADED";
bar._width = (percent / 100) * bk._width;
if (percent > 99.5) {
_local1._parent.gotoAndPlay(2);
gotoAndStop ("off");
doneLoading = 1;
}
}
}
_parent._parent.gotoAndStop(1);
doneLoading = 0;
stop();
Instance of Symbol 10003 MovieClip "bk" in Symbol 10009 MovieClip Frame 1
onClipEvent (enterFrame) {
_parent.preload();
}
Symbol 10001 MovieClip Frame 1
pr._width = (_parent.pjw * 2) / 3;
pr._x = (_parent.pjw - pr._width) / 2;
pr._y = (_parent.pjh - pr._height) / 2;
Instance of Symbol 10009 MovieClip "pr" in Symbol 10001 MovieClip Frame 1
onClipEvent (load) {
}
Symbol 10011 Button
on (rollOver) {
Mouse.hide();
cursor._visible = true;
}
on (rollOut) {
Mouse.show();
cursor._visible = false;
}
Symbol 10015 MovieClip Frame 17
stop();
Symbol 10016 Button
on (release) {
getURL ("http://www.quiz-builder.com", "_blank");
}
Symbol 10019 Button
on (release) {
getURL ("http://www.demo-builder.com", "_blank");
}
Symbol 10024 Button
on (rollOver) {
emailtxt = "<P ALIGN=\"LEFT\"><FONT FACE=\"Tahoma\" SIZE=\"12\" COLOR=\"#003497\"><U>";
emailtxt = (emailtxt + _parent._parent.email) + "</U></FONT></P>";
}
on (rollOut) {
emailtxt = "<P ALIGN=\"LEFT\"><FONT FACE=\"Tahoma\" SIZE=\"12\" COLOR=\"#000000\">";
emailtxt = (emailtxt + _parent._parent.email) + "</FONT></P>";
}
on (release, releaseOutside) {
getURL ("mailto:" + _parent._parent.email, "_self");
}
Symbol 10026 Button
on (rollOver) {
webtxt = "<P ALIGN=\"LEFT\"><FONT FACE=\"Tahoma\" SIZE=\"12\" COLOR=\"#003497\"><U>";
webtxt = (webtxt + _parent._parent.website) + "</U></FONT></P>";
}
on (rollOut) {
webtxt = "<P ALIGN=\"LEFT\"><FONT FACE=\"Tahoma\" SIZE=\"12\" COLOR=\"#000000\">";
webtxt = (webtxt + _parent._parent.website) + "</FONT></P>";
}
on (release, releaseOutside) {
getURL (_parent._parent.website, "_blank");
}
Symbol 10031 Button
on (release, releaseOutside) {
_parent._visible = false;
}
Instance of Symbol 10033 MovieClip "mcb" in Symbol 10036 MovieClip Frame 1
onClipEvent (load) {
this.useHandCursor = false;
b1.useHandCursor = false;
emailtxt = "<P ALIGN=\"LEFT\"><FONT FACE=\"Tahoma\" SIZE=\"12\" COLOR=\"#000000\">";
emailtxt = (emailtxt + _parent._parent.email) + "</FONT></P>";
webtxt = "<P ALIGN=\"LEFT\"><FONT FACE=\"Tahoma\" SIZE=\"12\" COLOR=\"#000000\">";
webtxt = (webtxt + _parent._parent.website) + "</FONT></P>";
}
Instance of Symbol 10035 MovieClip "cursor" in Symbol 10036 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
}
Symbol 38 MovieClip Frame 1
var item = _parent._parent.t;
if (item != undefined) {
item._x = item._x + 1;
item._y = item._y + 1;
}
Symbol 39 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
t._x = t._x - 1;
t._y = t._y - 1;
if (_global.currentlabel == "login") {
if (_global.askuserid == true) {
if (_parent.logind.t.text == "") {
_parent.mcfeed.Show(_global.GetText("userid"), "btnfeedcontinue", false);
Selection.setFocus(_parent.logind.t);
return(undefined);
}
}
if (_global.askpassword == true) {
if (_global.presetpassword == true) {
if (String(_parent.passwordd.t.text).toLowerCase() != String(_global.passwordvalue).toLowerCase()) {
_parent.mcfeed.Show(_global.GetText("password"), "btnfeedcontinue", false);
Selection.setFocus(_parent.passwordd.t);
return(undefined);
}
_global.logged = true;
_global.userid = _parent.logind.t.text;
_parent.gotoAndPlay(_parent.x);
} else {
var l1 = new LoadVars();
var l2 = new LoadVars();
l1.timestamp = new Date().getTime();
l1.password = _parent.passwordd.t.text;
if (_global.askuserid == true) {
l1.userid = _parent.logind.t.text;
}
l1.quizid = _global.quizid;
l2.onLoad = function (success) {
if (success == true) {
if (String(l2.valid).toLowerCase() != "true") {
_parent.mcfeed.Show(_global.GetText("password"), "btnfeedcontinue", false);
Selection.setFocus(_parent.passwordd.t);
return(undefined);
}
_global.logged = true;
_global.userid = _parent.logind.t.text;
_parent.gotoAndPlay(_parent.x);
} else {
_parent.mcfeed.Show(_global.GetText("connectionfaillogin"), "btnfeedcontinue", false);
Selection.setFocus(_parent.passwordd.t);
return(undefined);
}
};
var v1;
v1 = "POST";
if (_global.getmethod == true) {
v1 = "GET";
}
l1.sendAndLoad(_global.passwordurl, l2, v1);
}
} else {
_global.logged = true;
_global.userid = _parent.logind.t.text;
_parent.gotoAndPlay(_parent.x);
}
} else {
_parent.gotoAndPlay("start");
}
}
Symbol 58 MovieClip Frame 30
gotoAndPlay (10);
Symbol 59 MovieClip Frame 30
gotoAndPlay (10);
Symbol 61 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
qbinfo.show();
}
Symbol 70 MovieClip Frame 30
gotoAndPlay (10);
Symbol 71 MovieClip Frame 30
gotoAndPlay (10);
Symbol 72 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
_global.audioon = false;
bsoundon._visible = false;
bsoundoff._visible = true;
}
Symbol 75 MovieClip Frame 30
gotoAndPlay (10);
Symbol 76 MovieClip Frame 30
gotoAndPlay (10);
Symbol 77 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
_global.audioon = true;
bsoundoff._visible = false;
bsoundon._visible = true;
}
Symbol 80 MovieClip Frame 20
stop();
Symbol 85 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
_parent._parent._visible = false;
if (_parent._parent._jump == false) {
return(undefined);
}
if (_parent._parent._parent.take._checked == true) {
_parent._parent._parent.mctake.Show();
} else {
_parent._parent._parent.gotoAndPlay(_global.jump);
}
}
Symbol 88 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
_parent._parent._visible = false;
return(undefined);
}
Symbol 91 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
_parent._parent._visible = false;
if (_parent._parent._useretry == false) {
var i;
i = 0;
while (i < _global.qoptions.nrquestions) {
if (_global.quizItems[i].IsAnswered() == true) {
_parent._parent._parent.ReportInteraction(i);
_global.quizItems[i].completed = true;
}
i++;
}
_parent._parent._parent.gotoAndPlay("summary");
} else {
_global.SendXML();
}
}
Instance of Symbol 93 MovieClip "byes" in Symbol 94 MovieClip Frame 1
onClipEvent (enterFrame) {
var _dif;
if (_parent._parent._useretry == true) {
if (_parent._parent._visible == true) {
_dif = Math.round((getTimer() - _parent._parent._start) / 1000);
if (_dif < _parent._parent._wait) {
_parent._parent.SetButtonsText();
} else {
_parent._parent._visible = false;
_global.SendXML();
}
}
}
}
Instance of Symbol 80 MovieClip "feedbg" in Symbol 95 MovieClip Frame 1
onClipEvent (load) {
this.onRollOver = function () {
};
}
Symbol 124 MovieClip Frame 1
maskedView._x = 0;
maskedView._y = 0;
Instance of Symbol 98 MovieClip "maskedView" in Symbol 124 MovieClip Frame 1
onClipEvent (load) {
this.useHandCursor = false;
}
onClipEvent (enterFrame) {
if (_global.review == true) {
if (this.onRollOver == undefined) {
this.onRollOver = function () {
};
}
} else if (this.onRollOver != undefined) {
delete this.onRollOver;
}
}
Instance of Symbol 99 MovieClip "contentMain" in Symbol 124 MovieClip Frame 1
onClipEvent (load) {
onPress = function () {
_parent._parent._visible = false;
};
}
Instance of Symbol 114 MovieClip "VUp" in Symbol 124 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 115 MovieClip "VDown" in Symbol 124 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 120 MovieClip "HLeft" in Symbol 124 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 123 MovieClip "HRight" in Symbol 124 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 96 MovieClip "back" in Symbol 125 MovieClip Frame 1
onClipEvent (load) {
this.useHandCursor = false;
this.onRollOver = function () {
};
this.onRollOut = function () {
};
}
Instance of Symbol 124 MovieClip "scrollimg" in Symbol 125 MovieClip Frame 1
onClipEvent (load) {
var contentHeight;
var contentWidth;
var maskWidth;
var maskHeight;
var initPositionV;
var initPositionH;
var finalContentPosV;
var finalContentPosH;
var bottom;
var right;
var dy;
var dx;
var speed;
var moveValV;
var moveValH;
Resize = function () {
maskedView._width = _global.width;
maskedView._height = _global.height;
contentMain.Resize();
Update();
};
Update = function () {
hasV = true;
hasH = true;
if (contentMain._height <= (maskedView._height - corner._height)) {
hasV = false;
} else if (contentMain._height > maskedView._height) {
hasV = true;
} else if (contentMain._width <= (maskedView._width - corner._width)) {
hasV = false;
} else {
hasV = true;
}
if (contentMain._width <= (maskedView._width - corner._width)) {
hasH = false;
} else if (contentMain._width > maskedView._width) {
hasH = true;
} else if (hasV == true) {
hasH = false;
} else {
hasH = false;
}
if (hasH) {
maskHeight = maskedView._height - corner._height;
} else {
maskHeight = maskedView._height;
}
if (hasV) {
maskWidth = maskedView._width - corner._width;
} else {
maskWidth = maskedView._width;
}
contentHeight = contentMain._height;
contentWidth = contentMain._width;
VFace._visible = hasV;
VTrack._visible = hasV;
VUp._visible = hasV;
VDown._visible = hasV;
VUp.enabled = hasV;
VDown.enabled = hasV;
if (hasV == true) {
VUp._x = maskWidth;
VUp._y = 0;
VTrack._x = VUp._x;
VTrack._y = VUp._y + VUp._height;
VTrack._height = (maskHeight - VUp._height) - VDown._height;
VFace._x = VTrack._x;
VFace._y = VTrack._y;
VDown._x = VTrack._x;
VDown._y = VTrack._y + VTrack._height;
VFace.back._height = VTrack._height * (maskHeight / contentHeight);
VFace.ef._y = (VFace.back._height - VFace.ef._height) / 2;
if (VFace.back._height <= VFace.ef._height) {
VFace.ef._visible = false;
} else {
VFace.ef._visible = true;
}
VFace.ef._visible = false;
}
HFace._visible = hasH;
HTrack._visible = hasH;
HLeft._visible = hasH;
HRight._visible = hasH;
HLeft.enabled = hasH;
Hright.enabled = hasH;
if (hasH == true) {
HLeft._x = 0;
HLeft._y = maskHeight;
HTrack._y = HLeft._y;
HTrack._x = HLeft._x + HLeft._width;
HTrack._width = (maskWidth - HLeft._width) - HRight._width;
HFace._x = HTrack._x;
HFace._y = HTrack._y;
HRight._y = HTrack._y;
HRight._x = HTrack._x + HTrack._width;
HFace._width = HTrack._width * (maskWidth / contentWidth);
}
if (hasV && (hasH)) {
corner._visible = true;
corner._x = maskWidth;
corner._y = maskHeight;
} else {
corner._visible = false;
}
initPositionV = (VFace._y = VTrack._y);
finalContentPosV = maskHeight - contentHeight;
bottom = (VTrack._height - VFace._height) + VTrack._y;
dy = 0;
speed = 10;
moveValV = (contentHeight - maskHeight) / (VTrack._height - VFace._height);
initPositionH = (HFace._x = HTrack._x);
finalContentPosH = maskWidth - contentWidth;
right = (HTrack._width - HFace._width) + HTrack._x;
dx = 0;
moveValH = (contentWidth - maskWidth) / (HTrack._width - HFace._width);
};
VFace.onPress = function () {
startDrag (this, false, VTrack._x, VTrack._y, VTrack._x, bottom);
this.onMouseMove = function () {
dy = Math.abs(initPositionV - this._y);
contentMain._y = Math.round((dy * -1) * moveValV);
};
};
VFace.onMouseUp = function () {
stopDrag();
delete this.onMouseMove;
};
HFace.onPress = function () {
startDrag (this, false, HTrack._x, HTrack._y, right, HTrack._y);
this.onMouseMove = function () {
dx = Math.abs(initPositionH - this._x);
contentMain._x = Math.round((dx * -1) * moveValH);
};
};
HFace.onMouseUp = function () {
stopDrag();
delete this.onMouseMove;
};
VUp.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._y + speed) < maskedView._y) {
if (VFace._y <= VTrack._y) {
VFace._y = VTrack._y;
} else {
VFace._y = VFace._y - (speed / moveValV);
}
contentMain._y = contentMain._y + speed;
} else {
VFace._y = VTrack._y;
contentMain._y = maskedView._y;
delete this.onEnterFrame;
}
};
};
VUp.onDragOut = function () {
delete this.onEnterFrame;
};
VUp.onRelease = function () {
delete this.onEnterFrame;
};
HLeft.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._x + speed) < maskedView._x) {
if (HFace._x <= HTrack._x) {
HFace._x = HTrack._x;
} else {
HFace._x = HFace._x - (speed / moveValH);
}
contentMain._x = contentMain._x + speed;
} else {
HFace._x = HTrack._x;
contentMain._x = maskedView._x;
delete this.onEnterFrame;
}
};
};
HLeft.onDragOut = function () {
delete this.onEnterFrame;
};
HLeft.onRelease = function () {
delete this.onEnterFrame;
};
VDown.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._y - speed) > finalContentPosV) {
if (VFace._y >= bottom) {
VFace._y = bottom;
} else {
VFace._y = VFace._y + (speed / moveValV);
}
contentMain._y = contentMain._y - speed;
} else {
VFace._y = bottom;
contentMain._y = finalContentPosV;
delete this.onEnterFrame;
}
};
};
VDown.onRelease = function () {
delete this.onEnterFrame;
};
VDown.onDragOut = function () {
delete this.onEnterFrame;
};
HRight.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._x - speed) > finalContentPosH) {
if (HFace._x >= right) {
HFace._x = right;
} else {
HFace._x = HFace._x + (speed / moveValH);
}
contentMain._x = contentMain._x - speed;
} else {
HFace._x = right;
contentMain._x = finalContentPosH;
delete this.onEnterFrame;
}
};
};
HRight.onRelease = function () {
delete this.onEnterFrame;
};
HRight.onDragOut = function () {
delete this.onEnterFrame;
};
Update();
}
Symbol 130 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
_parent.UnShow();
}
Instance of Symbol 126 MovieClip "back" in Symbol 133 MovieClip Frame 1
onClipEvent (load) {
this.useHandCursor = false;
this.onRollOver = function () {
};
}
Instance of Symbol 128 MovieClip "timer" in Symbol 133 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
_totaltime = 900;
this.Start = function () {
_visible = true;
this.onEnterFrame = function () {
var _local3;
var _local4;
var _local5;
_local3 = getTimer() - _parent._starttime;
_parent._elapsedtime = _local3;
_local3 = Math.floor(_local3 / 1000);
_local3 = _totaltime - _local3;
t.text = _local3;
if (_local3 <= 0) {
_parent.UnShow();
return(undefined);
}
_local4 = Math.floor(_local3 / 60);
_local5 = _local3 - (_local4 * 60);
t.text = "";
if (_local5 < 10) {
t.text = "0";
}
t.text = t.text + _local5;
t.text = (_local4 + ":") + t.text;
if (_local4 < 10) {
t.text = "0" + t.text;
}
t.text = _global.FormatText(_global.GetText("remainingtake"), t.text);
_global.settextformat(t, _global.design.takefont);
t._width = _parent.back._width - 20;
t.wordWrap = true;
t.autoSize = true;
t._y = (_parent.info._y + _parent.info._height) + 10;
t._x = Math.floor((_parent.back._width - t.textWidth) / 2);
};
};
}
Symbol 134 MovieClip Frame 1
stop();
Symbol 134 MovieClip Frame 7
var mData = new XML();
mData.ignoreWhite = true;
mData.onLoad = function (success) {
_global.design.LoadFromXML(mData.firstChild.firstChild);
if (_global.design.dtoc == false) {
if (_parent.mctable._minimize == false) {
_parent.mctable.Minimize();
}
} else {
_parent.mctable.Resize();
_parent.mctable.Resize();
}
_global.ResizeTitle();
};
mData.load("design.xml");
gotoAndStop ("stop");
Symbol 134 MovieClip Frame 13
var mData = new XML();
mData.ignoreWhite = true;
mData.onLoad = function (success) {
_global.lang.LoadFromXML(mData.firstChild.firstChild);
_global.ResizeTitle();
};
mData.load("captions.xml");
gotoAndStop ("stop");
Symbol 376 MovieClip [__Packages.TQBase] Frame 0
class TQBase
{
var _type, question, shuffle, img, answers, feedback, feedbackok, feedbackwrong, attempts, maxattempts, points, completed, imginclude, scenario, date, interactionid, latency;
function TQBase (atype) {
_type = atype;
question = "";
shuffle = "";
img = "";
answers = new Array();
feedback = false;
feedbackok = "";
feedbackwrong = "";
attempts = 0;
maxattempts = 1;
points = 0;
completed = false;
imginclude = false;
scenario = "";
date = 0;
interactionid = "I1000";
latency = 0;
}
function AddScenario(ANode) {
if (ANode.attributes.scinclude == "1") {
scenario = _global.RemoveCR(String(ANode.childNodes[0]));
} else {
scenario = "";
}
}
function AddQuestion(ANode) {
question = _global.RemoveCR(String(ANode.childNodes[0]));
shuffle = ANode.attributes.shuffle;
interactionid = ANode.attributes.interactionid;
imginclude = Boolean(ANode.attributes.imginclude);
img = ANode.attributes.img;
if (ANode.attributes.feedback == "y") {
feedback = true;
feedbackok = ANode.attributes.feedbackok;
feedbackwrong = ANode.attributes.feedbackwrong;
maxattempts = ANode.attributes.attempts;
} else {
feedback = false;
}
points = Number(ANode.attributes.points);
}
function AddAnswer(ANode) {
var _local3 = new Array();
_local3[0] = _global.RemoveCR(ANode.childNodes[0]);
if (ANode.attributes.correct == "y") {
_local3[1] = true;
} else {
_local3[1] = false;
}
_local3[2] = false;
_local3[3] = answers.length;
answers.push(_local3);
}
function AnswersNumber() {
return(answers.length);
}
function GetAnswer(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex][0]);
}
return("");
}
function GetCorrect(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex][1]);
}
return(false);
}
function SetResponse(AIndex, AResponse) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
answers[AIndex][2] = AResponse;
}
}
function GetResponse(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex][2]);
}
return(false);
}
function UserResponse() {
var _local2;
var _local3 = answers.length;
if (_local3 <= 0) {
return(false);
}
_local2 = 0;
while (_local2 < _local3) {
if (answers[_local2][1] != answers[_local2][2]) {
return(false);
}
_local2++;
}
return(true);
}
function GetResponseAsString() {
var _local4;
_local4 = "";
var _local3;
var _local5 = answers.length;
if (_local5 <= 0) {
} else {
_local3 = 0;
while (_local3 < _local5) {
if (answers[_local3][2] == true) {
_local4 = _local4 + answers[_local3][0];
if (_local3 < (_local5 - 1)) {
_local4 = _local4 + _global.response_separator;
}
}
_local3++;
}
}
return(_local4);
}
function GetResponseAsStringLMS() {
var _local3;
_local3 = "";
var _local4;
var _local5 = answers.length;
if (_type == "tf") {
if (_local5 < 2) {
_local3 = "t";
} else if (answers[0][2] == true) {
_local3 = "t";
} else {
_local3 = "f";
}
return(_local3);
}
if (_local5 <= 0) {
} else {
_local4 = 0;
while (_local4 < _local5) {
if (answers[_local4][2] == true) {
if (length(_local3) > 0) {
_local3 = _local3 + _global.response_separator;
}
_local3 = _local3 + chr(97 + answers[_local4][3]);
}
_local4++;
}
}
return(_local3);
}
function GetCorrectResponseAsString() {
var _local4;
_local4 = "";
var _local3;
var _local5 = answers.length;
if (_local5 <= 0) {
} else {
_local3 = 0;
while (_local3 < _local5) {
if (answers[_local3][1] == true) {
_local4 = _local4 + answers[_local3][0];
if (_local3 < (_local5 - 1)) {
_local4 = _local4 + _global.response_separator;
}
}
_local3++;
}
}
return(_local4);
}
function GetCorrectResponseAsStringLMS() {
var _local3;
_local3 = "";
var _local4;
var _local5 = answers.length;
if (_type == "tf") {
if (_local5 < 2) {
_local3 = "t";
} else if (answers[0][1] == true) {
_local3 = "t";
} else {
_local3 = "f";
}
return(_local3);
}
if (_local5 <= 0) {
} else {
_local4 = 0;
while (_local4 < _local5) {
if (answers[_local4][1] == true) {
if (length(_local3) > 0) {
_local3 = _local3 + _global.response_separator;
}
_local3 = _local3 + chr(97 + answers[_local4][3]);
}
_local4++;
}
}
return(_local3);
}
function IsAnswered() {
var _local2;
var _local3 = answers.length;
if (_local3 <= 0) {
return(true);
}
_local2 = 0;
while (_local2 < _local3) {
if (answers[_local2][2] == true) {
return(true);
}
_local2++;
}
return(false);
}
function ResultPoints() {
if (UserResponse() == true) {
return(Number(points));
}
return(Number(0));
}
function AddLatency(avalue) {
latency = latency + avalue;
}
function HasImage() {
if ((img == undefined) || (imginclude == false)) {
return(false);
}
return(true);
}
function Pad(avalue) {
if (length(avalue) == 1) {
return("0" + avalue);
}
return(avalue);
}
function SetDateTime() {
if (_global.review == false) {
if (date == 0) {
date = new Date();
}
}
}
function GetTypeAsString() {
switch (_type) {
case "tf" :
return("true-false");
case "mc" :
return("single-answer");
case "mr" :
return("multiple-answers");
case "ed" :
return("short-answer");
case "wb" :
return("wordbank");
case "mdd" :
return("matching");
case "cz" :
return("click-map");
case "odd" :
return("order");
}
return("");
}
function GetTypeAsStringLMS() {
switch (_type) {
case "tf" :
return("true-false");
case "mc" :
return("choice");
case "mr" :
return("choice");
case "ed" :
return("fill-in");
case "wb" :
return("choice");
case "mdd" :
return("matching");
case "cz" :
return("choice");
case "odd" :
return("sequencing");
}
return("");
}
function GetDateAsString() {
if (date == 0) {
return(date);
}
var _local2;
_local2 = (((Pad(date.getMonth() + 1) + "/") + Pad(date.getDate())) + "/") + date.getFullYear();
return(_local2);
}
function GetTimeAsString() {
if (date == 0) {
return(date);
}
var _local2;
_local2 = (((Pad(date.getHours()) + ":") + Pad(date.getMinutes())) + ":") + Pad(date.getSeconds());
return(_local2);
}
function GetLatency() {
return(_global.FormatTime(latency));
}
function EmailResult() {
var _local3;
_local3 = "";
_local3 = _local3 + _global.emailbefore;
if (date == 0) {
_local3 = (_local3 + date) + _global.emailafter;
_local3 = ((_local3 + _global.emailbefore) + date) + _global.emailafter;
} else {
_local3 = (_local3 + GetDateAsString()) + _global.emailafter;
_local3 = ((_local3 + _global.emailbefore) + GetTimeAsString()) + _global.emailafter;
}
_local3 = ((_local3 + _global.emailbefore) + interactionid) + _global.emailafter;
_local3 = ((_local3 + _global.emailbefore) + GetTypeAsString()) + _global.emailafter;
_local3 = ((_local3 + _global.emailbefore) + GetResponseAsString()) + _global.emailafter;
_local3 = _local3 + _global.emailbefore;
if (IsAnswered() == false) {
_local3 = _local3 + _global.GetText("reportiincomplete");
} else if (UserResponse() == true) {
_local3 = _local3 + _global.GetText("reporticorrect");
} else {
_local3 = _local3 + _global.GetText("reportiincorrect");
}
_local3 = _local3 + _global.emailafter;
_local3 = ((_local3 + _global.emailbefore) + ResultPoints()) + _global.emailafter;
_local3 = ((_local3 + _global.emailbefore) + "1") + _global.emailafter;
_local3 = ((_local3 + _global.emailbefore) + GetLatency()) + _global.emailfinish;
return(_local3);
}
function LoadFromXML(ANode) {
var _local2 = 0;
while (ANode.childNodes[_local2]) {
switch (ANode.childNodes[_local2].nodeName) {
case "scenario" :
AddScenario(ANode.childNodes[_local2]);
break;
case "question" :
AddQuestion(ANode.childNodes[_local2]);
break;
case "answer" :
AddAnswer(ANode.childNodes[_local2]);
}
_local2++;
}
if (shuffle.toLowerCase() == "y") {
answers.sort(function () {
return(random(5) - 1);
});
}
}
}
Symbol 377 MovieClip [__Packages.TQClickZone] Frame 0
class TQClickZone extends TQBase
{
var userx, usery, scale, scaled, imginclude, imgbg, img, left, top, right, bottom;
function TQClickZone (atype) {
super(atype);
userx = -1;
usery = -1;
scale = 1;
scaled = false;
}
function AddQuestion(ANode) {
super.AddQuestion(ANode);
imginclude = false;
imgbg = img;
}
function GetImagebg() {
return(imgbg);
}
function AddAnswer(ANode) {
left = Number(ANode.attributes.left);
top = Number(ANode.attributes.top);
right = Number(ANode.attributes.right);
bottom = Number(ANode.attributes.bottom);
if (ANode.attributes.scaled == "y") {
scaled = true;
} else {
scaled = false;
}
}
function SetResponse(Ax, Ay) {
userx = Ax;
usery = Ay;
}
function UserResponse() {
if ((userx >= (left * scale)) && (userx <= (right * scale))) {
if ((usery >= (top * scale)) && (usery <= (bottom * scale))) {
return(true);
}
return(false);
}
return(false);
}
function IsAnswered() {
if ((userx == -1) || (usery == -1)) {
return(false);
}
return(true);
}
function GetResponseAsString() {
var _local3;
_local3 = "";
_local3 = ((userx / scale) + _global.response_separator) + (usery / scale);
return(_local3);
}
function GetResponseAsStringLMS() {
var _local2;
if (UserResponse() == true) {
_local2 = "1";
} else {
_local2 = "0";
}
return(_local2);
}
function GetCorrectResponseAsString() {
var _local3;
_local3 = "";
_local3 = (_local3 + left) + _global.response_separator;
_local3 = (_local3 + top) + _global.response_separator;
_local3 = (_local3 + right) + _global.response_separator;
_local3 = (_local3 + bottom) + _global.response_separator;
return(_local3);
}
function GetCorrectResponseAsStringLMS() {
var _local1;
_local1 = "1";
return(_local1);
}
function XMLAddAnswers(my_xml, node_answers) {
var _local2 = my_xml.createElement("userresponse");
_local2.attributes.y = usery / scale;
_local2.attributes.x = userx / scale;
node_answers.parentNode.appendChild(_local2);
_local2 = my_xml.createElement("answer");
_local2.attributes.bottom = bottom;
_local2.attributes.right = right;
_local2.attributes.top = top;
_local2.attributes.left = left;
node_answers.appendChild(_local2);
return(true);
}
var answer = "";
}
Symbol 378 MovieClip [__Packages.TQOrderdd] Frame 0
class TQOrderdd extends TQBase
{
var _answered, answers, AnswersNumber, points, img;
function TQOrderdd (atype) {
super(atype);
_answered = true;
}
function AddAnswer(ANode) {
var _local3 = new Array();
_local3[0] = _global.RemoveCR(ANode.childNodes[0]);
_local3[1] = answers.length;
_local3[2] = -1;
answers.push(_local3);
}
function GetAnswer(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex][0]);
}
return("");
}
function GetUserOrder(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex][2]);
}
return(-1);
}
function GetCorrectOrder(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex][1]);
}
return(-1);
}
function GetIndexAtOrder(AOrder) {
if ((AOrder >= 0) && (AOrder < AnswersNumber())) {
var _local2;
_local2 = 0;
while (_local2 < answers.length) {
if (AOrder == answers[_local2][2]) {
return(_local2);
}
_local2++;
}
return(-1);
}
return(-1);
}
function GetResponseAsString() {
var _local5;
var _local3;
var _local4;
_local4 = "";
_local5 = 0;
while (_local5 < answers.length) {
_local3 = 0;
while (_local3 < answers.length) {
if (_local5 == answers[_local3][2]) {
_local4 = _local4 + answers[_local3][0];
if (_local5 < (answers.length - 1)) {
_local4 = _local4 + _global.response_separator;
}
break;
}
_local3++;
}
_local5++;
}
return(_local4);
}
function GetResponseAsStringLMS() {
var _local5;
var _local4;
var _local3;
_local3 = "";
_local5 = 0;
while (_local5 < answers.length) {
_local4 = 0;
while (_local4 < answers.length) {
if (_local5 == answers[_local4][2]) {
if (length(_local3) > 0) {
_local3 = _local3 + _global.response_separator;
}
_local3 = _local3 + chr(97 + answers[_local4][1]);
break;
}
_local4++;
}
_local5++;
}
return(_local3);
}
function GetCorrectResponseAsString() {
var _local5;
var _local3;
var _local4;
_local4 = "";
_local5 = 0;
while (_local5 < answers.length) {
_local3 = 0;
while (_local3 < answers.length) {
if (_local5 == answers[_local3][1]) {
_local4 = _local4 + answers[_local3][0];
if (_local5 < (answers.length - 1)) {
_local4 = _local4 + _global.response_separator;
}
break;
}
_local3++;
}
_local5++;
}
return(_local4);
}
function GetCorrectResponseAsStringLMS() {
var _local5;
var _local4;
var _local3;
_local3 = "";
_local5 = 0;
while (_local5 < answers.length) {
_local4 = 0;
while (_local4 < answers.length) {
if (_local5 == answers[_local4][1]) {
if (length(_local3) > 0) {
_local3 = _local3 + _global.response_separator;
}
_local3 = _local3 + chr(97 + answers[_local4][1]);
break;
}
_local4++;
}
_local5++;
}
return(_local3);
}
function ChangeOrder(oldorder, neworder) {
var _local2;
_answered = true;
if (oldorder == neworder) {
return(undefined);
}
if ((oldorder < 0) || (neworder < 0)) {
return(undefined);
}
if ((oldorder >= answers.length) || (neworder >= answers.length)) {
return(undefined);
}
var _local5;
if (neworder < oldorder) {
_local2 = 0;
while (_local2 < answers.length) {
if (answers[_local2][2] == oldorder) {
_local5 = _local2;
}
if ((answers[_local2][2] >= neworder) && (answers[_local2][2] < oldorder)) {
answers[_local2][2] = answers[_local2][2] + 1;
}
_local2++;
}
answers[_local5][2] = neworder;
} else {
_local2 = 0;
while (_local2 < answers.length) {
if (answers[_local2][2] == oldorder) {
_local5 = _local2;
}
if ((answers[_local2][2] > oldorder) && (answers[_local2][2] <= neworder)) {
answers[_local2][2] = answers[_local2][2] - 1;
}
_local2++;
}
answers[_local5][2] = neworder;
}
}
function UserResponse() {
var _local2;
var _local3 = answers.length;
if (_local3 <= 0) {
return(false);
}
_local2 = 0;
while (_local2 < _local3) {
if (answers[_local2][1] != answers[_local2][2]) {
return(false);
}
_local2++;
}
return(true);
}
function IsAnswered() {
return(_answered);
}
function ResultPoints() {
if (UserResponse() == true) {
return(Number(points));
}
return(Number(0));
}
function HasImage() {
if (img == undefined) {
return(false);
}
return(true);
}
function LoadFromXML(ANode) {
super.LoadFromXML(ANode);
answers.sort(function () {
return(random(3) - 1);
});
var _local3;
var _local4;
_local4 = answers.length;
_local3 = 0;
while (_local3 < _local4) {
answers[_local3][2] = _local3;
_local3++;
}
}
function XMLAddAnswers(my_xml, node_answers) {
var _local5;
var _local2;
_local5 = 0;
while (_local5 < answers.length) {
_local2 = 0;
while (_local2 < answers.length) {
if (_local5 == answers[_local2][2]) {
var _local3 = my_xml.createElement("answer");
var _local4 = my_xml.createTextNode(answers[_local2][0]);
_local3.appendChild(_local4);
_local3.attributes.correctindex = answers[_local2][1] + 1;
node_answers.appendChild(_local3);
break;
}
_local2++;
}
_local5++;
}
return(true);
}
}
Symbol 379 MovieClip [__Packages.TQLanguage] Frame 0
class TQLanguage
{
var _Node;
function TQLanguage () {
}
function GetText(AId) {
var _local2 = 0;
while (_Node.childNodes[_local2]) {
var _local5 = 0;
while (_Node.childNodes[_local2].childNodes[_local5]) {
if (_Node.childNodes[_local2].childNodes[_local5].attributes.id == AId) {
if (_Node.childNodes[_local2].childNodes[_local5].childNodes[0] == undefined) {
return("");
}
var _local3 = new String();
_local3 = String(_Node.childNodes[_local2].childNodes[_local5].childNodes[0]);
var _local4 = ["&", "&", "<", "<", ">", ">", "'", "'", """, "\"", "²", "\u00B2", "³", "\u00B3", "™", "T"];
_local2 = 0;
while (_local2 < _local4.length) {
_local3 = _local3.split(_local4[_local2]).join(_local4[_local2 + 1]);
_local2 = _local2 + 2;
}
return(_local3);
}
_local5++;
}
_local2++;
}
return("");
}
function LoadFromXML(ANode) {
_Node = ANode;
return(undefined);
}
}
Symbol 380 MovieClip [__Packages.TQDesign] Frame 0
class TQDesign
{
var tfont, lfont, qfont, afont, qbfont, sfont, mfont, ifont, toctfont, tocfont, ffont, takecfont, takefont, timerfont, bfont, backcolor, qback, qbback, qbback2, tocback, dtoc, dtocpoints, dtocciicons, dpoints, dcscore, dnumbering, daudio, dinfo, infoemail, infoweb, numberingstyle, passfailmessages, review, email, print, printusername, passmessage, failmessage, emailaddress, rollover, rollovercolor, rbstyle, cbstyle;
function TQDesign () {
tfont = new TQFont();
lfont = new TQFont();
qfont = new TQFont();
afont = new TQFont();
qbfont = new TQFont();
sfont = new TQFont();
mfont = new TQFont();
ifont = new TQFont();
toctfont = new TQFont();
tocfont = new TQFont();
ffont = new TQFont();
takecfont = new TQFont();
takefont = new TQFont();
timerfont = new TQFont();
bfont = new TQFont();
backcolor = 16777215 /* 0xFFFFFF */;
qback = new TQBackground();
qbback = new TQBackground();
qbback2 = new TQBackground();
tocback = new TQBackground();
dtoc = true;
dtocpoints = true;
dtocciicons = true;
dpoints = true;
dcscore = true;
dnumbering = true;
daudio = true;
dinfo = true;
infoemail = "support@quiz-builder.com";
infoweb = "http://www.quiz-builder.com";
numberingstyle = "0";
passfailmessages = true;
review = true;
email = true;
print = true;
printusername = true;
passmessage = "";
failmessage = "";
emailaddress = "";
rollover = true;
rollovercolor = 16777215 /* 0xFFFFFF */;
}
function RemoveCR(astring) {
var _local2;
var _local5;
var _local3;
var _local6;
var _local1;
var _local4;
_local2 = new String(astring);
_local5 = String.fromCharCode(13) + String.fromCharCode(10);
_local6 = _local2.indexOf(_local5);
if (_local6 != -1) {
_local3 = new String();
_local1 = 0;
while (_local1 < _local2.length) {
_local4 = _local2.charCodeAt(_local1);
if (_local4 != 13) {
_local3 = _local3 + _local2.charAt(_local1);
}
_local1++;
}
return(String(_local3));
}
return(String(_local2));
}
function LoadFromXML(ANode) {
var _local2 = 0;
while (ANode.childNodes[_local2]) {
switch (ANode.childNodes[_local2].nodeName) {
case "tfont" :
tfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "lfont" :
lfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "qfont" :
qfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "afont" :
afont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "qbfont" :
qbfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "sfont" :
sfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "mfont" :
mfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "ifont" :
ifont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "toctfont" :
toctfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "tocfont" :
tocfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "ffont" :
ffont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "takefont" :
takefont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "takecfont" :
takecfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "timerfont" :
timerfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "bfont" :
bfont.LoadFromXML(ANode.childNodes[_local2]);
break;
case "qback" :
qback.LoadFromXML(ANode.childNodes[_local2]);
break;
case "qbback" :
qbback.LoadFromXML(ANode.childNodes[_local2]);
qbback2.enable = qbback.enable;
qbback2.border = qbback.border;
qbback2.fill = qbback.fill;
qbback2.round = qbback.round;
qbback2.shadow = qbback.shadow;
break;
case "tocback" :
tocback.LoadFromXML(ANode.childNodes[_local2]);
break;
case "rollover" :
if (String(ANode.childNodes[_local2].childNodes[0]) == "1") {
rollover = true;
} else {
rollover = false;
}
rollovercolor = Number(ANode.childNodes[_local2].attributes.color);
break;
case "backcolor" :
backcolor = Number(ANode.childNodes[_local2].attributes.color);
break;
case "rbstyle" :
rbstyle = ANode.childNodes[_local2].childNodes[0];
break;
case "cbstyle" :
cbstyle = ANode.childNodes[_local2].childNodes[0];
break;
case "toc" :
if (ANode.childNodes[_local2].attributes.display == "1") {
dtoc = true;
} else {
dtoc = false;
}
if (ANode.childNodes[_local2].attributes.icons == "1") {
dtocciicons = true;
} else {
dtocciicons = false;
}
if (ANode.childNodes[_local2].attributes.points == "1") {
dtocpoints = true;
} else {
dtocpoints = false;
}
break;
case "qbdisplay" :
if (ANode.childNodes[_local2].attributes.points == "1") {
dpoints = true;
} else {
dpoints = false;
}
if (ANode.childNodes[_local2].attributes.cscore == "1") {
dcscore = true;
} else {
dcscore = false;
}
if (ANode.childNodes[_local2].attributes.numbering == "1") {
dnumbering = true;
} else {
dnumbering = false;
}
if (ANode.childNodes[_local2].attributes.audio == "1") {
daudio = true;
} else {
daudio = false;
}
if (ANode.childNodes[_local2].attributes.info == "1") {
dinfo = true;
} else {
dinfo = false;
}
if (ANode.childNodes[_local2].attributes.infoemail != undefined) {
infoemail = ANode.childNodes[_local2].attributes.infoemail;
}
if (ANode.childNodes[_local2].attributes.infoweb != undefined) {
infoweb = ANode.childNodes[_local2].attributes.infoweb;
}
numberingstyle = ANode.childNodes[_local2].attributes.numberingstyle;
if (numberingstyle == undefined) {
numberingstyle = "0";
}
break;
case "finishdisplay" :
if (ANode.childNodes[_local2].attributes.passfailmessages == "1") {
passfailmessages = true;
} else {
passfailmessages = false;
}
if (ANode.childNodes[_local2].attributes.review == "1") {
review = true;
} else {
review = false;
}
if (ANode.childNodes[_local2].attributes.email == "1") {
email = true;
} else {
email = false;
}
if (ANode.childNodes[_local2].attributes.print == "1") {
print = true;
} else {
print = false;
}
if (ANode.childNodes[_local2].attributes.printusername == "1") {
printusername = true;
} else {
printusername = false;
}
if (ANode.childNodes[_local2].attributes.passmessage != undefined) {
passmessage = RemoveCR(ANode.childNodes[_local2].attributes.passmessage);
}
if (ANode.childNodes[_local2].attributes.failmessage != undefined) {
failmessage = RemoveCR(ANode.childNodes[_local2].attributes.failmessage);
}
if (ANode.childNodes[_local2].attributes.emailaddress == undefined) {
break;
}
emailaddress = ANode.childNodes[_local2].attributes.emailaddress;
}
_local2++;
}
}
}
Symbol 381 MovieClip [__Packages.TQFont] Frame 0
class TQFont
{
var name, size, color, bold, italic, backenable, backcolor;
function TQFont () {
name = "Arial";
size = 16;
color = 0;
bold = false;
italic = false;
backenable = false;
backcolor = 0;
}
function LoadFromXML(ANode) {
name = ANode.attributes.name;
size = Number(ANode.attributes.size);
color = Number(ANode.attributes.color);
bold = Boolean(Number(ANode.attributes.bold));
italic = Boolean(Number(ANode.attributes.italic));
backenable = Boolean(Number(ANode.attributes.backenable));
backcolor = Number(ANode.attributes.backcolor);
}
}
Symbol 382 MovieClip [__Packages.TQBackground] Frame 0
class TQBackground
{
var enable, border, fill, round, shadow;
function TQBackground () {
enable = true;
border = 0;
fill = 16777215 /* 0xFFFFFF */;
round = false;
shadow = false;
}
function LoadFromXML(ANode) {
enable = Boolean(Number(ANode.attributes.enable));
border = Number(ANode.attributes.border);
fill = Number(ANode.attributes.fill);
round = Boolean(Number(ANode.attributes.round));
shadow = Boolean(Number(ANode.attributes.shadow));
}
}
Symbol 383 MovieClip [__Packages.TQMatchdd] Frame 0
class TQMatchdd extends TQBase
{
var match, answers, AnswersNumber, shuffle;
function TQMatchdd (atype) {
super(atype);
match = new Array();
}
function AddAnswer(ANode) {
var _local3 = new Array();
var _local4 = new Array();
_local3[0] = _global.RemoveCR(ANode.childNodes[0]);
_local3[1] = answers.length;
_local3[2] = -1;
_local3[3] = -1;
_local4[0] = _global.RemoveCR(ANode.attributes.match);
_local4[1] = _local3[1];
_local4[2] = match.length;
answers.push(_local3);
match.push(_local4);
}
function GetResponseAsString() {
var _local4;
_local4 = "";
var _local5;
var _local3;
var _local6 = answers.length;
if (_local6 <= 0) {
} else {
_local5 = 0;
while (_local5 < _local6) {
_local4 = _local4 + match[_local5][0];
_local3 = 0;
while (_local3 < _local6) {
if (answers[_local3][3] == _local5) {
_local4 = (_local4 + ".") + answers[_local3][0];
}
_local3++;
}
if (_local5 < (_local6 - 1)) {
_local4 = _local4 + _global.response_separator;
}
_local5++;
}
}
return(_local4);
}
function GetResponseAsStringLMS() {
var _local3;
_local3 = "";
var _local5;
var _local4;
var _local6 = answers.length;
if (_local6 <= 0) {
} else {
_local5 = 0;
while (_local5 < _local6) {
if (length(_local3) > 0) {
_local3 = _local3 + _global.response_separator;
}
_local3 = _local3 + match[_local5][2];
_local4 = 0;
while (_local4 < _local6) {
if (answers[_local4][3] == _local5) {
if (_global.scoversion == 1) {
_local3 = _local3 + "[.]";
} else {
_local3 = _local3 + ".";
}
_local3 = _local3 + chr(97 + answers[_local4][1]);
}
_local4++;
}
_local5++;
}
}
return(_local3);
}
function GetCorrectResponseAsString() {
var _local4;
_local4 = "";
var _local5;
var _local3;
var _local6 = answers.length;
if (_local6 <= 0) {
} else {
_local5 = 0;
while (_local5 < _local6) {
_local4 = _local4 + match[_local5][0];
_local3 = 0;
while (_local3 < _local6) {
if (answers[_local3][1] == match[_local5][1]) {
_local4 = (_local4 + ".") + answers[_local3][0];
}
_local3++;
}
if (_local5 < (_local6 - 1)) {
_local4 = _local4 + _global.response_separator;
}
_local5++;
}
}
return(_local4);
}
function GetCorrectResponseAsStringLMS() {
var _local3;
_local3 = "";
var _local5;
var _local4;
var _local6 = answers.length;
if (_local6 <= 0) {
} else {
_local5 = 0;
while (_local5 < _local6) {
if (length(_local3) > 0) {
_local3 = _local3 + _global.response_separator;
}
_local3 = _local3 + match[_local5][2];
_local4 = 0;
while (_local4 < _local6) {
if (answers[_local4][1] == match[_local5][1]) {
if (_global.scoversion == 1) {
_local3 = _local3 + "[.]";
} else {
_local3 = _local3 + ".";
}
_local3 = _local3 + chr(97 + answers[_local4][1]);
}
_local4++;
}
_local5++;
}
}
return(_local3);
}
function GetMatch(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(match[AIndex][0]);
}
return("");
}
function GetMatchIndex(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(Number(match[AIndex][1]));
}
return(-1);
}
function GetResponse(AIndex) {
}
function GetOrder(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex][3]);
}
return(0);
}
function SetOrder(AIndex, ANewOrder) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
answers[AIndex][3] = ANewOrder;
return(ANewOrder);
}
return(-1);
}
function GetIndexFromOrder(AOrder) {
var _local2;
var _local3 = answers.length;
if (_local3 <= 0) {
return(-1);
}
_local2 = 0;
while (_local2 < _local3) {
if (answers[_local2][3] == AOrder) {
return(_local2);
}
_local2++;
}
return(-1);
}
function GetAnswerMatchIndex(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(Number(answers[AIndex][2]));
}
return(-1);
}
function GetAnswerMatchOrder(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
var _local2;
var _local4;
var _local3;
_local3 = answers[AIndex][1];
_local4 = answers.length;
_local2 = 0;
while (_local2 < _local4) {
if (match[_local2][1] == _local3) {
return(_local2);
}
_local2++;
}
return(-1);
}
return(-1);
}
function SetAnswerMatchIndex(AIndex, AMatch) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
answers[AIndex][2] = AMatch;
}
}
function UserResponse() {
var _local2;
var _local3 = answers.length;
if (_local3 <= 0) {
return(false);
}
_local2 = 0;
while (_local2 < _local3) {
if (answers[_local2][1] != answers[_local2][2]) {
return(false);
}
_local2++;
}
return(true);
}
function GetCorrect(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
if (answers[AIndex][1] == answers[AIndex][2]) {
return(true);
}
return(false);
}
return(false);
}
function IsAnswered() {
var _local2;
var _local3 = answers.length;
if (_local3 <= 0) {
return(false);
}
_local2 = 0;
while (_local2 < _local3) {
if (answers[_local2][2] == -1) {
return(false);
}
_local2++;
}
return(true);
}
function LoadFromXML(ANode) {
super.LoadFromXML(ANode);
answers.sort(function () {
return(random(5) - 1);
});
var _local4 = AnswersNumber();
var _local3;
_local3 = 0;
while (_local3 < _local4) {
answers[_local3][3] = _local3;
_local3++;
}
if (shuffle.toLowerCase() == "y") {
match.sort(function () {
return(random(5) - 1);
});
}
}
function XMLAddAnswers(my_xml, node_answers) {
var _local4;
var _local2;
var _local5 = answers.length;
if (_local5 <= 0) {
} else {
_local4 = 0;
while (_local4 < _local5) {
var _local3 = my_xml.createElement("answer");
node_answers.appendChild(_local3);
_local2 = 0;
while (_local2 < _local5) {
if (answers[_local2][3] == _local4) {
_local3.attributes.correctchoiceindex = GetAnswerMatchOrder(_local2) + 1;
_local3.attributes.match = answers[_local2][0];
}
_local2++;
}
_local3.attributes.choice = match[_local4][0];
_local4++;
}
}
return(true);
}
}
Symbol 384 MovieClip [__Packages.TQEdit] Frame 0
class TQEdit extends TQBase
{
var answers, AnswersNumber;
function TQEdit (atype) {
super(atype);
}
function AddAnswer(ANode) {
var _local3;
_local3 = _global.RemoveCR(String(ANode.childNodes[0]).toLowerCase());
answers.push(_local3);
}
function GetResponse(AIndex) {
if ((AIndex >= 0) && (AIndex < AnswersNumber())) {
return(answers[AIndex]);
}
return("");
}
function SetResponse(AResponse) {
answer = String(AResponse).toLowerCase();
}
function UserResponse() {
var _local2;
var _local3 = answers.length;
if (_local3 <= 0) {
return(false);
}
_local2 = 0;
while (_local2 < _local3) {
if (answers[_local2] == answer) {
return(true);
}
_local2++;
}
return(false);
}
function IsAnswered() {
if (answer == "") {
return(false);
}
return(true);
}
function GetResponseAsString() {
var _local2;
_local2 = answer;
return(_local2);
}
function GetResponseAsStringLMS() {
var _local2;
_local2 = GetResponseAsString();
return(_local2);
}
function GetCorrectResponseAsString() {
var _local4;
_local4 = "";
var _local3;
var _local5 = answers.length;
if (_local5 <= 0) {
} else {
_local3 = 0;
while (_local3 < _local5) {
_local4 = _local4 + answers[_local3];
if (_local3 < (_local5 - 1)) {
_local4 = _local4 + _global.response_separator;
}
_local3++;
}
}
return(_local4);
}
function GetCorrectResponseAsStringLMS() {
var _local2;
_local2 = GetCorrectResponseAsString();
return(_local2);
}
function XMLAddAnswers(my_xml, node_answers) {
var _local3 = my_xml.createElement("userresponse");
var _local4 = my_xml.createTextNode(answer);
_local3.appendChild(_local4);
node_answers.parentNode.appendChild(_local3);
var _local2;
var _local6 = answers.length;
if (_local6 <= 0) {
} else {
_local2 = 0;
while (_local2 < _local6) {
_local3 = my_xml.createElement("answer");
_local4 = my_xml.createTextNode(answers[_local2]);
_local3.appendChild(_local4);
node_answers.appendChild(_local3);
_local2++;
}
}
return(true);
}
var answer = "";
}
Symbol 385 MovieClip [__Packages.TQFinish] Frame 0
class TQFinish
{
var timelimited, time, showtime, actionpass, actionfail, actionpassswf, actionpassurl, actionpassexe, actionfailswf, actionfailurl, actionfailexe;
function TQFinish () {
timelimited = false;
time = 600000 /* 0x0927C0 */;
showtime = false;
actionpass = "3";
actionfail = "3";
}
function LoadFromXML(ANode) {
var _local3 = 0;
var _local5;
while (ANode.childNodes[_local3]) {
switch (ANode.childNodes[_local3].nodeName) {
case "score" :
_global.passedscore = ANode.childNodes[_local3].attributes.value;
break;
case "time" :
ANode.childNodes[_local3].attributes.nrquestions;
if (ANode.childNodes[_local3].attributes.limited == "1") {
timelimited = true;
} else {
timelimited = false;
}
time = 0;
_local5 = Number(ANode.childNodes[_local3].attributes.ss);
time = time + (_local5 * 1000);
_local5 = Number(ANode.childNodes[_local3].attributes.mm);
time = time + ((_local5 * 60) * 1000);
_local5 = Number(ANode.childNodes[_local3].attributes.hh);
time = time + ((_local5 * 3600) * 1000);
if (ANode.childNodes[_local3].attributes.show == "1") {
showtime = true;
} else {
showtime = false;
}
break;
case "actionpass" :
actionpass = ANode.childNodes[_local3].firstChild;
actionpassswf = ANode.childNodes[_local3].attributes.swf;
actionpassurl = ANode.childNodes[_local3].attributes.url;
actionpassexe = ANode.childNodes[_local3].attributes.exe;
break;
case "actionfail" :
actionfail = ANode.childNodes[_local3].firstChild;
actionfailswf = ANode.childNodes[_local3].attributes.swf;
actionfailurl = ANode.childNodes[_local3].attributes.url;
actionfailexe = ANode.childNodes[_local3].attributes.exe;
}
_local3++;
}
}
}
Symbol 386 MovieClip [__Packages.TQOptions] Frame 0
class TQOptions
{
var all, nrquestions, randomize, submitone, allowfinish, take;
function TQOptions () {
all = true;
nrquestions = 1;
randomize = false;
submitone = true;
allowfinish = false;
take = true;
}
function LoadFromXML(ANode) {
var _local2 = 0;
while (ANode.childNodes[_local2]) {
switch (ANode.childNodes[_local2].nodeName) {
case "all" :
if (String(ANode.childNodes[_local2].childNodes[0]) == "0") {
all = false;
} else {
all = true;
}
nrquestions = ANode.childNodes[_local2].attributes.nrquestions;
if (nrquestions == undefined) {
nrquestions = 1;
}
if (ANode.childNodes[_local2].attributes.randomize == "1") {
randomize = true;
} else {
randomize = false;
}
break;
case "submitone" :
if (String(ANode.childNodes[_local2].childNodes[0]) == "0") {
submitone = false;
} else {
submitone = true;
}
if (ANode.childNodes[_local2].attributes.finish == "1") {
allowfinish = true;
} else {
allowfinish = false;
}
if (ANode.childNodes[_local2].attributes.take == "1") {
take = true;
} else {
take = false;
}
}
_local2++;
}
}
}
Instance of Symbol 152 MovieClip "b" in Symbol 153 MovieClip Frame 1
onClipEvent (load) {
var _index;
var _text;
this.onRollOver = function () {
if (_global.design.rollover == true) {
if (_index != _global.currentQuestionNumber) {
if (_text != t.text) {
_parent._parent._parent.mchint.Show(_text, t._x + _parent._parent._x, (t._y + this._y) + _parent._parent._y, _parent.hintwidth);
}
}
}
};
this.onRollOut = function () {
_parent._parent._parent.mchint.UnShow();
};
this.onRelease = function () {
if (_global.currentQuestionNumber != _index) {
_global.StartSound("sclick");
_parent._parent._parent.mchint.UnShow();
GoToQuestion(_index);
}
};
}
Instance of Symbol 153 MovieClip "list" in Symbol 154 MovieClip Frame 1
onClipEvent (load) {
var hintwidth = 0;
this.ItemResize = function (item, index, _lasty) {
var _local4;
var _local11;
var _local5;
var _local14;
var _local10;
var _local8;
item.crt.text = "99.";
item.crt.wordWrap = false;
_global.settextformat(item.crt, _global.design.tocfont);
_local8 = item.crt.getTextFormat();
_local8.bold = true;
item.crt.setTextFormat(_local8);
item.crt.autoSize = "right";
var _local6 = item.crt._width;
item.crt.text = (index + 1) + ".";
_global.settextformat(item.crt, _global.design.tocfont);
_local8 = item.crt.getTextFormat();
_local8.bold = !_global.quizItems[index].IsAnswered();
item.crt.setTextFormat(_local8);
item.crt.autoSize = "right";
_local6 = _local6 - item.crt._width;
_local6 = _local6 + 3;
_local5 = (_global.toc_width - (2 * _global.border)) - 5;
if (_parent._parent.btnUp._visible == true) {
_local5 = _local5 - _parent._parent.btnUp._width;
}
if (_global.design.dtocciicons == false) {
item.crt._x = 3 + _local6;
} else {
item.mccorrect._x = 0;
item.mcincorrect._x = 0;
item.crt._x = (item.mccorrect._width + 3) + _local6;
}
item.t._x = (item.crt._x + item.crt._width) + 5;
if (_global.design.dtocpoints == true) {
var _local12;
item.points.text = "999";
item.points.wordWrap = false;
_global.settextformat(item.points, _global.design.tocfont);
item.points.autoSize = "right";
_local12 = item.points._width + 3;
item.points.text = _global.quizItems[i].points;
item.points.wordWrap = false;
_global.settextformat(item.points, _global.design.tocfont);
item.points.autoSize = "right";
item.points._visible = true;
} else {
item.points._visible = false;
}
if (_global.design.dtocpoints == false) {
_local4 = _local5 - item.t._x;
} else {
_local4 = (_local5 - item.t._x) - _local12;
}
item.t.autoSize = true;
item.t.wordWrap = false;
item.t.text = quizItems[index].question;
_global.settextformat(item.t, _global.design.tocfont);
item._text = item.t.text;
_local4 = _local4 - 20;
if (item.t._width > _local4) {
item.t.autosize = false;
_local10 = new String();
_local10 = quizItems[index].question;
_local11 = (length(_local10) * _local4) / item.t._width;
_local11 = Math.round(_local11) - 3;
item.t._width = _local4;
item.t.text = String(_local10).substr(0, _local11) + "...";
} else {
item.t._width = _local4;
}
_global.settextformat(item.t, _global.design.tocfont);
item.t.autosize = false;
item.points._x = ((((item.t._x + _local4) + 20) + _local12) - item.points._width) - 6;
if ((quizItems[index].completed == true) && (_global.design.dtocciicons == true)) {
item.mccorrect._visible = quizItems[index].UserResponse();
item.mcincorrect._visible = !item.mccorrect._visible;
item.mccorrect._y = Math.floor((item.t._height - item.mccorrect._height) / 2);
item.mcincorrect._y = item.mccorrect._y;
} else {
item.mccorrect._visible = false;
item.mcincorrect._visible = false;
}
item.back._x = 0;
item.back._y = 0;
var _local9 = 0;
_local9 = item.t._height;
item.back._alpha = 100;
item.back.clear();
if (_global.design.dtocpoints == true) {
item.back.lineStyle(1, 6710886, 100);
} else {
item.back.lineStyle(1, 6710886, 0);
}
item.back.moveTo(((item.t._x + _local4) + 20) - 2, -2);
item.back.lineTo(((item.t._x + _local4) + 20) - 2, _local9 + 2);
if ((index + 1) == _global.currentQuestionNumber) {
item.back.clear();
item.back.lineStyle(1, 6710886, 100);
item.back.beginFill(16777215, 100);
item.back.moveTo(1, 0);
item.back.lineTo((_local5 - item.back._x) - 5, 0);
item.back.lineTo((_local5 - item.back._x) - 5, _local9);
item.back.lineTo(1, _local9);
item.back.lineTo(1, 0);
item.back.endFill();
}
hintwidth = _local4;
item.back2._alpha = 0;
item.back2._width = _local5 - item.back._x;
item.back2._height = item.t._height;
item._y = _lasty;
item.mccorrect._x = 0;
item.mccorrect._y = 0;
};
this.Populate = function () {
j = _global.qoptions.nrquestions;
i = 0;
while (i < j) {
var item = eval ("b" + i);
item.removeMovieClip();
i++;
}
var _lasty = 0;
i = 0;
while (i < j) {
var item = b.duplicateMovieClip("b" + i, i + 5);
item._index = i + 1;
ItemResize(item, i, _lasty);
_lasty = (_lasty + item.t._height) + 2;
i++;
}
b._visible = false;
};
this.Resize = function () {
var _lasty = 0;
j = _global.qoptions.nrquestions;
i = 0;
while (i < j) {
item = eval ("b" + i);
ItemResize(item, i, _lasty);
_lasty = (_lasty + item.t._height) + 2;
i++;
}
};
}
Symbol 162 MovieClip Frame 1
_visible = false;
stop();
Symbol 162 MovieClip Frame 5
if (_show == true) {
_visible = true;
} else {
_visible = false;
}
stop();
Symbol 162 MovieClip Frame 98
_visible = false;
gotoAndStop ("stop");
Instance of Symbol 114 MovieClip "btnUp" in Symbol 163 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 115 MovieClip "btnDown" in Symbol 163 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 162 MovieClip "mchint" in Symbol 163 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
var _show = false;
this.Show = function (atext, ax, ay, aw) {
_show = true;
t.text = atext;
t.wordWrap = true;
t._width = (_global.width - ax) - 30;
t._x = ax;
t._y = ay;
var _local5;
_local5 = t.getTextFormat();
_local5.font = _global.design.tocfont.name;
_local5.size = _global.design.tocfont.size;
_local5.color = _global.design.tocfont.color;
t.setTextFormat(_local5);
t.autoSize = true;
if (t.textWidth < (t._width - 4)) {
t._width = t.textWidth + 10;
}
t.borderColor = 6710886 /* 0x666666 */;
t.background = false;
this.clear();
this.beginFill(_global.design.rollovercolor, 100);
this.lineStyle(0, 0, 0);
this.moveTo(ax, ay);
this.lineTo(ax + t._width, ay);
this.lineTo(ax + t._width, ay + t._height);
this.lineTo(ax, ay + t._height);
this.lineTo(ax, ay);
this.endFill();
this._x = 0;
this._y = 0;
this.gotoAndPlay("start");
};
this.UnShow = function () {
_show = false;
_visible = false;
stop();
this.gotoAndStop("stop");
};
}
Symbol 167 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
_parent._parent.Minimize();
}
Instance of Symbol 141 MovieClip "bg" in Symbol 169 MovieClip Frame 1
onClipEvent (load) {
this.useHandCursor = false;
this.onRollOver = function () {
};
this.onRollOut = function () {
};
this.onRelease = function () {
};
this.Resize = function () {
_global.drawback(this, _global.toc_width, _global.toc_height, "box2", _global.design.tocback, _global.toct_height, _global.design.toctfont.backcolor);
};
}
Instance of Symbol 163 MovieClip "scroll" in Symbol 169 MovieClip Frame 1
onClipEvent (load) {
var scrollHeight = scrollTrack._height;
var contentHeight = contentMain._height;
var scrollFaceHeight = scrollFace._height;
var maskHeight = maskedView._height;
a = true;
if (contentHeight < maskHeight) {
a = false;
}
scrollFace._visible = a;
scrollTrack._visible = a;
btnUp._visible = a;
btnDown._visible = a;
btnUp.enabled = a;
btnDown.enabled = a;
if (a == true) {
scrollFace._height = scrollTrack._height * (maskHeight / contentHeight);
scrollFaceHeight = scrollFace._height;
}
var initPosition = ((scrollFace._y = scrollTrack._y));
var initContentPos = contentMain._y;
var finalContentPos = ((maskHeight - contentHeight) + initContentPos);
var left = scrollTrack._x;
var top = scrollTrack._y;
var right = scrollTrack._x;
var bottom = ((scrollTrack._height - scrollFaceHeight) + scrollTrack._y);
var dy = 0;
var speed = 10;
var moveVal = ((contentHeight - maskHeight) / (scrollHeight - scrollFaceHeight));
this.Resize = function () {
var _local2;
_local2 = _global.toc_width;
maskedView._width = _local2 - (2 * _global.border);
if (btnUp._visible == true) {
maskedView._width = maskedView._width - btnUp._width;
}
maskedView._height = (_global.toc_height - (2 * _global.border)) - _global.toct_height;
btnUp._x = (maskedView._width + maskedView._x) - 8;
scrollTrack._height = (maskedView._height - btnUp._height) - btnDown._height;
btnDown._x = btnUp._x;
btnDown._y = scrollTrack._y + scrollTrack._height;
scrollTrack._x = btnUp._x;
scrollFace._x = btnUp._x;
contentMain.list.Resize();
Update();
contentMain.list.Resize();
left = scrollTrack._x;
top = scrollTrack._y;
right = scrollTrack._x;
bottom = (scrollTrack._height - scrollFaceHeight) + scrollTrack._y;
};
this.Update = function () {
scrollHeight = scrollTrack._height;
contentHeight = contentMain._height;
scrollFaceHeight = scrollFace._height;
maskHeight = maskedView._height;
a = true;
if (contentHeight < maskHeight) {
a = false;
}
scrollFace._visible = a;
scrollTrack._visible = a;
btnUp._visible = a;
btnDown._visible = a;
btnUp.enabled = a;
btnDown.enabled = a;
if (a == true) {
scrollFace._height = scrollTrack._height * (maskHeight / contentHeight);
scrollFaceHeight = scrollFace._height;
}
finalContentPos = (maskHeight - contentHeight) + initContentPos;
left = scrollTrack._x;
top = scrollTrack._y;
right = scrollTrack._x;
bottom = (scrollTrack._height - scrollFaceHeight) + scrollTrack._y;
moveVal = (contentHeight - maskHeight) / (scrollHeight - scrollFaceHeight);
};
scrollFace.onPress = function () {
var _local2 = this._y;
startDrag (this, false, left, top, right, bottom);
this.onMouseMove = function () {
dy = Math.abs(initPosition - this._y);
contentMain._y = Math.round(((dy * -1) * moveVal) + initContentPos);
};
};
scrollFace.onMouseUp = function () {
stopDrag();
delete this.onMouseMove;
};
btnUp.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._y + speed) < maskedView._y) {
if (scrollFace._y <= top) {
scrollFace._y = top;
} else {
scrollFace._y = scrollFace._y - (speed / moveVal);
}
contentMain._y = contentMain._y + speed;
} else {
scrollFace._y = top;
contentMain._y = maskedView._y;
delete this.onEnterFrame;
}
};
};
btnUp.onDragOut = function () {
delete this.onEnterFrame;
};
btnUp.onRelease = function () {
delete this.onEnterFrame;
};
btnDown.onPress = function () {
this.onEnterFrame = function () {
if ((contentMain._y - speed) > finalContentPos) {
if (scrollFace._y >= bottom) {
scrollFace._y = bottom;
} else {
scrollFace._y = scrollFace._y + (speed / moveVal);
}
contentMain._y = contentMain._y - speed;
} else {
scrollFace._y = bottom;
contentMain._y = finalContentPos;
delete this.onEnterFrame;
}
};
};
btnDown.onRelease = function () {
delete this.onEnterFrame;
};
btnDown.onDragOut = function () {
delete this.onEnterFrame;
};
}
Instance of Symbol 168 MovieClip "header" in Symbol 169 MovieClip Frame 1
onClipEvent (load) {
this.Resize = function () {
this._xscale = 100;
this._yscale = 100;
t._xscale = 100;
t._yscale = 100;
var _local3;
_local3 = _global.toc_width;
btnclose._x = (_local3 - btnclose._width) - _global.toc_btnclosedy;
t.text = _global.GetText("toctitle");
t.autoSize = true;
_global.settextformat(t, _global.design.toctfont);
t._x = (_global.border + Math.floor(((btnclose._x - _global.border) - t._width) / 2)) - 2;
t._y = Math.floor((_global.toct_height - t._height) / 2) - 2;
};
}
Symbol 191 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
q = _parent.currentQuizItem;
if (q.IsAnswered() == false) {
_parent.mcfeed.Show(_global.GetText("msgimcomplete"), "btnfeedcontinue", false);
} else if (q.UserResponse() == true) {
q.AddLatency(getTimer() - _global.qbegintime);
q.completed = true;
_parent.ReportInteraction(_global.currentQuestionNumber - 1);
_global.NextQuestion();
_global.jump = "process";
if (q.feedback == true) {
_parent.mcfeed.Show(q.feedbackok, "btnfeedcontinue", true);
} else if (_parent.take._checked == true) {
_parent.mctake.Show();
} else {
_parent.gotoAndPlay(_global.jump);
}
} else if (q.feedback == true) {
q.attempts++;
if (q.attempts < q.maxattempts) {
_parent.mcfeed.Show(q.feedbackwrong, "btnfeedretry", false);
} else {
q.AddLatency(getTimer() - _global.qbegintime);
q.completed = true;
_parent.ReportInteraction(_global.currentQuestionNumber - 1);
_global.NextQuestion();
_global.jump = "process";
_parent.mcfeed.Show(q.feedbackwrong, "btnfeedcontinue", true);
}
} else {
q.AddLatency(getTimer() - _global.qbegintime);
q.completed = true;
_parent.ReportInteraction(_global.currentQuestionNumber - 1);
_global.NextQuestion();
if (_parent.take._checked == true) {
_parent.mctake.Show();
} else {
_parent.gotoAndPlay("process");
}
}
}
Symbol 194 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
_global.currentQuestionNumber--;
_parent.gotoAndPlay("process");
}
Symbol 197 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
_global.currentQuestionNumber++;
_parent.gotoAndPlay("process");
}
Symbol 204 MovieClip Frame 1
var item = _parent._parent.t;
if (item != undefined) {
item._x = item._x + 1;
item._y = item._y + 1;
}
Symbol 205 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
if (_global.review == true) {
_parent.gotoAndStop("summary");
return(undefined);
}
if (_global.IsAnswered() == true) {
_parent.mcfeed.Showyn("submitallcomplete");
} else if (_global.qoptions.allowfinish == true) {
_parent.mcfeed.Showyn("submitallincomplete");
} else {
_parent.mcfeed.Show(_global.GetText("submitallnotification"), "btnfeedcontinue", false);
}
}
Symbol 219 MovieClip Frame 38
gotoAndPlay (10);
Symbol 220 MovieClip Frame 40
gotoAndPlay (10);
Symbol 221 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
mctable.Minimize();
}
Symbol 224 MovieClip Frame 1
stop();
Symbol 224 MovieClip Frame 7
stop();
Symbol 224 MovieClip Frame 15
stop();
Instance of Symbol 230 MovieClip "b" in Symbol 231 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
var _selected;
var _correct;
bg._y = 0;
bg._x = 0;
text._y = 0;
this.onRollOver = function () {
if (_global.design.rollover == true) {
var _local2 = new Color(bg);
_local2.setRGB(_global.design.rollovercolor);
bg.gotoAndPlay("over");
_global.StartSound("sover");
}
};
this.onRollOut = function () {
if (_global.design.rollover == true) {
var _local2 = new Color(bg);
_local2.setRGB(_global.design.rollovercolor);
bg.gotoAndPlay("out");
}
};
this.onRelease = function () {
if (_selected == true) {
return(undefined);
}
_global.StartSound("sclick");
_selected = !_selected;
_parent.SetSelected(_index);
};
}
onClipEvent (enterFrame) {
if (_name == "b") {
_visible = false;
} else {
_visible = true;
bsel._visible = _selected;
bunsel._visible = !_selected;
if (review == true) {
mcreview._visible = _correct;
} else {
mcreview._visible = false;
}
}
}
Symbol 233 MovieClip Frame 1
stop();
Symbol 233 MovieClip Frame 10
stop();
Symbol 233 MovieClip Frame 21
stop();
Instance of Symbol 238 MovieClip "b" in Symbol 239 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
var _selected;
var _correct;
bg._y = 0;
bg._x = 0;
text._y = 0;
this.onRollOver = function () {
if (_global.design.rollover == true) {
var _local2 = new Color(bg);
_local2.setRGB(_global.design.rollovercolor);
bg.gotoAndPlay("over");
_global.StartSound("sover");
}
};
this.onRollOut = function () {
if (_global.design.rollover == true) {
var _local2 = new Color(bg);
_local2.setRGB(_global.design.rollovercolor);
bg.gotoAndPlay("out");
}
};
this.onRelease = function () {
_global.StartSound("sclick");
_selected = !_selected;
_parent.SetSelected(_index);
};
}
onClipEvent (enterFrame) {
if (_name == "b") {
_visible = false;
} else {
_visible = true;
bsel._visible = _selected;
bunsel._visible = !_selected;
if (review == true) {
mcreview._visible = _correct;
} else {
mcreview._visible = false;
}
}
}
Instance of Symbol 244 MovieClip "e" in Symbol 248 MovieClip Frame 1
onClipEvent (load) {
t.onChanged = function (t) {
_parent.Changed();
};
}
Instance of Symbol 250 MovieClip "b" in Symbol 251 MovieClip Frame 1
onClipEvent (load) {
_dragged = false;
_fromdest = false;
this.onRollOver = function () {
if (_name == "dest") {
return(undefined);
}
if (_global.design.rollover) {
_parent.drawback(this, this._width - 2, this._height - 2, _global.design.rollovercolor);
_global.StartSound("sover");
}
};
this.onRollOut = function () {
if (_name == "dest") {
return(undefined);
}
if (_global.design.rollover) {
if (indest() == true) {
_parent.drawback(this, this._width - 2, this._height - 2, _parent._destcolor);
} else {
_parent.drawback(this, this._width - 2, this._height - 2, _parent._normalcolor);
}
}
};
this.indest = function () {
if ((this._x == _parent.dest._x) && (this._y == _parent.dest._y)) {
return(true);
}
return(false);
};
this.onPress = function () {
if (_name == "dest") {
return(undefined);
}
_fromdest = indest();
this.swapDepths(1000);
this.startDrag(false);
_dragged = true;
};
this.onRelease = function () {
_dragged = false;
this.stopDrag();
if (this.hitTest(_parent.dest) == true) {
_global.StartSound("sclick");
_parent.UpdateSelected(this);
} else if (_fromdest == true) {
_parent.UpdateSelected(undefined);
}
_parent.UpdateItems();
};
this.onReleaseOutside = this.onRelease;
}
onClipEvent (enterFrame) {
if (_dragged == true) {
var contentMain = _parent._parent;
var p = _parent._parent._parent;
var speed = p.speed;
var moveValV = p.moveValV;
var maskedView = p.maskedView;
if (contentMain._y < 0) {
if ((this._y + contentMain._y) < 10) {
var old = contentMain._y;
if ((contentMain._y + speed) < maskedView._y) {
if (p.VFace._y <= p.VTrack._y) {
p.VFace._y = p.VTrack._y;
} else {
p.VFace._y = p.VFace._y - (speed / moveValV);
}
contentMain._y = contentMain._y + speed;
} else {
p.VFace._y = p.VTrack._y;
p.contentMain._y = p.maskedView._y;
}
var v1 = this._y;
this._y = this._y - (contentMain._y - old);
}
}
}
}
Instance of Symbol 254 MovieClip "m" in Symbol 258 MovieClip Frame 1
onClipEvent (load) {
}
Instance of Symbol 257 MovieClip "a" in Symbol 258 MovieClip Frame 1
onClipEvent (load) {
this.onPress = function () {
this.swapDepths(1000);
this.startDrag(false);
_dragged = true;
onRollOver();
this.onEnterFrame = function () {
if (_dragged == true) {
var _local4 = _parent._parent;
var _local3 = _parent._parent._parent;
var _local5 = _local3.speed;
var _local7 = _local3.moveValV;
var _local6 = _local3.maskedView;
if (_local4._y < 0) {
if ((this._y + _local4._y) < 10) {
var _local8 = _local4._y;
if ((_local4._y + _local5) < _local6._y) {
if (_local3.VFace._y <= _local3.VTrack._y) {
_local3.VFace._y = _local3.VTrack._y;
} else {
_local3.VFace._y = _local3.VFace._y - (_local5 / _local7);
}
_local4._y = _local4._y + _local5;
} else {
_local3.VFace._y = _local3.VTrack._y;
_local3.contentMain._y = _local3.maskedView._y;
}
this._y = this._y - (_local4._y - _local8);
}
}
if (_local4._height > _local6._height) {
if (_local3.VUp._visible == false) {
return(undefined);
}
if (((this._y + this._height) + _local4._y) > _local6._height) {
var _local8 = _local4._y;
if ((_local4._y - _local5) > _local3.finalContentPosV) {
if (_local3.VFace._y >= _local3.bottom) {
_local3.VFace._y = _local3.bottom;
} else {
_local3.VFace._y = _local3.VFace._y + (_local5 / _local7);
}
_local4._y = _local4._y - _local5;
} else {
_local3.VFace._y = _local3.bottom;
_local4._y = _local3.finalContentPosV;
}
this._y = this._y - (_local4._y - _local8);
}
}
}
};
};
this.onRelease = function () {
_dragged = false;
delete this.onEnterFrame;
this.stopDrag();
var _local4;
_local4 = _parent.HitMatchOrder(this);
if (_local4 != -1) {
_global.StartSound("sclick");
_parent.MoveAnswer(_index, _local4);
} else {
_parent._object.SetAnswerMatchIndex(_index, -1);
}
_parent.UpdateItems();
};
this.onReleaseOutside = this.onRelease;
this.onRollOver = function () {
if (_global.design.rollover == true) {
_parent.drawbackright(this, (((this.t._width + (2 * _parent._dx3)) + _parent.mw) + _parent._rw) + _parent._dx1, _parent._maxheight + 4, _global.design.rollovercolor, _parent._rw + _parent._dx1, _parent._object.GetAnswerMatchIndex(_index));
_global.StartSound("sover");
}
};
this.onRollOut = function () {
if (_global.design.rollover == true) {
_parent.drawbackright(this, (((this.t._width + (2 * _parent._dx3)) + _parent.mw) + _parent._rw) + _parent._dx1, _parent._maxheight + 4, _parent._normalcolor, _parent._rw + _parent._dx1, _parent._object.GetAnswerMatchIndex(_index));
}
};
}
Instance of Symbol 268 MovieClip "b" in Symbol 273 MovieClip Frame 1
onClipEvent (load) {
_visible = true;
_dragged = false;
this.onRollOver = function () {
if (_global.design.rollover == true) {
var _local2 = new Color(bg);
_local2.setRGB(_global.design.rollovercolor);
bg.gotoAndPlay("over");
_global.StartSound("sover");
}
};
this.onRollOut = function () {
if (_global.design.rollover == true) {
var _local2 = new Color(bg);
_local2.setRGB(_global.design.rollovercolor);
bg.gotoAndPlay("out");
}
};
this.onPress = function () {
this.swapDepths(1000);
this.startDrag(false);
_dragged = true;
this.onEnterFrame = function () {
if (_dragged == true) {
var _local4 = _parent._parent;
var _local3 = _parent._parent._parent;
var _local5 = _local3.speed;
var _local7 = _local3.moveValV;
var _local6 = _local3.maskedView;
if (_local4._y < 0) {
if ((this._y + _local4._y) < 10) {
var _local8 = _local4._y;
if ((_local4._y + _local5) < _local6._y) {
if (_local3.VFace._y <= _local3.VTrack._y) {
_local3.VFace._y = _local3.VTrack._y;
} else {
_local3.VFace._y = _local3.VFace._y - (_local5 / _local7);
}
_local4._y = _local4._y + _local5;
} else {
_local3.VFace._y = _local3.VTrack._y;
_local3.contentMain._y = _local3.maskedView._y;
}
this._y = this._y - (_local4._y - _local8);
}
}
if (_local4._height > _local6._height) {
if (_local3.VUp._visible == false) {
return(undefined);
}
if (((this._y + this._height) + _local4._y) > _local6._height) {
var _local8 = _local4._y;
if ((_local4._y - _local5) > _local3.finalContentPosV) {
if (_local3.VFace._y >= _local3.bottom) {
_local3.VFace._y = _local3.bottom;
} else {
_local3.VFace._y = _local3.VFace._y + (_local5 / _local7);
}
_local4._y = _local4._y - _local5;
} else {
_local3.VFace._y = _local3.bottom;
_local4._y = _local3.finalContentPosV;
}
this._y = this._y - (_local4._y - _local8);
}
}
}
};
};
this.onMouseMove = function () {
if (_dragged == true) {
var k = _parent._object.AnswersNumber();
i = 0;
while (i < k) {
item = eval ("_parent.b" + i);
if ((this.hitTest(item) == true) && (item != this)) {
_parent.line.swapDepths(999);
_parent.line._y = item._y - 3;
_parent.line._visible = true;
return(undefined);
}
i++;
}
var min;
var max;
min = 10000;
max = 0;
var k = _parent._object.AnswersNumber();
i = 0;
while (i < k) {
item = eval ("_parent.b" + i);
if (item != this) {
if (min > item._y) {
min = item._y;
}
if (max < (item._y + item._height)) {
max = item._y + item._height;
}
}
i++;
}
if (this._y > max) {
_parent.line._y = max + 2;
_parent.line._visible = true;
} else if (this._y < min) {
_parent.line._y = min - 3;
_parent.line._visible = true;
} else {
_parent.line._visible = false;
}
}
};
this.onRelease = function () {
_dragged = false;
delete this.onEnterFrame;
this.stopDrag();
var k = _parent._object.AnswersNumber();
i = 0;
while (i < k) {
item = eval ("_parent.b" + i);
if ((this.hitTest(item) == true) && (item != this)) {
_global.StartSound("sclick");
_parent._object.ChangeOrder(_parent._object.GetUserOrder(_index), _parent._object.GetUserOrder(item._index));
_parent.UpdateItems();
_parent.line._visible = false;
return(undefined);
}
i++;
}
var min;
var max;
min = 10000;
max = 0;
i = 0;
while (i < k) {
item = eval ("_parent.b" + i);
if (item != this) {
if (min > item._y) {
min = item._y;
}
if (max < (item._y + item._height)) {
max = item._y + item._height;
}
}
i++;
}
if (this._y > max) {
_global.StartSound("sclick");
_parent._object.ChangeOrder(_parent._object.GetUserOrder(_index), _parent._object.AnswersNumber() - 1);
} else if (this._y < min) {
_global.StartSound("sclick");
_parent._object.ChangeOrder(_parent._object.GetUserOrder(_index), 0);
}
_parent.UpdateItems();
_parent.line._visible = false;
};
this.onReleaseOutside = this.onRelease;
}
Instance of Symbol 231 MovieClip "rb" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
_index = -1;
_items = 0;
_lasty = 0;
_object = undefined;
_imgwidth = 0;
_imgheight = 0;
this.AddItems = function (aobject, aimgwidth, aimgheight) {
_object = aobject;
_imgwidth = aimgwidth;
_imgheight = aimgheight;
b._xscale = 100;
b._yscale = 100;
i = 0;
while (i < _object.AnswersNumber()) {
_rbwidth = (_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx;
if (aimgwidth == 0) {
} else if (_lasty < aimgheight) {
_rbwidth = _rbwidth - aimgwidth;
}
AddItem(i, _rbwidth);
i++;
}
Resize();
this._visible = true;
b._xscale = 0;
b._yscale = 0;
};
this.AddItem = function (aindex, awidth) {
_items = _items + 1;
b.duplicateMovieClip("b" + _items, _items + 10);
item = eval ("b" + _items);
item._index = _items;
item.t.text = _object.GetAnswer(aindex);
item._selected = _object.GetResponse(aindex);
item._correct = _object.GetCorrect(aindex);
};
this.Resize = function () {
if (_object == undefined) {
this._visible = false;
this._xscale = 0;
this._xscale = 0;
} else {
this._visible = true;
this._xscale = 100;
this._xscale = 100;
}
_lasty = 0;
i = 1;
while (i <= _items) {
item = eval ("b" + i);
_rbwidth = (_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx;
if (_imgwidth == 0) {
} else if (_lasty < _imgheight) {
_rbwidth = _rbwidth - _imgwidth;
}
if (item != undefined) {
item.bg._width = _rbwidth;
_global.settextformat(item.t, _global.design.afont);
item.t.autoSize = true;
item.t.wordWrap = true;
item.t._width = item.bg._width - _global.rb_dx;
item.t._x = _global.rb_dx;
item._y = _lasty;
item.bg._height = item.t._height;
item.bsel.attachMovie(_global.design.rbstyle + "_rbchecked", "rbcn", 10);
item.bunsel.attachMovie(_global.design.rbstyle + "_rbunchecked", "rbcu", 10);
item.bsel._y = Math.floor((item.t.getTextFormat().size - item.bsel._height) / 2) + 4;
item.bunsel._y = item.bsel._y;
item.mcreview._y = item.bsel._y;
item.bsel._x = 30;
item.bunsel._x = 30;
item.mcreview._x = 5;
_lasty = (_lasty + item._height) + _global.rb_dy;
}
i++;
}
};
this.Items = function () {
return(_items);
};
this.SetSelected = function (aindex) {
_index = aindex;
i = 1;
while (i <= _items) {
item = eval ("b" + i);
if (i != aindex) {
item._selected = false;
}
_object.SetResponse(i - 1, item._selected);
i++;
}
};
}
Instance of Symbol 239 MovieClip "cb" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
_index = -1;
_items = 0;
_lasty = 0;
_object = undefined;
_imgwidth = 0;
_imgheight = 0;
this.AddItems = function (aobject, aimgwidth, aimgheight) {
_object = aobject;
_imgwidth = aimgwidth;
_imgheight = aimgheight;
this._x = 0;
this._y = 0;
b._xscale = 100;
b._yscale = 100;
i = 0;
while (i < _object.AnswersNumber()) {
_rbwidth = (_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx;
if (aimgwidth == 0) {
} else if (_lasty < aimgheight) {
_rbwidth = _rbwidth - aimgwidth;
}
AddItem(i, _rbwidth);
i++;
}
Resize();
b._xscale = 0;
b._yscale = 0;
};
this.AddItem = function (aindex, awidth) {
_items = _items + 1;
b.duplicateMovieClip("b" + _items, _items + 10);
item = eval ("b" + _items);
item._index = _items;
item.t.text = _object.GetAnswer(aindex);
item._selected = _object.GetResponse(aindex);
item._correct = _object.GetCorrect(aindex);
};
this.Resize = function () {
if ((_object == undefined) || (_items == 0)) {
this._visible = false;
this._xscale = 0;
this._xscale = 0;
} else {
this._visible = true;
this._xscale = 100;
this._xscale = 100;
}
_lasty = 0;
i = 1;
while (i <= _items) {
item = eval ("b" + i);
_rbwidth = (_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx;
if (_imgwidth == 0) {
} else if (_lasty < _imgheight) {
_rbwidth = _rbwidth - _imgwidth;
}
if (item != undefined) {
item.bg._width = _rbwidth;
_global.settextformat(item.t, _global.design.afont);
item.t.autoSize = true;
item.t.wordWrap = true;
item.t._width = item.bg._width - _global.rb_dx;
item.t._x = _global.rb_dx;
item._y = _lasty;
item.bg._height = item.t._height;
item.bsel.attachMovie(_global.design.cbstyle + "_cbchecked", "cbcn", 10);
item.bunsel.attachMovie(_global.design.cbstyle + "_cbunchecked", "cbcu", 10);
item.bsel._y = Math.floor((item.t.getTextFormat().size - item.bsel._height) / 2) + 4;
item.bunsel._y = item.bsel._y;
item.mcreview._y = item.bsel._y;
item.bsel._x = 30;
item.bunsel._x = 30;
item.mcreview._x = 5;
_lasty = (_lasty + item._height) + _global.rb_dy;
}
i++;
}
};
this.Items = function () {
return(_items);
};
this.SetSelected = function (aindex) {
item = eval ("b" + aindex);
_object.SetResponse(aindex - 1, item._selected);
};
}
Instance of Symbol 248 MovieClip "ed" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
_object = undefined;
_imgwidth = 0;
this.AddItem = function (aobject, aimgwidth, aimgheight) {
_object = aobject;
_imgwidth = aimgwidth;
e.t.text = _object.answer;
if (_global.review == false) {
Selection.setFocus(e.t);
}
if (_global.review == true) {
edreview._visible = true;
} else {
edreview._visible = false;
}
e._x = _global.rb_dx;
edreview._x = e._x;
_visible = true;
Resize();
};
this.Changed = function () {
_object.SetResponse(e.t.text);
};
this.Resize = function () {
if (_object == undefined) {
this._visible = false;
this._xscale = 0;
this._xscale = 0;
} else {
this._visible = true;
this._xscale = 100;
this._xscale = 100;
}
if (_global.review == true) {
j = _object.answers.length;
var _local3 = ("<b>" + _global.GetText("shortanswerreview")) + "</b><br>";
i = 0;
while (i < j) {
_local3 = ((_local3 + "<li>") + _object.GetResponse(i)) + "</li>";
i++;
}
edreview.t.html = true;
edreview.t.htmlText = _local3;
var _local4;
_local4 = edreview.t.getTextFormat();
_local4.font = _global.design.afont.name;
_local4.color = _global.design.afont.color;
_local4.size = _global.design.afont.size;
edreview.t.setTextFormat(_local4);
edreview.t.wordWrap = true;
edreview.t.autoSize = true;
_local4 = e.t.getTextFormat();
if (_object.UserResponse() == true) {
_local4.color = _global.clgreen;
} else {
_local4.color = _global.clred;
}
e.t.setTextFormat(_local4);
} else {
xx = new Color(e.t);
xx.setRGB(_global.design.afont.color);
}
};
}
Instance of Symbol 251 MovieClip "wb" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
_index = -1;
_items = 0;
_object = undefined;
_lasty = 0;
_objheight = 0;
_dx = 10;
_dy = 5;
dest._visible = false;
var _destcolor = 13421772;
var _normalcolor = 16777215;
this.AddItems = function (aobject, aimgwidth, aimgheight) {
_object = aobject;
_objheight = 0;
_items = 0;
_imgwidth = aimgwidth;
this._visible = true;
b._xscale = 100;
b._yscale = 100;
k = _object.AnswersNumber();
i = 0;
while (i < k) {
AddItem(i, _rbwidth);
i++;
}
AddDest(_rbwidth);
this._x = _global.rb_dx - 10;
this._y = 0;
b._visible = false;
mcreview._visible = false;
Resize();
b._xscale = 0;
b._yscale = 0;
};
this.AddDest = function (awidth) {
item = b.duplicateMovieClip("dest", 10);
item.useHandCursor = false;
};
this.drawback = function (item, aw, ah, acolor) {
item.clear();
item.beginFill(16777215);
item.lineStyle(1, 3355443, 100);
item.moveTo(1, 1);
item.lineTo(aw, 1);
item.lineTo(aw, ah);
item.lineTo(1, ah);
item.lineTo(1, 1);
item.endFill();
item.beginFill(acolor);
item.lineStyle(1, 0, 100);
item.moveTo(0, 0);
item.lineTo(aw - 1, 0);
item.lineTo(aw - 1, ah - 1);
item.lineTo(0, ah - 1);
item.lineTo(0, 0);
item.endFill();
};
this.AddItem = function (aindex, awidth) {
_items = _items + 1;
b.duplicateMovieClip("b" + _items, _items + 10);
item = eval ("b" + _items);
item._index = _items;
item.t.text = _object.GetAnswer(aindex);
};
this.UpdateSelected = function (adrop) {
k = _object.AnswersNumber();
i = 0;
while (i < k) {
j = i + 1;
item = eval ("b" + j);
if (item != adrop) {
_object.SetResponse(i, false);
} else {
_object.SetResponse(i, true);
}
i++;
}
};
this.Resize = function () {
if ((_object == undefined) || (_items == 0)) {
this._visible = false;
this._xscale = 0;
this._xscale = 0;
} else {
this._visible = true;
this._xscale = 100;
this._xscale = 100;
}
_rbwidth = ((_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx) - _imgwidth;
if (_rbwidth > 250) {
_rbwidth = 250;
} else if (_rbwidth < 100) {
_rbwidth = 100;
}
_objheight = 0;
item = dest;
item.t.text = _global.GetText("wordbank");
item.t.wordWrap = true;
item.t._width = _rbwidth - (2 * _dx);
var t = item.t.getTextFormat();
t.font = "Tahoma";
t.color = 16777215 /* 0xFFFFFF */;
t.size = 10;
item.t.setTextFormat(t);
item.t.autoSize = true;
if (item.t._height > _objheight) {
_objheight = item.t._height;
}
i = 0;
while (i < k) {
j = i + 1;
item = eval ("b" + j);
item.t.wordWrap = true;
_global.settextformat(item.t, _global.design.afont);
item.t._width = _rbwidth - (2 * _dx);
item.t.autoSize = true;
if (item.t._height > _objheight) {
_objheight = item.t._height;
}
i++;
}
UpdateItems();
};
this.UpdateItems = function () {
item = dest;
this.drawback(item, item.t._width + (2 * _dx), _objheight + (2 * _dy), _destcolor);
item.t._x = _dx;
item.t._y = (((_objheight + (2 * _dy)) - item.t._height) / 2) - 1;
item.lineStyle(1, 13421772, 100);
item.moveTo(0, (_objheight + (2 * _dy)) + 10);
item.lineTo((item.t._width + (2 * _dx)) + 100, (_objheight + (2 * _dy)) + 10);
item._x = 25;
_lasty = (((_objheight + (2 * _dy)) + 10) + 10) + 20;
k = _object.AnswersNumber();
i = 0;
while (i < k) {
j = i + 1;
item = eval ("b" + j);
item.t.autoSize = false;
item.t._height = _objheight;
item.t._x = _dx;
item.t._y = _dy - 2;
item._y = _lasty;
item._x = 25;
if (_object.GetResponse(i) == false) {
this.drawback(item, item.t._width + (2 * _dx), _objheight + (2 * _dy), _normalcolor);
_lasty = ((_lasty + _objheight) + (2 * _dy)) + 10;
if (_global.review == true) {
if (_object.GetCorrect(i) == true) {
mcreview._visible = true;
mcreview._y = ((item._y + _dx) + ((item.t._height - mcreview._height) / 2)) - 3;
}
}
} else {
item._x = dest._x;
item._y = dest._y;
if (_global.review == true) {
var txtformat;
txtformat = item.t.getTextFormat();
txtformat.color = 16777215 /* 0xFFFFFF */;
item.t.setTextFormat(txtformat);
if (_object.GetCorrect(i) == true) {
this.drawback(item, item.t._width + (2 * _dx), _objheight + (2 * _dy), _global.clgreen);
mcreview._visible = true;
mcreview._y = ((item._y + _dx) + ((item.t._height - mcreview._height) / 2)) - 3;
} else {
this.drawback(item, item.t._width + (2 * _dx), _objheight + (2 * _dy), _global.clred);
}
} else {
this.drawback(item, item.t._width + (2 * _dx), _objheight + (2 * _dy), _destcolor);
}
}
item._visible = true;
i++;
}
};
}
Instance of Symbol 258 MovieClip "mdd" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
function UpdateItems() {
j = _object.AnswersNumber();
_lasty = 0;
i = 0;
while (i < j) {
item = eval ("m" + i);
item.t.autoSize = false;
this.drawbackleft(item, (item.t._width + (2 * _dx3)) + mw, _maxheight + 4, _destcolor, _rw + _dx1);
item.t._x = (_rw + _dx1) + _dx3;
item.t._y = 2 + Math.floor((_maxheight - item.t._height) / 2);
item.r._visible = _global.review;
item.r.autoSize = "right";
item.r._y = 2 + Math.floor((_maxheight - item.r._height) / 2);
item.r._x = _rw - item.r.textWidth;
item._y = _lasty;
_lasty = (_lasty + _maxheight) + _dy;
item = eval ("a" + i);
var txtf;
if (_global.review == true) {
txtf = item.t.getTextFormat();
txtf.color = 16777215 /* 0xFFFFFF */;
item.t.setTextFormat(txtf);
}
item.t.autoSize = false;
item.t._x = mw + _dx3;
item.t._y = 2 + Math.floor((_maxheight - item.t._height) / 2);
item.r._x = ((item.t._width + (2 * _dx3)) + mw) + _dx1;
item.r._y = 2 + Math.floor((_maxheight - item.r._height) / 2);
var xx;
if (_global.review == true) {
item.r._visible = true;
if (_object.GetCorrect(item._index) == true) {
xx = clgreen;
} else {
xx = clred;
}
} else {
item.r._visible = false;
xx = _normalcolor;
}
txtf = item.r.getTextFormat();
txtf.color = xx;
item.r.setTextFormat(txtf);
this.drawbackright(item, (((item.t._width + (2 * _dx3)) + mw) + _rw) + _dx1, _maxheight + 4, xx, _rw + _dx1, _object.GetAnswerMatchIndex(i));
item._y = _object.GetOrder(i) * (_maxheight + _dy);
if (_object.GetAnswerMatchIndex(i) >= 0) {
item._x = (((_rbwidth - _dx2) / 2) - mw) - 3;
} else {
item._x = ((_rbwidth - _dx2) / 2) + _dx2;
}
i++;
}
}
var _index = -1;
var _items = 0;
var _lasty = 0;
var _object = undefined;
var _rbwidth = 280;
var _normalcolor = 16777215;
var _destcolor = 13421772;
var _minheight = 30;
var _dx1 = 10;
var _dx2 = 30;
var _dx3 = 5;
var _rw = 30;
var _dy = 20;
var mh = 10;
var mw = 6;
var _maxheight;
var _imgwidth;
this.AddItems = function (aobject, aimgwidth, aimgheight) {
_object = aobject;
_imgwidth = aimgwidth;
this._x = 5;
this._y = 0;
_maxheight = _minheight;
i = 0;
while (i < _object.AnswersNumber()) {
AddItem(i);
i++;
}
Resize();
m._visible = false;
a._visible = false;
this._visible = true;
};
this.drawbackleft = function (item, aw, ah, acolor, adx) {
item.clear();
item.beginFill(16777215);
item.lineStyle(1, 3355443, 100);
item.moveTo(adx + 1, 1);
item.lineTo(aw + adx, 1);
item.lineTo(aw + adx, 1 + mh);
item.lineTo((aw + adx) - mw, 1 + mh);
item.lineTo((aw + adx) - mw, ah - mh);
item.lineTo(aw + adx, ah - mh);
item.lineTo(aw + adx, ah);
item.lineTo(adx + 1, ah);
item.lineTo(adx + 1, 1);
item.endFill();
item.beginFill(acolor);
item.lineStyle(1, 0, 100);
item.moveTo(adx, 0);
item.lineTo((aw + adx) - 1, 0);
item.lineTo((aw + adx) - 1, mh);
item.lineTo(((aw + adx) - mw) - 1, mh);
item.lineTo(((aw + adx) - mw) - 1, (ah - mh) - 1);
item.lineTo((aw + adx) - 1, (ah - mh) - 1);
item.lineTo((aw + adx) - 1, ah - 1);
item.lineTo(adx, ah - 1);
item.lineTo(adx, 0);
item.endFill();
};
this.drawbackright = function (item, aw, ah, acolor, adx, aconnect) {
item.clear();
item.beginFill(16777215);
item.lineStyle(1, 3355443, 100);
item.moveTo(mw + 1, 1);
item.lineTo(aw - adx, 1);
item.lineTo(aw - adx, ah);
item.lineTo(mw + 1, ah);
if (aconnect >= 0) {
item.lineTo(mw + 1, (ah - mh) - 1);
item.lineTo(1, (ah - mh) - 1);
} else {
item.lineTo(mw + 1, ah - mh);
item.lineTo(1, ah - mh);
}
item.lineTo(1, 1 + mh);
item.lineTo(mw + 1, 1 + mh);
item.lineTo(mw + 1, 1);
item.endFill();
item.beginFill(acolor);
item.lineStyle(1, 0, 100);
item.moveTo(mw, 0);
item.lineTo((aw - adx) - 1, 0);
item.lineTo((aw - adx) - 1, ah - 1);
item.lineTo(mw, ah - 1);
item.lineTo(mw, (ah - mh) - 1);
item.lineTo(0, (ah - mh) - 1);
item.lineTo(0, mh);
item.lineTo(mw, mh);
item.lineTo(mw, 0);
item.endFill();
};
this.AddItem = function (aindex) {
var _local1 = m.duplicateMovieClip("m" + _items, _items + 10);
_local1._index = _items;
_local1.t.text = _object.GetMatch(aindex);
_local1.r.text = _items + 1;
_local1 = a.duplicateMovieClip("a" + _items, _items + 100);
_local1._index = _items;
_local1.t.text = _object.GetAnswer(aindex);
_local1.r.text = _object.GetAnswerMatchOrder(aindex) + 1;
_items = _items + 1;
};
this.Resize = function () {
if ((_object == undefined) || (_items == 0)) {
this._visible = false;
this._xscale = 0;
this._xscale = 0;
} else {
this._visible = true;
this._xscale = 100;
this._xscale = 100;
}
_rbwidth = ((_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx) - _imgwidth;
_rbwidth = _rbwidth - 10;
_maxheight = _minheight;
j = _object.AnswersNumber();
i = 0;
while (i < j) {
item = eval ("m" + i);
item.t._width = (((Math.floor((_rbwidth - _dx2) / 2) - _rw) - _dx1) - mw) - (2 * _dx3);
_global.settextformat(item.t, _global.design.afont);
item.t.wordWrap = true;
item.t.autoSize = true;
item.r._width = _rw;
_global.settextformat(item.r, _global.design.afont);
item.r.wordWrap = false;
item.r.autoSize = "right";
if (_maxheight < item.t._height) {
_maxheight = item.t._height;
}
var item = eval ("a" + i);
item.t._width = (((Math.floor((_rbwidth - _dx2) / 2) - _rw) - _dx1) - mw) - (2 * _dx3);
_global.settextformat(item.t, _global.design.afont);
item.t.wordWrap = true;
item.t.autoSize = true;
item.r._width = _rw;
_global.settextformat(item.r, _global.design.afont);
item.r.wordWrap = false;
item.r.autoSize = true;
if (_maxheight < item.t._height) {
_maxheight = item.t._height;
}
i++;
}
UpdateItems();
};
this.HitMatchOrder = function (aobject) {
j = _object.AnswersNumber();
i = 0;
while (i < j) {
item = eval ("m" + i);
if (aobject.hitTest(item) == true) {
return(i);
}
i++;
}
return(-1);
};
this.MoveAnswer = function (aindex, neworder) {
var _local4;
var _local5;
var _local1;
_local1 = _object.GetIndexFromOrder(neworder);
_object.SetOrder(_local1, _object.GetOrder(aindex));
_object.SetOrder(aindex, neworder);
_object.SetAnswerMatchIndex(_local1, -1);
_local1 = _object.GetMatchIndex(neworder);
_object.SetAnswerMatchIndex(aindex, _local1);
};
}
Instance of Symbol 266 MovieClip "cz" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
var width = _width;
var height = _height;
_visible = false;
click._visible = false;
_object = undefined;
loadimg = function (aobject) {
var _local6;
var _local5;
var _local4;
_object = aobject;
mcimg.attachMovie(_object.GetImagebg(), "img", 10);
mcimg.img._x = 0;
mcimg.img._y = 0;
this._x = 0;
this._y = 0;
if (_object.scaled == true) {
if ((mcimg.img._width > _global.scroll_w) || (mcimg.img._height >= _global.scroll_h)) {
_local6 = (_global.scroll_w - 10) / mcimg.img._width;
_local5 = (_global.scroll_h - 10) / mcimg.img._height;
_local4 = _local6;
if (_local5 < _local4) {
_local4 = _local5;
}
mcimg.img._xscale = _local4 * 100;
mcimg.img._yscale = _local4 * 100;
_object.scale = _local4;
}
}
r._visible = _global.review;
if (_global.review == true) {
r._width = (_object.right - _object.left) * _object.scale;
r._height = (_object.bottom - _object.top) * _object.scale;
r._x = _object.left * _object.scale;
r._y = _object.top * _object.scale;
click._x = _object.userx;
click._y = _object.usery;
click._visible = true;
} else if (_object.IsAnswered() == true) {
click._x = _object.userx;
click._y = _object.usery;
click._visible = true;
} else {
click._visible = false;
}
_visible = true;
_parent._parent.Update();
};
onRelease = function () {
_global.StartSound("sclick");
click._x = _xmouse;
click._y = _ymouse;
click._visible = true;
_object.SetResponse(_xmouse, _ymouse);
};
}
Instance of Symbol 273 MovieClip "odd" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
_index = -1;
_object = undefined;
var _lasty = 0;
var _imgwidth = 0;
this.DrawLine = function () {
var _local3 = (_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx;
if (_imgwidth == 0) {
} else {
_local3 = _local3 - _imgwidth;
}
line.clear();
line.lineStyle(1, 0, 100);
line.beginFill(0);
line.moveTo(0, -4);
line.lineTo(4, 0);
line.lineTo(0, 4);
line.lineTo(0, -4);
line.endFill();
line.moveTo(4, 0);
line.lineTo(_local3 - 4, 0);
line.beginFill(0);
line.moveTo(_local3, -4);
line.lineTo(_local3, 4);
line.lineTo(_local3 - 4, 0);
line.lineTo(_local3, -4);
line.endFill();
};
this.AddItems = function (aobject, aimgwidth, aimgheight) {
_object = aobject;
_imgwidth = aimgwidth;
this._visible = true;
b._xscale = 100;
b._yscale = 100;
k = _object.AnswersNumber();
i = 0;
while (i < k) {
AddItem(i);
i++;
}
this._x = 0;
this._y = 0;
this.line._visible = false;
Resize();
b._visible = false;
crt._visible = false;
b._xscale = 0;
b._yscale = 0;
};
this.Resize = function () {
if (_object == undefined) {
this._visible = false;
this._xscale = 0;
this._xscale = 0;
} else {
this._visible = true;
this._xscale = 100;
this._xscale = 100;
}
var k = _object.AnswersNumber();
var _rbwidth = ((_global.scroll_w - _parent._parent.VTrack._width) - _global.imgview_dx);
if (_imgwidth == 0) {
} else {
_rbwidth = _rbwidth - _imgwidth;
}
_rbwidth = _rbwidth - _global.rb_dx;
i = 0;
while (i < k) {
item = eval ("b" + i);
item.t.autoSize = false;
item.t._width = _rbwidth;
_global.settextformat(item.t, _global.design.afont);
item.t.wordWrap = true;
item.t.autoSize = true;
item.bg._width = item.t._width;
item.bg._height = item.t._height;
itemcrt = eval ("crt" + i);
itemcrt.t._width = _global.rb_dx;
_global.settextformat(itemcrt.t, _global.design.afont);
var txtf;
txtf = itemcrt.t.getTextFormat();
if (_global.review == false) {
txtf.color = 0;
} else {
var m;
m = _object.GetIndexAtOrder(i);
if (_object.GetCorrectOrder(m) == _object.GetUserOrder(m)) {
txtf.color = _global.clgreen;
} else {
txtf.color = _global.clred;
}
}
txtf.bold = true;
txtf.italic = false;
itemcrt.t.setTextFormat(txtf);
itemcrt.t.autoSize = "right";
itemcrt.t.wordWrap = false;
itemcrt.t._x = (_global.rb_dx - itemcrt.t._width) - 5;
i++;
}
UpdateItems();
DrawLine();
};
this.AddItem = function (aindex) {
var _local3 = b.duplicateMovieClip("b" + aindex, aindex + 100);
_local3._index = aindex;
_local3.t.text = _object.GetAnswer(aindex);
var _local4 = crt.duplicateMovieClip("crt" + aindex, aindex + 10);
if (_global.review == false) {
_local4.t.text = (aindex + 1) + ".";
} else {
_local4.t.text = (_object.GetCorrectOrder(_object.GetIndexAtOrder(aindex)) + 1) + ".";
}
};
this.UpdateSelected = function (adrop) {
k = _object.AnswersNumber();
i = 0;
while (i < k) {
j = i + 1;
item = eval ("b" + j);
if (item != adrop) {
_object.SetResponse(i, false);
} else {
_object.SetResponse(i, true);
}
i++;
}
};
this.DraggedItem = function () {
var k = _object.AnswersNumber();
i = 0;
while (i < k) {
item = eval ("b" + i);
if (item._dragged == true) {
return(i);
}
i++;
}
return(-1);
};
this.UpdateItems = function () {
_lasty = _global.rb_dy + 2;
var k = _object.AnswersNumber();
i = 0;
while (i < k) {
j = _object.GetIndexAtOrder(i);
item = eval ("b" + j);
item._y = _lasty;
item._x = _global.rb_dx;
itemcrt = eval ("crt" + i);
itemcrt._y = item._y;
itemcrt._x = 0;
itemcrt.clear();
itemcrt.lineStyle(1, 13421772, 80);
itemcrt.moveTo(0, item.t._height + 2);
itemcrt.lineTo(_global.rb_dx + item.t._width, item.t._height + 2);
_lasty = (_lasty + item._height) + _global.rb_dy;
i++;
}
};
}
Instance of Symbol 279 MovieClip "imgview" in Symbol 280 MovieClip Frame 1
onClipEvent (load) {
_visible = false;
this.loadimage = function () {
var width = 200;
var _local6 = 250;
mcimg.attachMovie(_img, "img", 10);
if ((mcimg.img._width > width) || (mcimg.img._height > _local6)) {
var _local7;
var _local5;
var _local4;
_local7 = (100 * width) / mcimg.img._width;
_local5 = (100 * _local6) / mcimg.img._height;
_local4 = _local7;
if (_local5 < _local4) {
_local4 = _local5;
}
mcimg.img._xscale = _local4;
mcimg.img._yscale = _local4;
this.onPress = function () {
mchint._visible = false;
_parent._parent._parent.enlarge.showimage(_img);
};
mchint._visible = false;
this.onRollOver = function () {
mchint._visible = true;
mchint.t.text = _global.GetText("imagehint");
_global.settextformat(mchint.t, _global.design.afont);
mchint.t._width = width;
mchint.t.wordWrap = true;
mchint.t.autoSize = true;
mchint.back._width = mchint.t._width;
mchint.back._height = mchint.t._height;
var _local2;
_local2 = new Color(mchint.back);
_local2.setRGB(_global.design.rollovercolor);
};
this.onRollOut = function () {
mchint._visible = false;
};
} else {
mchint._visible = false;
delete this.onRollOver;
delete this.onRollOut;
}
mcback._width = mcimg.img._width;
mcback._height = mcimg.img._height;
this._x = this._x + (width - mcback._width);
_visible = true;
};
}
Symbol 282 MovieClip Frame 1
maskedView._x = 0;
maskedView._y = 0;
Instance of Symbol 280 MovieClip "contentMain" in Symbol 282 MovieClip Frame 1
onClipEvent (load) {
Resize = function () {
rb.Resize();
cb.Resize();
odd.Resize();
wb.Resize();
mdd.Resize();
ed.Resize();
};
}
Instance of Symbol 281 MovieClip "maskedView" in Symbol 282 MovieClip Frame 1
onClipEvent (load) {
this.useHandCursor = false;
}
onClipEvent (enterFrame) {
if ((_global.review == true) || (_global.qreview == true)) {
if (this.onRollOver == undefined) {
this.onRollOver = function () {
};
}
} else if (this.onRollOver != undefined) {
delete this.onRollOver;
}
}
Instance of Symbol 114 MovieClip "VUp" in Symbol 282 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 115 MovieClip "VDown" in Symbol 282 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 120 MovieClip "HLeft" in Symbol 282 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 123 MovieClip "HRight" in Symbol 282 MovieClip Frame 1
onClipEvent (load) {
this.stop();
}
on (rollOver) {
this.gotoAndStop(2);
}
on (release, rollOut) {
this.gotoAndStop(1);
}
on (press) {
this.gotoAndStop(3);
}
Instance of Symbol 318 MovieClip "header" in Symbol 319 MovieClip Frame 1
onClipEvent (load) {
var bx;
var by;
var level;
var dx;
var bx;
var w;
var h;
var i;
var pagecount;
var headery;
var clred;
var clgreen;
var clblack;
var clwhite;
var clgray;
clgreen = _global.clgreen;
clred = _global.clred;
clblack = 0;
clgray = 13421772 /* 0xCCCCCC */;
clwhite = 16777215 /* 0xFFFFFF */;
i = 0;
pagecount = 1;
bx = 10;
var gutter = 2;
var c1;
var c2;
var c3;
var c4;
c1 = 30;
c3 = 65;
c4 = 45;
this.drawArc = function (x, y, radius, arc, startAngle, yRadius) {
if (arguments.length < 5) {
return(undefined);
}
if (yRadius == undefined) {
yRadius = radius;
}
var _local17;
var _local4;
var _local3;
var _local6;
var _local15;
var _local9;
var _local8;
var _local11;
var _local12;
var _local14;
var _local13;
if (Math.abs(arc) > 360) {
arc = 360;
}
_local15 = Math.ceil(Math.abs(arc) / 45);
_local17 = arc / _local15;
_local4 = (-(_local17 / 180)) * Math.PI;
_local3 = (-(startAngle / 180)) * Math.PI;
_local9 = x - (Math.cos(_local3) * radius);
_local8 = y - (Math.sin(_local3) * yRadius);
if (_local15 > 0) {
var _local5 = 0;
while (_local5 < _local15) {
_local3 = _local3 + _local4;
_local6 = _local3 - (_local4 / 2);
_local11 = _local9 + (Math.cos(_local3) * radius);
_local12 = _local8 + (Math.sin(_local3) * yRadius);
_local14 = _local9 + (Math.cos(_local6) * (radius / Math.cos(_local4 / 2)));
_local13 = _local8 + (Math.sin(_local6) * (yRadius / Math.cos(_local4 / 2)));
this.curveTo(_local14, _local13, _local11, _local12);
_local5++;
}
}
return({x:_local11, y:_local12});
};
this.addrb = function (x, aobject, isrb) {
var _local3;
_local3 = 0;
while (_local3 < aobject.answers.length) {
item = a.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.GetAnswer(_local3);
var _local5 = item.t.getTextFormat();
if (aobject.GetResponse(_local3) == true) {
if (aobject.GetCorrect(_local3) == true) {
_local5.color = clgreen;
} else {
_local5.color = clred;
}
} else {
_local5.color = clblack;
}
item.t.setTextFormat(_local5);
item._x = x + 25;
item._y = by;
item.t._width = c2 - 25;
item.t.wordWrap = true;
item.t.autoSize = true;
if (aobject.GetCorrect(_local3) == true) {
itemr = this.createEmptyMovieClip("ob" + level, level);
level++;
itemr.lineStyle(0, clwhite, 100);
itemr.beginFill(clgreen, 100);
itemr.moveTo(x + 2, by + 3);
itemr.lineTo(x + 10, by + 9);
itemr.lineTo(x + 2, by + 15);
itemr.lineTo(x + 2, by + 3);
itemr.endFill();
}
itemc = this.createEmptyMovieClip("ob" + level, level);
level++;
itemc.lineStyle(1, 0, 100);
if (isrb == true) {
itemc.moveTo(x + 22, by + 9);
itemc.drawArc = this.drawArc;
itemc.drawArc(x + 22, by + 9, 3, 360, 0, 3);
if (aobject.GetResponse(_local3) == true) {
itemc.beginFill(0, 100);
itemc.moveTo(x + 20, by + 9);
itemc.drawArc(x + 20, by + 9, 1, 360, 0, 1);
itemc.endFill();
}
} else {
itemc.moveTo(x + 22, by + 6);
itemc.lineTo(x + 22, by + 12);
itemc.lineTo(x + 16, by + 12);
itemc.lineTo(x + 16, by + 6);
itemc.lineTo(x + 22, by + 6);
if (aobject.GetResponse(_local3) == true) {
itemc.beginFill(0, 100);
itemc.moveTo(x + 20, by + 8);
itemc.lineTo(x + 20, by + 10);
itemc.lineTo(x + 18, by + 10);
itemc.lineTo(x + 18, by + 8);
itemc.lineTo(x + 20, by + 8);
itemc.endFill();
}
}
by = (by + item._height) - (2 * gutter);
item.t.autoSize = false;
_local3++;
}
};
this.added = function (x, aobject) {
var _local5;
_local5 = clblack;
if (aobject.answer != "") {
item = a.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.answer;
item._x = x + 25;
item._y = by;
item.t._width = c2 - 25;
item.t.wordWrap = true;
item.t.autoSize = true;
if (aobject.UserResponse() == true) {
_local5 = clgreen;
} else {
_local5 = clred;
}
var _local6 = item.t.getTextFormat();
_local6.color = _local5;
item.t.setTextFormat(_local6);
by = (by + item._height) - (2 * gutter);
item.t.autoSize = false;
} else {
by = by + 10;
}
itemc = this.createEmptyMovieClip("ob" + level, level);
level++;
itemc.lineStyle(1, clgray, 100);
itemc.moveTo(x + 25, by);
itemc.lineTo((x + 25) + ((c2 - 25) / 2), by);
by = by + 2;
var _local3;
_local3 = 0;
while (_local3 < aobject.answers.length) {
item = a.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.GetResponse(_local3);
item._x = x + 25;
item._y = by;
item.t._width = c2 - 25;
item.t.wordWrap = true;
item.t.autoSize = true;
itemc = this.createEmptyMovieClip("ob" + level, level);
level++;
itemc.lineStyle(1, 0, 100);
itemc.beginFill(0, 100);
itemc.moveTo(x + 19, by + 8);
itemc.lineTo(x + 20, by + 9);
itemc.lineTo(x + 19, by + 10);
itemc.lineTo(x + 18, by + 9);
itemc.lineTo(x + 19, by + 8);
itemc.endFill();
by = (by + item._height) - (2 * gutter);
item.t.autoSize = false;
_local3++;
}
};
this.addwb = function (x, aobject) {
var _local5;
var _local4;
_local5 = clblack;
if (aobject.IsAnswered() == true) {
item = a.duplicateMovieClip("ob" + level, level);
level++;
_local4 = 0;
while (_local4 < aobject.answers.length) {
if (aobject.GetResponse(_local4) == true) {
item.t.text = aobject.GetAnswer(_local4);
break;
}
_local4++;
}
item._x = x + 25;
item._y = by;
item.t._width = c2 - 25;
item.t.wordWrap = true;
item.t.autoSize = true;
if (aobject.UserResponse() == true) {
_local5 = clgreen;
} else {
_local5 = clred;
}
var _local6 = item.t.getTextFormat();
_local6.color = _local5;
item.t.setTextFormat(_local6);
if (aobject.UserResponse() == true) {
itemr = this.createEmptyMovieClip("ob" + level, level);
level++;
itemr.lineStyle(0, clwhite, 100);
itemr.beginFill(clgreen, 100);
itemr.moveTo(x + 2, by + 3);
itemr.lineTo(x + 10, by + 9);
itemr.lineTo(x + 2, by + 15);
itemr.lineTo(x + 2, by + 3);
itemr.endFill();
}
by = (by + item._height) - (2 * gutter);
item.t.autoSize = false;
} else {
by = by + 10;
}
itemc = this.createEmptyMovieClip("ob" + level, level);
level++;
itemc.lineStyle(1, clgray, 100);
itemc.moveTo(x + 25, by);
itemc.lineTo((x + 25) + ((c2 - 25) / 2), by);
by = by + 2;
_local4 = 0;
while (_local4 < aobject.answers.length) {
if (aobject.GetResponse(_local4) == false) {
item = a.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.GetAnswer(_local4);
item._x = x + 25;
item._y = by;
item.t._width = c2 - 25;
item.t.wordWrap = true;
item.t.autoSize = true;
itemc = this.createEmptyMovieClip("ob" + level, level);
level++;
itemc.lineStyle(1, 0, 100);
itemc.beginFill(0, 100);
itemc.moveTo(x + 20, by + 8);
itemc.lineTo(x + 20, by + 10);
itemc.lineTo(x + 18, by + 10);
itemc.lineTo(x + 18, by + 8);
itemc.lineTo(x + 20, by + 8);
itemc.endFill();
if (aobject.GetCorrect(_local4) == true) {
itemr = this.createEmptyMovieClip("ob" + level, level);
level++;
itemr.lineStyle(0, clwhite, 100);
itemr.beginFill(clgreen, 100);
itemr.moveTo(x + 2, by + 3);
itemr.lineTo(x + 10, by + 9);
itemr.lineTo(x + 2, by + 15);
itemr.lineTo(x + 2, by + 3);
itemr.endFill();
}
by = (by + item._height) - (2 * gutter);
item.t.autoSize = false;
}
_local4++;
}
};
this.addmdd = function (x, aobject) {
var _local5;
var _local7;
var _local2;
_local5 = clblack;
var _local4;
_local4 = 0;
while (_local4 < aobject.answers.length) {
item = nomdd.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = _local4 + 1;
item.t._width = item.t.textWidth + (2 * gutter);
item.t._height = item.t.textHeight + (2 * gutter);
item._x = (x + 2) + ((20 - item._width) / 2);
item._y = by;
item = a.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.GetMatch(_local4);
item._x = x + 25;
item._y = by;
item.t._width = ((c2 - 50) - 10) / 2;
item.t.wordWrap = true;
item.t.autoSize = true;
item.t.autoSize = false;
_local7 = (by + item._height) - (2 * gutter);
_local2 = 0;
while (_local4 < aobject.answers.length) {
if (aobject.GetOrder(_local2) == _local4) {
break;
}
_local2++;
}
item = nomdd.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.GetAnswerMatchOrder(_local2) + 1;
item.t._width = item.t.textWidth + (2 * gutter);
item.t._height = item.t.textHeight + (2 * gutter);
item._x = (((x + c2) - 25) + 2) + ((20 - item._width) / 2);
item._y = by;
if (aobject.GetAnswerMatchIndex(_local2) >= 0) {
xt = item.t.getTextFormat();
_local5 = clblack;
if (aobject.GetCorrect(_local2) == true) {
_local5 = clgreen;
} else {
_local5 = clred;
}
xt.color = _local5;
item.t.setTextFormat(xt);
}
item = a.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.GetAnswer(_local2);
item._x = ((x + 25) + (((c2 - 50) - 10) / 2)) + 10;
item._y = by;
item.t._width = ((c2 - 50) - 10) / 2;
item.t.wordWrap = true;
item.t.autoSize = true;
item.t.autoSize = false;
if (aobject.GetAnswerMatchIndex(_local2) >= 0) {
xt = item.t.getTextFormat();
_local5 = clblack;
if (aobject.GetCorrect(_local2) == true) {
_local5 = clgreen;
} else {
_local5 = clred;
}
xt.color = _local5;
item.t.setTextFormat(xt);
}
by2 = (by + item._height) - (2 * gutter);
by = _local7;
if (by2 > _local7) {
by = by2;
}
iteml = this.createEmptyMovieClip("ob" + level, level);
level++;
iteml.lineStyle(1, clgray, 100);
iteml.moveTo(x + 5, by + 1);
iteml.lineTo((x + c2) - 5, by + 1);
by = by + 3;
_local4++;
}
};
this.addodd = function (x, aobject) {
var _local4;
var _local7;
var _local8;
var _local3;
_local4 = clblack;
var _local5;
_local5 = 0;
while (_local5 < aobject.answers.length) {
_local3 = aobject.GetIndexAtOrder(_local5);
itemcrt = nomdd.duplicateMovieClip("ob" + level, level);
level++;
itemcrt.t.text = (aobject.GetCorrectOrder(_local3) + 1) + ".";
xt = item.t.getTextFormat();
_local4 = clblack;
if (aobject.GetUserOrder(_local3) == aobject.GetCorrectOrder(_local3)) {
_local4 = clgreen;
} else {
_local4 = clred;
}
xt.color = _local4;
xt.bold = true;
itemcrt.t.setTextFormat(xt);
itemcrt.t.autoSize = "right";
itemcrt.t._width = itemcrt.t.textWidth + (2 * gutter);
itemcrt.t._height = itemcrt.t.textHeight + (2 * gutter);
itemcrt.t._x = 0;
itemcrt._x = (((x + 2) + 25) - 5) - itemcrt.t._width;
itemcrt._y = by;
itemcrt.t.autoSize = false;
item = a.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = aobject.GetAnswer(_local3);
item._x = x + 25;
item._y = by;
item.t._width = ((c2 - 50) - 10) / 2;
item.t.wordWrap = true;
item.t.autoSize = true;
_local7 = (by + item._height) - (2 * gutter);
item.t.autoSize = false;
by = _local7;
iteml = this.createEmptyMovieClip("ob" + level, level);
level++;
iteml.lineStyle(1, clgray, 100);
iteml.moveTo(x + 5, by + 1);
iteml.lineTo((x + c2) - 5, by + 1);
by = by + 3;
_local5++;
}
};
this.addcz = function (x, aobject) {
var _local11;
var _local13;
var _local5;
var _local4;
var _local8;
var _local7;
item = this.attachMovie(_global.quizItems[i].GetImagebg(), "ob" + level, level);
level++;
if ((item._width > (c2 - 25)) || (item._height > 200)) {
_local11 = (c2 - 25) / item._width;
_local13 = 200 / item._height;
if (_local13 < _local11) {
_local11 = _local13;
}
item._xscale = 100 * _local11;
item._yscale = 100 * _local11;
}
item._x = x + 25;
item._y = by;
by = by + item._height;
itemr = this.createEmptyMovieClip("ob" + level, level);
level++;
_local5 = item._x + ((_global.quizItems[i].left * item._xscale) / 100);
_local8 = item._x + ((_global.quizItems[i].right * item._xscale) / 100);
_local4 = item._y + ((_global.quizItems[i].top * item._xscale) / 100);
_local7 = item._y + ((_global.quizItems[i].bottom * item._xscale) / 100);
itemr.lineStyle(1, clgreen, 100);
itemr.moveTo(_local5, _local4);
itemr.lineTo(_local8, _local4);
itemr.lineTo(_local8, _local7);
itemr.lineTo(_local5, _local7);
itemr.lineTo(_local5, _local4);
var _local3;
var _local6;
var _local15;
_local3 = 10;
while (_local3 < (((_local8 - _local5) + _local7) - _local4)) {
if ((_local5 + _local3) < _local8) {
itemr.moveTo(_local5 + _local3, _local4);
if ((_local4 + _local3) < _local7) {
itemr.lineTo(_local5, _local4 + _local3);
} else {
_local6 = (_local4 + _local3) - _local7;
itemr.lineTo(_local5 + _local6, (_local4 + _local3) - _local6);
}
} else {
_local6 = (_local5 + _local3) - _local8;
itemr.moveTo(_local8, _local4 + _local6);
if ((_local4 + _local3) < _local7) {
itemr.lineTo(_local5, _local4 + _local3);
} else {
_local6 = (_local4 + _local3) - _local7;
itemr.lineTo(_local5 + _local6, (_local4 + _local3) - _local6);
}
}
_local3 = _local3 + 10;
}
if (_global.quizItems[i].IsAnswered() == true) {
var _local10;
var _local9;
var _local12;
_local10 = _global.quizItems[i].userx / _global.quizItems[i].scale;
_local10 = item._x + ((_local10 * item._xscale) / 100);
_local9 = _global.quizItems[i].usery / _global.quizItems[i].scale;
_local9 = item._y + ((_local9 * item._xscale) / 100);
if (_global.quizItems[i].UserResponse() == true) {
_local12 = clgreen;
} else {
_local12 = clred;
}
itemt = this.createEmptyMovieClip("ob" + level, level);
level++;
itemt.lineStyle(1, _local12, 100);
itemt.drawArc = this.drawArc;
itemt.moveTo(_local10 + 1, _local9);
itemt.beginFill(_local12, 100);
itemt.drawArc(_local10 + 1, _local9 + 0, 1, 360, 0, 1);
itemt.endFill();
itemt.moveTo(_local10 + 3, _local9);
itemt.drawArc(_local10 + 3, _local9 + 0, 3, 360, 0, 3);
itemt.moveTo(_local10 + 5, _local9);
itemt.lineTo(_local10 + 3, _local9);
itemt.moveTo(_local10 - 5, _local9);
itemt.lineTo(_local10 - 3, _local9);
itemt.moveTo(_local10, _local9 + 5);
itemt.lineTo(_local10, _local9 + 3);
itemt.moveTo(_local10, _local9 - 5);
itemt.lineTo(_local10, _local9 - 3);
}
};
this.Showheader = function () {
lineStyle(1, clwhite, 100);
moveTo(0, 0);
lineTo(w, 0);
title._x = dx + bx;
title._y = dy;
title.text = _parent._parent.vtitle;
title._width = title.textWidth + (2 * gutter);
title._height = title.textHeight + (2 * gutter);
if (_global.passed == true) {
status.text = _global.GetText("passedprint");
} else {
status.text = _global.GetText("failedprint");
}
status._width = status.textWidth + (2 * gutter);
status._height = status.textHeight + (2 * gutter);
status._x = (w - bx) - status._width;
status._y = dy;
back._x = dx;
back._y = dy;
back._width = w - dx;
back._height = title._height;
backcolor = new Color("back");
if (_global.passed == true) {
backcolor.setRGB(clgreen);
} else {
backcolor.setRGB(clred);
}
userl._x = title._x;
userl._y = (back._y + back._height) + 1;
userl.text = _global.GetText("userprint");
userl._width = userl.textWidth + (2 * gutter);
userl._height = userl.textHeight + (2 * gutter);
datel._x = userl._x;
datel._y = ((userl._y + userl._height) + 1) - (3 * gutter);
datel.text = _global.GetText("dateprint");
datel._width = datel.textWidth + (2 * gutter);
datel._height = datel.textHeight + (2 * gutter);
elapsedl._y = ((datel._y + datel._height) + 1) - (3 * gutter);
elapsedl._x = dx + bx;
elapsedl.text = _global.GetText("elapsedprint");
elapsedl._width = elapsedl.textWidth + (2 * gutter);
elapsedl._height = elapsedl.textHeight + (2 * gutter);
maxx = userl._x + userl._width;
if (maxx < (datel._x + datel._width)) {
maxx = datel._x + datel._width;
}
if (maxx < (elapsedl._x + elapsedl._width)) {
maxx = elapsedl._x + elapsedl._width;
}
maxx = maxx + 30;
userd._y = userl._y;
userd._x = maxx;
userd.text = ": " + _global.userid;
userd._width = userd.textWidth + (2 * gutter);
userd._height = userd.textHeight + (2 * gutter);
dated._y = datel._y;
dated._x = maxx;
myDate = new Date();
dd = myDate.getDate();
mm = myDate.getMonth();
yyyy = myDate.getFullYear();
switch (mm) {
case 0 :
mm = _global.GetText("month01print");
break;
case 1 :
mm = _global.GetText("month02print");
break;
case 2 :
mm = _global.GetText("month03print");
break;
case 3 :
mm = _global.GetText("month04print");
break;
case 4 :
mm = _global.GetText("month05print");
break;
case 5 :
mm = _global.GetText("month06print");
break;
case 6 :
mm = _global.GetText("month07print");
break;
case 7 :
mm = _global.GetText("month08print");
break;
case 8 :
mm = _global.GetText("month09print");
break;
case 9 :
mm = _global.GetText("month10print");
break;
case 10 :
mm = _global.GetText("month11print");
break;
case 11 :
mm = _global.GetText("month12print");
}
dated.text = ((((": " + mm) + " ") + dd) + ", ") + yyyy;
dated._width = (dated.textWidth + (2 * gutter)) + 5;
dated._height = dated.textHeight + (2 * gutter);
elapsedd._y = elapsedl._y;
elapsedd._x = maxx;
elapsedd.text = ": " + _global.FormatTime(_global.timeelapsed);
elapsedd._width = elapsedd.textWidth + (2 * gutter);
elapsedd._height = elapsedd.textHeight + (2 * gutter);
usersd.text = (((((": " + _global.userscore) + " % ( ") + _global.userpoints) + " ") + _global.GetText("pointsprint")) + " )";
usersd._width = usersd.textWidth + (2 * gutter);
usersd._height = usersd.textHeight + (2 * gutter);
usersd._y = userl._y;
passedsd.text = (((((": " + _global.passedscore) + " % ( ") + _global.passedpoints) + " ") + _global.GetText("pointsprint")) + " )";
passedsd._width = passedsd.textWidth + (2 * gutter);
passedsd._height = passedsd.textHeight + (2 * gutter);
passedsd._y = datel._y;
maxx = Math.max(usersd._width, passedsd._width);
usersd._x = w - maxx;
passedsd._x = w - maxx;
usersl.text = _global.GetText("userscoreprint");
usersl._width = usersl.textWidth + (2 * gutter);
usersl._height = usersl.textHeight + (2 * gutter);
usersl._y = userl._y;
passedsl.text = _global.GetText("passedscoreprint");
passedsl._width = passedsl.textWidth + (2 * gutter);
passedsl._height = passedsl.textHeight + (2 * gutter);
passedsl._y = datel._y;
maxx = Math.max(usersl._width + maxx, passedsl._width + maxx);
usersl._x = w - maxx;
passedsl._x = w - maxx;
by = elapsedl._y + elapsedl._height;
nocl.text = _global.GetText("nocolprint");
nocl._width = nocl.textWidth + (2 * gutter);
nocl._height = nocl.textHeight + (2 * gutter);
nocl._y = by;
nocl._x = (dx + bx) + ((c1 - nocl._width) / 2);
answerscl.text = _global.GetText("questionscolprint");
answerscl._width = answerscl.textWidth + (2 * gutter);
answerscl._height = answerscl.textHeight + (2 * gutter);
answerscl._y = by;
answerscl._x = ((dx + bx) + c1) + 5;
statuscl.text = _global.GetText("statuscolprint");
statuscl._width = statuscl.textWidth + (2 * gutter);
statuscl._height = statuscl.textHeight + (2 * gutter);
statuscl._y = by;
statuscl._x = ((w - c4) - c3) + ((c3 - statuscl._width) / 2);
pointscl.text = _global.GetText("pointscolprint");
pointscl._width = pointscl.textWidth + (2 * gutter);
pointscl._height = pointscl.textHeight + (2 * gutter);
pointscl._y = by;
pointscl._x = (w - c4) + ((c4 - pointscl._width) / 2);
beginFill(clgray, 30);
lineStyle(0, clwhite, 100);
moveTo(dx + bx, by);
lineTo(w, by);
lineTo(w, by + nocl._height);
lineTo(dx + bx, by + nocl._height);
lineTo(dx + bx, by);
endFill();
by = (by + nocl._height) + 1;
headery = by;
pcount.t.text = ("- " + pagecount) + " -";
pcount._width = pcount.textWidth + (2 * gutter);
pcount._height = pcount.textHeight + (2 * gutter);
pcount._y = (h - pcount._height) - 5;
pcount._x = dx + (((w - pcount._width) - dx) / 2);
};
this.Print = function (pj, pw, ph, adx, ady) {
w = pw;
h = ph;
dx = adx;
dy = ady;
c2 = ((((w - c1) - c3) - c4) - dx) - bx;
i = 0;
pagecount = 1;
this.clear();
Showheader();
no._visible = false;
lscenario._visible = false;
pscenario._visible = false;
q._visible = false;
a._visible = false;
pstatus._visible = false;
ppoints._visible = false;
nomdd._visible = false;
level = 1000;
var miny;
var maxy;
var psy;
var levelq;
var levelp;
levelp = level;
by = headery;
while (i < _global.qoptions.nrquestions) {
miny = by;
psy = miny;
levelq = level;
item = no.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = i + 1;
item._x = dx + bx;
item._y = by;
item._visible = true;
if (_global.quizItems[i].scenario != "") {
item = lscenario.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = _global.GetText("scenarioprint");
item.t._width = item.t.textWidth;
item._x = (dx + bx) + c1;
item._y = by;
item._visible = true;
item.t.autoSize = false;
psy = item._width;
item = pscenario.duplicateMovieClip("ob" + level, level);
level++;
item.t.text = _global.quizItems[i].scenario;
item.t._width = (c2 - psy) - 1;
item.t.autoSize = "left";
item.t.wordWrap = true;
item._x = (((dx + bx) + c1) + psy) + 1;
item._y = by;
item._visible = true;
by = (by + item._height) - (2 * gutter);
item.t.autoSize = false;
psy = by + gutter;
}
item = q.duplicateMovieClip("ob" + level, level);
level++;
item.t._width = c2;
item.t.autoSize = "left";
item.t.wordWrap = true;
item.t.text = _global.quizItems[i].question;
item._x = (dx + bx) + c1;
item._y = by;
item._visible = true;
by = (by + item.t._height) - (2 * gutter);
item.t.autoSize = false;
switch (_global.quizItems[i]._type) {
case "tf" :
addrb((dx + bx) + c1, _global.quizItems[i], true);
break;
case "mc" :
addrb((dx + bx) + c1, _global.quizItems[i], true);
break;
case "mr" :
addrb((dx + bx) + c1, _global.quizItems[i], false);
break;
case "ed" :
added((dx + bx) + c1, _global.quizItems[i]);
break;
case "wb" :
addwb((dx + bx) + c1, _global.quizItems[i]);
break;
case "mdd" :
addmdd((dx + bx) + c1, _global.quizItems[i]);
break;
case "odd" :
addodd((dx + bx) + c1, _global.quizItems[i]);
break;
case "cz" :
addcz((dx + bx) + c1, _global.quizItems[i]);
}
item = pstatus.duplicateMovieClip("ob" + level, level);
level++;
var xt = item.t.getTextFormat();
if (_global.quizItems[i].completed == false) {
item.t.text = _global.GetText("incompleteprint");
} else if (_global.quizItems[i].UserResponse() == true) {
item.t.text = _global.GetText("correctprint");
xt.color = clgreen;
} else {
item.t.text = _global.GetText("incorrectprint");
xt.color = clred;
}
item.t.setTextFormat(xt);
item.t._width = c3;
item._x = (w - c4) - c3;
item._y = miny;
item._visible = true;
item = ppoints.duplicateMovieClip("ob" + level, level);
level++;
if (_global.quizItems[i].IsAnswered() == false) {
item.t.text = "-";
} else {
item.t.text = _global.quizItems[i].ResultPoints();
}
item.t._width = c4 - 5;
item._x = (w - c4) - 5;
item._y = miny;
item._visible = true;
var xscale;
var yscale;
imgy = (miny + item._height) + 1;
if (_global.quizItems[i].HasImage()) {
item = this.attachMovie(_global.quizItems[i].img, "ob" + level, level);
level++;
if ((item._width > (c3 + c4)) || (item._height > 125)) {
xscale = (c3 + c4) / item._width;
yscale = 125 / item._height;
if (yscale < xscale) {
xscale = yscale;
}
item._xscale = 100 * xscale;
item._yscale = 100 * xscale;
}
item._x = (w - c3) - c4;
item._y = imgy;
if ((imgy + item._height) > by) {
by = imgy + item._height;
}
}
if ((by > ph) && (levelq != levelp)) {
k = levelq;
while (k < level) {
item = eval ("ob" + k);
item._visible = false;
k++;
}
pj.addPage(this);
k = levelp;
while (k < (level + 1)) {
removeMovieClip("ob" + k);
k++;
}
levelp = level;
pagecount++;
this.clear();
Showheader();
} else {
lineStyle(1, clgray, 100);
moveTo((dx + bx) + 1, miny);
lineTo((dx + bx) + 1, by + gutter);
lineTo(w, by + gutter);
moveTo(((dx + bx) + c1) - 1, miny);
lineTo(((dx + bx) + c1) - 1, by + gutter);
moveTo((((dx + bx) + c1) + c2) - 1, miny);
lineTo((((dx + bx) + c1) + c2) - 1, by + gutter);
moveTo(w, miny);
lineTo(w, by + gutter);
if (psy != miny) {
moveTo(((dx + bx) + c1) - 1, psy);
lineTo((((dx + bx) + c1) + c2) - 1, psy);
}
by = by + gutter;
i++;
}
}
pj.addPage(this);
pj.send();
k = levelp;
while (k < (level + 1)) {
removeMovieClip("ob" + k);
k++;
}
this.clear();
};
}
Symbol 321 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
mctable.Minimize();
}
Symbol 331 Button
on (release, releaseOutside) {
t._x = t._x - 1;
t._y = t._y - 1;
_global.StartSound("sclick");
if (_global.rep_enable == true) {
if (_global.rep_method < 2) {
_parent.getURL("javaScript:Finish()", "_self");
}
}
if (_global.passed == true) {
if (String(_global.finish.actionpass) == "0") {
_parent.loadMovie(_global.finish.actionpassswf);
}
if (String(_global.finish.actionpass) == "1") {
_parent.getURL(_global.finish.actionpassurl, "_self");
}
if (String(_global.finish.actionpass) == "2") {
fscommand ("exec", _global.finish.actionpassexe);
fscommand ("quit");
}
if (String(_global.finish.actionpass) == "3") {
if (_parent.var1 == "1.20") {
fscommand ("quit");
} else if (System.capabilities.playerType == "StandAlone") {
fscommand ("quit");
} else {
getURL ("javascript:window.opener=self; window.close();");
}
}
} else {
if (String(_global.finish.actionfail) == "0") {
_parent.loadMovie(_global.finish.actionfailswf);
}
if (String(_global.finish.actionfail) == "1") {
_parent.getURL(_global.finish.actionfailurl, "_self");
}
if (String(_global.finish.actionfail) == "2") {
fscommand ("exec", _global.finish.actionfailexe);
fscommand ("quit");
}
if (String(_global.finish.actionfail) == "3") {
if (_parent.var1 == "1.20") {
fscommand ("quit");
} else if (System.capabilities.playerType == "StandAlone") {
fscommand ("quit");
} else {
getURL ("javascript:window.opener=self; window.close();");
}
}
}
}
Symbol 343 MovieClip Frame 80
gotoAndPlay (10);
Symbol 346 MovieClip Frame 80
gotoAndPlay (10);
Symbol 348 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
var state = 1;
if (System.capabilities.playerType == "ActiveX") {
state = 2;
if (var1 == "1.10") {
state = 1;
}
} else {
state = 1;
}
if (state == 2) {
_global.emailbefore = _global.emailbefore_2;
_global.emailafter = _global.emailafter_2;
_global.emailfinish = _global.emailfinish_2;
_global.crlf = _global.crlf_2;
} else {
_global.emailbefore = _global.emailbefore_1;
_global.emailafter = _global.emailafter_1;
_global.emailfinish = _global.emailfinish_1;
_global.crlf = _global.crlf_1;
}
var i;
var str;
str = new String();
if (state == 2) {
str = _global.crlf + _global.crlf;
} else {
str = (_global.GetText("emailbegin") + _global.crlf) + _global.crlf;
}
str = ((str + _global.emailbefore) + _global.GetText("emailquizid")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailuserid")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailstatus")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailuserpoints")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailpassedpoints")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailmaxpoints")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailuserscore")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailpassedscore")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailtimeelapsed")) + _global.emailfinish;
str = ((str + _global.emailbefore) + _global.quizid) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.userid) + _global.emailafter;
str = str + _global.emailbefore;
if (_global.passed == true) {
str = str + _global.GetText("reportpassed");
} else {
str = str + _global.GetText("reportfailed");
}
str = str + _global.emailafter;
str = ((str + _global.emailbefore) + _global.userpoints) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.passedpoints) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.totalpoints) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.userscore) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.passedscore) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.FormatTime(_global.timeelapsed)) + _global.emailfinish;
str = str + _global.crlf;
str = ((str + _global.emailbefore) + _global.GetText("emaildate")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailtime")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailinteractionid")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailinteractiontype")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailinteractionuserresponse")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailinteractionresult")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailinteractionpoints")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailinteractionweight")) + _global.emailafter;
str = ((str + _global.emailbefore) + _global.GetText("emailinteractionlatency")) + _global.emailfinish;
i = 0;
while (i < _global.qoptions.nrquestions) {
str = str + _global.quizItems[i].EmailResult();
i++;
}
str = str + _global.crlf;
str = (str + _global.GetText("emailend")) + _global.crlf;
var subj;
subj = new String();
subj = _global.FormatText(_global.GetText("emailsubject"), _global.title);
var body;
body = new String();
body = str;
var mailto;
mailto = new String();
mailto = (((("mailto:" + _global.design.emailaddress) + "?subject=") + subj) + "&body=") + body;
var mailtojs;
mailtojs = new String();
mailtojs = _global.design.emailaddress + _global.interaction_separator;
mailtojs = (mailtojs + subj) + _global.interaction_separator;
mailtojs = (mailtojs + body) + _global.interaction_separator;
if (state == 2) {
fscommand ("SendEmail", mailtojs);
} else {
_root.getURL(mailto, "_blank");
}
}
Symbol 356 MovieClip Frame 63
gotoAndPlay (35);
Symbol 359 MovieClip Frame 63
gotoAndPlay (35);
Symbol 361 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
_global.review = true;
GoToQuestion(1);
}
Symbol 373 MovieClip Frame 50
gotoAndPlay (10);
Symbol 374 MovieClip Frame 51
gotoAndPlay (10);
Symbol 375 Button
on (release, releaseOutside) {
_global.StartSound("sclick");
mcprint.Print();
}