ผลต่างระหว่างรุ่นของ "01219245/javascript1/tutorial4"
ไปยังการนำทาง
ไปยังการค้นหา
Jittat (คุย | มีส่วนร่วม) |
Jittat (คุย | มีส่วนร่วม) |
||
แถว 7: | แถว 7: | ||
<div class="toccolours mw-collapsible mw-collapsed"> | <div class="toccolours mw-collapsible mw-collapsed"> | ||
− | Expand this box after you finish thinking. | + | Expand this box to see a few examples after you finish thinking. |
<div class="mw-collapsible-content"> | <div class="mw-collapsible-content"> | ||
* Random a word. | * Random a word. | ||
แถว 24: | แถว 24: | ||
'''Exercise:''' From the list above, try to order the items according to their importance to the game. | '''Exercise:''' From the list above, try to order the items according to their importance to the game. | ||
+ | |||
+ | <div class="toccolours mw-collapsible mw-collapsed"> | ||
+ | Expand this box to see some possible ordering. | ||
+ | <div class="mw-collapsible-content"> | ||
+ | * Show the word with blanks. | ||
+ | * Read the guess alphabets and show the correct ones in the word. | ||
+ | * Count the number of wrong guesses. | ||
+ | * Random a word. | ||
+ | * Show the hangman figures. | ||
+ | * Show a list of alphabets from which the user can choose. | ||
+ | * Hide used alphabets. | ||
+ | * Reset the game after the game ends. | ||
+ | </div> | ||
+ | </div> | ||
== Core mechanics == | == Core mechanics == | ||
== Assets == | == Assets == |
รุ่นแก้ไขเมื่อ 17:38, 28 มกราคม 2557
- This is part of 01219245.
Everyone should know what Hangman Game is. If you don't, it's a simple vocabulary game and you can try it here.
Task breakdown
Exercise: Let's think about what our Hangman program has do to.
Expand this box to see a few examples after you finish thinking.
- Random a word.
- Show the word with blanks.
- Read the guess alphabets and show the correct ones in the word.
- Count the number of wrong guesses.
- Show the hangman figures.
- Show a list of alphabets from which the user can choose.
- Hide used alphabets.
- Reset the game after the game ends.
- (... I can keep listing other features.)
Not all features above are extremely important to the game. For example, if you don't even draw the hangman figures, the game will be a pretty weird hangman game, but it is still the hangman game. If we can only choose 2 features to implement, we can simply throw away the hangman drawing task.
Exercise: From the list above, try to order the items according to their importance to the game.
Expand this box to see some possible ordering.
- Show the word with blanks.
- Read the guess alphabets and show the correct ones in the word.
- Count the number of wrong guesses.
- Random a word.
- Show the hangman figures.
- Show a list of alphabets from which the user can choose.
- Hide used alphabets.
- Reset the game after the game ends.