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
1
Question by guido-paglie · Oct 22, 2015 at 06:45 AM · networkingplayerspawnservermanager

UNET Players not spawning on server change scene

I am using NetworkStarter sample project to make a lobby: http://forum.unity3d.com/threads/unet-sample-projects.331978/

The problem i have is when i change scene the player prefab does now spawn. The first time it enters to the game it does spawn, if you win the level and continue, in the next level it doesn't spawn.

I have somethink like: NetworkManager.singleton.ServerChangeScene("02.Game");

I already have done this with a game of mine, but here i can't find what's happening. In the level i have game object with network start position.

The weird thing is that is the same level, the flow is: Menu (lobby) -> game (level1) ->game (level1) the first time in the game it does spawn the player, but when i change scene it doesn't any more.

thank u in advance!

Comment
Add comment · Show 2
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 $$anonymous$$ · Mar 01, 2016 at 12:40 AM 0
Share

Did you ever figure this out? I have the same issue.

avatar image Wurghi · Apr 30, 2016 at 01:44 AM 0
Share

same problem, unet is still badly documented

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by sglindme · Jun 28, 2016 at 08:09 PM

Did you ever figure this out? One thing I'm noticing is that the port on the server network manager seems to just go back to the default value(7777) whenever it changes scene. This could be a cause of the problem....

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 Wurghi · Jun 28, 2016 at 10:38 PM 0
Share

I think i did! When i rebuilt the lobbyscene for my project from scratch in a simpler way the same problem occured and after some more research i realized that some important events would not get called on a levelchange. This post helped me out **http://forum.unity3d.com/threads/lobbyplayer-to-gameplayer-networklobbymanager.349614/**

You need to make sure that your lobbyplayer-objects are kept in the scene... i did this by parenting them on the lobbymanager which doesn't get destroyed On Load... hope this helps.

avatar image VenUk · Sep 12, 2016 at 12:50 PM 0
Share

So just to get this straight what you did in the player prefab in the Awake() or Start() is to set the Lobby$$anonymous$$anager as the parent of the player prefab?

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

44 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Unity networking tutorial? 6 Answers

Player Prefab on Lobby Managers? 5 Answers

Netcode [Command] Issues .. no errors, just not working. 1 Answer

How to check when a new client/local player is loaded? 1 Answer

Networking HLAPI Spawning Objects 2 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