Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • 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
0
Question by kag4380 · Aug 20, 2015 at 10:51 PM · networkingunity multiplayer

[UNET] Network object inactive after loading online scene

I'm working on Unity's UNET for networking. My problem is that when network manager takes me to online scene it deactivates all the networked objects. I know that network objects will start executing only after all the scene objects are loaded. But even after all my scene objects have loaded(I don't see any error in console), my network objects are still inactive. What else do I need to check in order to get those scripts running?

Comment
Add comment · Show 1
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 MFKJ · Jan 31, 2017 at 10:59 AM 0
Share

I am getting the same error? did you solve it?

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by marcelop · Nov 03, 2015 at 12:17 AM

You have to call NetworkServer.SpawnObjects() on the server once both server and client have fully loaded the scene.

http://docs.unity3d.com/Manual/UNetSceneObjects.html

Comment
Add comment · Show 2 · 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 MFKJ · Jan 31, 2017 at 11:00 AM 0
Share

NetworkServer.SpawnObjects() how you will use it on server

avatar image MFKJ · Jan 31, 2017 at 11:01 AM 0
Share

check here http://stackoverflow.com/questions/41909305/spawn-scene-object-not-found-for-1

avatar image
0

Answer by neopaul78 · Jun 21, 2019 at 03:04 PM

 1) Override Awake in script of network object:
     void Awake(){    DontDestroyOnLoad(gameObject);}
 2) Add prefab of this object to spawn list of NetworkManager
 3) OnPlayer script:
     void Awake(){ DontDestroyOnLoad (gameObject); }
 IEnumerator selfEnab(){ // KORUTINE WAIT LOADIN OF SCENE
         yield return new WaitForSeconds (2);
         Cmd_Ena(); }
 void MyChangeLevel(){ // CALL SPAWN CORUTINE AFTER LOAD SCENE
 SceneManager.LoadScene (numlev++, LoadSceneMode.Single);
 StartCoroutine ("selfEnab"); }











Comment
Add comment · 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.

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

UNET relay server for Personal Edition? 1 Answer

UNET moving client objects 1 Answer

Rpc is received by client but Cmd is not received by server 2 Answers

How to give a client authority over an object in UNET? 3 Answers

Sending texture updates from client to server 1 Answer


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