Skip to content

Conversation

@lucnguyen1375
Copy link

No description provided.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Em nên đặt biến rõ ràng hơn nhé, với lại mình không nên viết tắt -> không rõ ràng -> em có thể đặt Leaderboard gì đó, cái này tùy em thôi

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

các biến a đang thấy e viết tắt khá nhiều -> không thể hiện được ý nghĩa của biến, ở chỗ này e có thể đặt fileRank,... gì đó để thể hiện rõ ràng hơn nhé, bên dưới cũng thế

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Data thường là package để chứa dữ liệu kiểu như em muốn chơi tiếp thì em lưu dữ liệu vào đó, bxh là cái e thể hiện ra cho người dùng thấy, a nghĩ e nên đặt nó trong package view thì hợp lý hơn,
ngoài ra em có thể tạo 1 class chuyển load dữ liệu thôi -> a thấy bxh của e đang có cả load dữ liệu và hiển thị ra màn hình nữa
Các đường dẫn e nên truyền vào -> tái sử dụng
Em có thể lưu theo object bằng file nhị phân nhé -> em đọc 1 phát object luôn chứ không đọc từng dòng thế này

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nếu i không sử dụng thì e nên dùng for each nhé

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a đang thấy các chuỗi như "\uD83C\uDF0A", "\uD83D\uDC25" đang sử dụng lại nhiều lần nhưng nó đang không thể hiện ra được là nó có ý nghĩa thế nào -> em nên tạo 1 class Constant gì đó lưu giá trị của các cái này, mình chỉ lần mỗi lần so sánh thì sẽ lấy ra thôi

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

đoạn này e nên viết hàm để tái sử dụng nếu được nhé, với lại nếu nhiều if else thì em nên dùng swithcase thì rõ ràng hơn

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

import thư viện lên trên em nhé

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Biến lúc tiếng anh lúc tiếng việt này em, a đang thấy e đặt biến đang không tường minh cho lắm, em nên sửa nhé

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mình nên hạn chế sử dùng các con số nhé, vì nó không thể hiện được ý nghĩa, em có thể đặt sizeBoard = 10 rồi em so sanh chẳng hạn

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mấy hàm dưới nữa nhé, e nên sửa lại các biến nhé

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a thấy cái này e đặt package là player thì trong nó sẽ chứa model Player các thứ thôi, a thấy nó đang có cả checkShoot, ShowBoard các thứ nữa -> không thể hiện được sử liên quan class đến package, em có thể tham khảo mô hình MVC nhé

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a thấy em đặt sizeBoard là 10 nhưng mà em lại không sử dụng nó, ví dụ a muốn tăng kích thước lên 15 thì phải làm thế nào -> e phải sửa từng chỗ thay vì sử sizeBoard đko

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants