Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Classic Snake Game Development in Android: A Comprehensive Guide, Assignments of Java Programming

A detailed guide to developing a classic snake game for android using android studio. It covers the design, implementation, and testing phases of the project, including the creation of the game's interface, the implementation of game logic, and the testing of the game's functionality. Suitable for students learning android development and provides a practical example of game development principles.

Typology: Assignments

2023/2024

Uploaded on 03/07/2025

TuyetAnh24
TuyetAnh24 🇻🇳

5

(7)

33 documents

1 / 26

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
TRƯỜNG ĐẠI HỌC MỞ HÀ NỘI
KHOA CÔNG NGHỆ THÔNG TIN
---------------------------
BÁO CÁO BÀI TẬP LỚN
MÔN LẬP TRÌNH ANDROID
Đề tài: Lập trình game rắn săn mồi cổ điển
Giảng viên hướng dẫn : ThS. Mai Thị Thúy Hà
Sinh viên thực hiện :
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a

Partial preview of the text

Download Classic Snake Game Development in Android: A Comprehensive Guide and more Assignments Java Programming in PDF only on Docsity!

TRƯỜNG ĐẠI HỌC MỞ HÀ NỘI

KHOA CÔNG NGHỆ THÔNG TIN

BÁO CÁO BÀI TẬP LỚN

MÔN LẬP TRÌNH ANDROID

Đề tài: Lập trình game rắn săn mồi cổ điển

Giảng viên hướng dẫn : ThS. Mai Thị Thúy Hà

Sinh viên thực hiện :

MỤC LỤC

  • MỤC LỤC..................................................................................................................
  • I. Giới thiệu thành viên......................................................................................
  • II. Giới thiệu đề tài...............................................................................................
    1. Tổng quan....................................................................................................................
    1. Một số tựa game rắn săn mồi phổ biến.......................................................................
    1. Lợi ích ứng dụng mang lại..........................................................................................
  • III. Chức năng của ứng dụng...............................................................................
  • IV. Giải pháp thực hiện........................................................................................
  • V. Thiết kế giao diện............................................................................................
    1. Giao diện màn hình chính activity _main.xml
    1. Giao diện màn hình chơi game activity _play.xml
    1. Giao diện chọn tốc độ activity _speed.xml
  • VI. Xử lý code java_Xây dựng ứng dụng..........................................................
  •  SnakeSegments.java..................................................................................................
  •  GameView.java.........................................................................................................
  •  PlayActivity.java.......................................................................................................
  •  SpeedActivity.java....................................................................................................
  •  MainActivity.java......................................................................................................
  • VII. Kiểm thử........................................................................................................

 Thay đổi tốc độ : Thay đổi tốc độ di chuyển của rắn ở 3 mức slow (chậm),

medium (trung bình, nhanh gấp 1.5 lần slow), fast (nhanh, nhanh gấp 2 lần

medium)

 Lưu tốc độ rắn: Lưu lại tốc độ di chuyển của rắn sau mỗi lần người chơi ấn

chọn

 Xem điểm cao : Hiển thị điểm số cao nhất đạt được trong trò chơi để người

chơi có thể theo dõi.

 Lưu điểm cao : Lưu lại điểm số cao nhất đạt được trong trò chơi.

IV. Giải pháp thực hiện

 Phần mềm Android Studio

V. Thiết kế giao diện

1. Giao diện màn hình chính activity _main.xml

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent"

android:layout_height="match_parent" android:orientation="vertical" android:id="@+id/main" android:background="#6D9558" android:gravity="center">