• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
Question by nife · Nov 27, 2015 at 03:22 PM · networkingspawnsynchronizationsyncmessages

[Unet] Did not find target for sync message for 1. Delayed Spawn information

Sometimes in my client-server application I have "Did not find target for sync message for 1" Warning. I have server with OnlineSpectator (NetworkBehavior) object which is common and singular on all clients and server. Once the client is connected, I want SyncVar "time" to be synchronized. I am aware, that warning appears because OnlineSpectator is disabled on Client, but SyncVar is trying to synchronize. Server is sending to client information to spawn OnlineSpectator but it is delivered after few sync messages. Logs here: http://static.pokazywarka.pl/bigImages/6177079/16677912.jpg?1448627774

I use Reliable Fragmented channel (0) (because of big data messages) and HLAPI. Can I assure correct order of this messages? It is unacceptable to sync SyncVars ans SyncLits before being sure of OnlineSpectator existance on client.

I will be grateful for your help! :)

Comment
Zelek

People who like this

1 Show 0
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

2 Replies

· Add your reply
  • Sort: 
avatar image

Answer by nife · Nov 28, 2015 at 08:49 AM

What I discovered is that DefauldReliable channel (in Channels class) is 0 and is used for state updates and spawning.

Channels class: The id of the default reliable channel used by the UNet HLAPI, This channel is used for state updates and spawning.

public const int DefaultReliable = 0;

Because of it, to get oredered messages we have to set Channel 0 to Reliable Sequenced. Spawn message is now always before sync messages and error won't appear.

But it provides another problem. I was using channel 0 as Reliable Fragmented due to big data in message. I want to send this message OnConnect and using connection Id only. I use NetworkServer.SendToClient, but it uses channel 0 only. Can I bypass it somehow?

Messages ignores [NetworkSettings(channel = 1)] attribute :(

Comment
Zelek
Titanium_Fist

People who like this

2 Show 0 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image

Answer by jolleee · Aug 10, 2016 at 07:10 AM

Experienced the same problem. Seems to be caused by different errors, however I solved it by setting the inspector to "Debug"-mode and checking the Network Identity of the prefab that the server was spawning.

It had Scene Id set to 1 where every other prefab had it set to 0. I changed it to 0 and everything worked fine. Not sure if this is the case for everyone that are experiencing this problem though.

Comment

People who like this

0 Show 0 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

How to avoid spawn delay on client? 0 Answers

Spawing Hololens Camera OR ARCamera at user defined spawn locations 0 Answers

SyncVar works with disabled components? 0 Answers

[SyncVar] protect Cheat Engine 0 Answers

Did not find target warning when using uNet 3 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges