`NetworkObject` `CheckObjectVisibility` doesn't work on client connection
Mantenedores costumam responder em até 2 dias
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 42/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Estagnada
- Domínio
- game-dev, networking
Direção de pesquisa
Comece pelo comportamento de NetworkObject em SpawnWithObservers, Spawn e CheckObjectVisibility, comparando a documentação sobre spawning e visibilidade de objetos vinculada no relatório. Reproduza a sequência de late join com CheckObjectVisibility retornando false e confirme que o objeto permanece ausente no cliente; considera-se concluído quando a visibilidade também for aplicada a futuros clientes que fizerem late join.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Description
I want to spawn a networkprefab without any client visibility, first i tried to set no observers before spawn:
NetworkObject.SpawnWithObservers = false;
NetworkObject.Spawn();
this results a spawned object with zero observers, but when a late-join client connects, the object gets spawned on client. The documentation says this is the intended normal behavior, because it only works at the initial spawning.
Then, the documentation says the CheckObjectVisibility will work at both initial spawning and new client connection, so i tried this:
NetworkObject.CheckObjectVisibility += _ => false;
NetworkObject.Spawn();
it did spawn with no observers as the previous approach, but when late-join client connects, it still spawn the object on client.
Reproduce Steps
- start server/host
- spawn a network prefab with
NetworkObject.CheckObjectVisibility += _ => false; - start a client and connect to server
Actual Outcome
a spawned object with visibility always set to false still spawns on late-join client
Expected Outcome
a spawned object with visibility always set to false should be invisible to all connected client and future late-join clients
Environment
- OS: [win10]
- Unity Version: [6000.0.32f1]
- Netcode Version: [2.1.1]
- Linguagem predominante
- C#
- Estrelas
- 2.3k
- Forks
- 464
- Merge médio
- 2d 18h
- PRs com merge (30d)
- 15
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de Unity-Technologies/com.unity.netcode.gameobjects
-
NetworkList changes made since the last tick are applied twice on a newly synchronized clientAbertastat:awaiting-triage stat:reply-needed type:bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 55/100
Unity-Technologies/com.unity.netcode.gameobjects#4179 ·
Mantenedores costumam responder em até 2 dias
-
Dedicated server: mixed-authority NetworkObject is removed from NetworkTransformUpdate, so its owner-authoritative NetworkTransform never updates server-sideTalvez já em andamento @NoelStephensUnity assumiu há 11 dias. Abertastat:imported stat:reply-needed type:bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 68/100
Unity-Technologies/com.unity.netcode.gameobjects#4159 · 5 comentários ·
Mantenedores costumam responder em até 2 dias
-
NetworkAnimator: Conditional triggered transitions to Exit node log false errorsTalvez já em andamento @NoelStephensUnity assumiu há 196 dias. Abertastat:awaiting-response stat:awaiting-triage stat:Investigating type:bug
Unity-Technologies/com.unity.netcode.gameobjects#3912 · 7 comentários · 1 responsável ·
Mantenedores costumam responder em até 2 dias
-
Tracking type:feature-2.x
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 35/100
Unity-Technologies/com.unity.netcode.gameobjects#3870 · 5 comentários ·
Mantenedores costumam responder em até 2 dias
-
Tracking type:feature
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
Unity-Technologies/com.unity.netcode.gameobjects#3830 · 7 comentários ·
Mantenedores costumam responder em até 2 dias
Todas as issues de Unity-Technologies/com.unity.netcode.gameobjects
Issues semelhantes
-
[Doc Gap] Document new --enable-public-network-access breaking change for azurebackup vault createAbertacopilot documentation
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 86/100
Mantenedores costumam responder em até 1 dia
-
area-dashboard
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
Mantenedores costumam responder em até 1 dia
-
0 - Backlog Bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
BrighterCommand/Brighter#4539 ·
Mantenedores costumam responder em até 1 dia
-
area-networking
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
dotnet/aspnetcore#69671 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
test
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
NethermindEth/nethermind#14274 ·
Mantenedores costumam responder em até 1 dia