Android
代写Android | app | project – 该题目是一个常规的Android的练习题目代写, 是比较有代表性的Android/app等代写方向, 该题目是值得借鉴的project代写的题目
CMSC 436 project 3 Assigned Thursday March 2, 2023
Due Thursday March 16, 11:59PM
0 This project is individual. It is a simplified Simon. The project must be called Project4 and the package must be com.example.project4. The project will be tested on emulator Pixel 5 API 31. 1 – Create an Android app using the Empty Activity template 2 The app works in vertical orientation and will use persistent data (but you do not need to submit the AndroidManifest.xml file). This app has only 1 screen. 3 – The screen displays 5 buttons (red, green, yellow, blue, and RESET) arranged as in the screen shot. The spacing does not have to be perfect but it should look clean and good. 4 When the app starts, a long Toast shows the current pattern (for example, red) 5 The user needs to successively click on the buttons that the current pattern shows. 6 If the user click sequence does not match the pattern, the user loses and the app terminates. 7 If the user click sequence matches the pattern, a new pattern is generated with an additional color, and so on until the user loses. Each time a new pattern is generated ("next level"), a long Toast shows the pattern. 8 We keep track of the best level reached by the user and store it in the app’s preferences on the device. When the user starts the app again and the best level reached is 4, the app should start at level 5. 9 If the user clicks on RESET, the persistent data (best level) is reset to 0 and the app restarts at level 1 with a new sequence and a corresponding Toast. The new sequence is randomly generated. 10 – Your app should include a Model (class Game in file Game.kt) that encapsulates the functionality of your app. Obviously, the model needs to be used (and used in a way that makes sense) within the app. Some things that should be included in the Model: best level, current level, target sequence, current sequence, methods to update these, generate a sequence, reset things in preparation of a new level, reading from and writing to persistent data,
Some useful information:
- Look up how a Toast is generated and is shown
- You may need to do some research on controlling the color of a button (so that it is not always purple)
Submission Details: on Gradescope, 3 files 1 layout .xml file: activity_main.xml 2 Kotlin files (one model and 1 activity): MainActivity.kt and Game.kt (the Model)
Grading Details:
Item Points App starts with the 5 buttons and looks good 10 App starts with the Toast 10 Event handling is enabled on all 5 buttons 10 When the user should lose, the user loses 5 When the user should continue (within a level), the user does 5 When the user should win, the user wins and moves to the next level and a new Toast shows with the correct (random) sequence
10
Persistent storage is working (reading and writing) 20 RESET button works 10 Model (Game class) is coded and is correct 10 Model is used correctly 10 Total 100
Grading notes:
1 In canvas, zipping the files will result in a 10 points penalty. 2 Not naming the files as specified above will result in a 10 points penalty.
Possible screenshot of a run when we start (as you can see, the pattern is blue):
Possible screenshot of a run as the user is now starting to play level 4:
Possible screenshot of a run as the user is now playing level 4 (the Toast is no longer showing):