Presentation is loading. Please wait.

Presentation is loading. Please wait.

UFCFY5-30-1Multimedia Studio Scripting for Interactive Media Times Table Quiz This will contribute towards your online portfolio for this module.

Similar presentations


Presentation on theme: "UFCFY5-30-1Multimedia Studio Scripting for Interactive Media Times Table Quiz This will contribute towards your online portfolio for this module."— Presentation transcript:

1 UFCFY5-30-1Multimedia Studio Scripting for Interactive Media Times Table Quiz This will contribute towards your online portfolio for this module.

2 UFCFY5-30-1Multimedia Studio Development Cycle Problem Description and Analysis Design a Solution (Describe/Plan/Document) Implement (code it!) Test – Debug! - Retest Maintain / Improve/ Enhance.

3 UFCFY5-30-1Multimedia Studio Problem Create a times-table quiz for users of around 6-7 years old to play against the computer. After entering their name at the start of the quiz the user will be presented with randomly generated times-table questions based on 2 – 10 times tables and will attempt to give the correct answer. If the user answer is correct their score will increase, if not the computer’s score will increase. After 10 questions the scores are displayed and the winner announced.

4 UFCFY5-30-1Multimedia Studio Do I Understand the Problem? Think…

5 UFCFY5-30-1Multimedia Studio 2 x 7 = ? Times Tables 6 x 9 = ? 9 x 8 = ? 7 x 5 = ?

6 UFCFY5-30-1Multimedia Studio Design Solution – Pseudo Code prompt the user to enter their name loop generate two random numbers multiply them together and store the answer display the numbers and prompt the user to enter their answer compare the user’s answer with the answer stored if the user’s answer is correct – increase the user’s score if the user’s answer is incorrect increase the computer’s score while more questions to ask user display scores to the user with an appropriate message.

7 UFCFY5-30-1Multimedia Studio What Variables are Required prompt the user to enter their name loop generate two random numbers multiply them together and store the answer display the numbers and prompt the user to enter their answer compare the user’s answer with the answer stored if the user’s answer is correct – increase the user’s score the user’s answer is incorrect increase the computer’s score while more questions to ask user display scores to the user with an appropriate message

8 UFCFY5-30-1Multimedia Studio Data Table: Variables, Purpose and Type Variable NamePurposeType userNamestore the user’s nameString firstNumberstore the value of the integer first random number secondNumberstore the value of the secondinteger random number correctAnswerstore the product of theinteger first and second number userResponsestores the value of the userinteger answer to the question userScore stores the number of correctinteger answers from the user computerScorestores the number of incorrectinteger answers from the user numberOfQuestionsstores the number of questions tointeger ask the user during the quiz

9 UFCFY5-30-1Multimedia Studio Control Structures ? loop generate two random numbers multiply them together and store the answer display the numbers and prompt the user to enter their answer compare the user’s answer with the answer stored if the user’s answer is correct – increase the user’s score if the user’s answer is incorrect increase the computer’s score while more questions to ask user display scores to the user with an appropriate message.

10 UFCFY5-30-1Multimedia Studio User Interface Information Static text fields to label user information. Input text fields to get user response to questions. Dynamic text fields to update display.

11 UFCFY5-30-1Multimedia Studio Over to You! Use the design and pseudo code in this presentation together with previous notes and tutorial examples to implement a times table quiz using AS3. Once you have a working solution you can then think about designing and creating an engaging user interface.


Download ppt "UFCFY5-30-1Multimedia Studio Scripting for Interactive Media Times Table Quiz This will contribute towards your online portfolio for this module."

Similar presentations


Ads by Google