Unity-Technologies / Unity-Technologies/com.unity.netcode.gameobjects

Potential bug. NGO causes Nintendo Switch to freeze.

Đang mở
#3,053 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

priority:high stat:imported type:bug
Ngôn ngữ chính
C#
Star
2.3k
Fork
461
Merge trung bình
3 ngày 16 giờ
Pull request đã merge (30 ngày)
20

Mô tả

Description

If you put the console to sleep for a long period of time the console will hang for a period of time.

Reproduce Steps
  1. Start the game or test project
  2. Start a host but do not let any client in
  3. Put the console sleep
  4. Wait a few hours (The longer it sleeps the longer will be the freeze)
  5. Turn the console back on and return to the game.
Actual Outcome

The game is frozen for a certain amount of time. After a while the game is playable again.

Expected Outcome

The game doesn't freeze and Gameplay continue, (Except when playing online)

Environment
  • Unity Version: 2022.3.30f
  • Netcode Version: 1.9
Additional Context

Looking at a nxdump, it seems like the game is freezing in some loop somewhere involving NetworkTime, I did not have the chance to look deeper but I wanted to bring more eyes on the issue. This was the "suspicious" part I found in the dump.

IL2CPP_EXTERN_C IL2CPP_METHOD_ATTR void NetworkTime__ctor_mD40214D6A925F3027C77DA7051C210F487C0CC55 (NetworkTime_t2E4697E4558B217C431021D2CC30A9306E778B5F* __this, uint32_t ___0_tickRate, int32_t ___1_tick, double ___2_tickOffset, const RuntimeMethod* method)

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Tái hiện kịch bản sleep-and-resume với một host và không có client, sau đó kiểm tra nxdump xung quanh NetworkTime__ctor_mD40214D6A925F3027C77DA7051C210F487C0CC55. Theo dõi vòng lặp NetworkTime bị nghi ngờ và xác minh rằng game tiếp tục mà không bị treo kéo dài sau khi sleep trong thời gian dài trên Nintendo Switch.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
csharp, unity
Lĩnh vực
game-dev, networking
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
25/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.