NetworkTransform misses sync when GameObject is re-enabled; add option for automatic reassertion
Maintainer thường phản hồi trong vòng 3 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Lĩnh vực
- networking
Hướng nghiên cứu
Bắt đầu từ cách NetworkTransform xử lý Teleport theo quyền của server khi NetworkObject không hoạt động, sau đó tái hiện chuỗi vô hiệu hóa, di chuyển và kích hoạt lại được mô tả. Xác định cách có thể áp dụng lại transform mới nhất có thẩm quyền khi kích hoạt lại, đồng thời xác minh rằng client nhận được vị trí đã cập nhật mà không cần gọi Teleport lần thứ hai.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Description
When using NetworkTransform in server-authoritative mode, if a NetworkObject is deactivated on clients (e.g. via SetActive(false) or scene streaming), any transform changes (e.g. via Teleport) made while it's inactive are not propagated to the client once it's re-enabled. This results in position mismatches, where the client sees the object at its old position while the server has already moved it.
There is no warning, and the desync is silent unless manually corrected.
Reproduction Steps
Spawn a server-authoritative NetworkObject with a NetworkTransform
Deactivate the object on all clients (via RPC or reparenting in a disabled object)
On the server, call Teleport(...) to move the object
Reactivate the object after a short delay
Observe: the client does not reflect the new position
Expected Behavior
Clients should receive the latest authoritative position of the object when it becomes active again.
Workarounds
Currently, we must:
Reapply Teleport() after reactivating the object, or
Use a coroutine to delay the teleport until the object is re-enabled, or
Use custom NetworkVariable logic or whatever boiler plate works instead of NetworkTransform
Suggested Fixes
Add a forceResyncOnEnable bool on NetworkTransform
Internally store the last known transform state, and resend it on reactivation
Or provide an OnNetworkObjectReenabled callback for developers to manually reassert state
- Ngôn ngữ chính
- C#
- Star
- 2.3k
- Fork
- 465
- Merge trung bình
- 3 ngày 12 giờ
- Pull request đã merge (30 ngày)
- 39
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của Unity-Technologies/com.unity.netcode.gameobjects
-
TimeSyncMessage is sent reliably, so a late one resets the client clock backwards and stalls its NetworkTransformsCó thể đã có người làm @reginaldalfret đã nhận 8 ngày trước. Đang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 52/100
Unity-Technologies/com.unity.netcode.gameobjects#4249 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
NetworkTransform: half-float base update dropped as out of order when UseUnreliableDeltas is on, so later deltas decode ~2 m offCó thể đã có người làm @NoelStephensUnity đã nhận 8 ngày trước. Đang mởport:3.x-completed priority:medium stat:imported type:bug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 57/100
Unity-Technologies/com.unity.netcode.gameobjects#4248 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Tracking type:feature-2.x
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
Unity-Technologies/com.unity.netcode.gameobjects#3870 · 5 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
-
Please error, or at least warn, when a managed type is included in INetworkSerializeByMemcpyĐang mởTracking type:feature
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
Unity-Technologies/com.unity.netcode.gameobjects#3830 · 7 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
-
priority:medium stat:imported type:feature type:feature-2.x
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 42/100
Unity-Technologies/com.unity.netcode.gameobjects#3706 · 5 bình luận ·
Maintainer thường phản hồi trong vòng 3 ngày
Tất cả issue của Unity-Technologies/com.unity.netcode.gameobjects
Issue tương tự
-
hand-to-AI
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
CactuseSecurity/firewall-orchestrator#5803 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Typed MINID rejects numeric thresholds with a leading plus sign accepted by Redis and ValkeyĐang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
Maintainer thường phản hồi trong vòng 1 ngày
-
DXF with empty names failsĐang mởbug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Maintainer thường phản hồi trong vòng 3 ngày
-
bug python
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 88/100
ilia-sokolov/OfficeAgent.NET#89 ·
Maintainer thường phản hồi trong vòng 13 ngày