Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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 Wagner Schmitt · Nov 09, 2010 at 11:28 PM · instantiateprefabnetworkprojectclient

Network Instantiate cannot find prefab in client

Hi,

I made two different projetcs, one for the server and another for client. The server is calling Network.Instantiate every time a client connects, but this is giving me the following erros in client.

Network.Instantiate on the receiving client failed because the asset couldn't be found in the project

I have the same prefab on the client project. By the way, I clonned the whole scene from the server project, so why it don't find the prefab?

When I run two instances of the same project is works. Is there a problem using Network.Instantiate with diferent projects? Even if the scene is the same in the two projects? Should I instantiate using RPCs instead?

thx.

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

3 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by hypnoslave · Feb 18, 2011 at 08:07 PM

Hi there, i dont know if you're having the same problem, but I ran into a similar issue and resolved it. first though:

the design that you're going for is almost certainly a bad idea. DO NOT branch your build unless you have a really, really, really good reason to do so. Networking in unity is designed to be handled from the same build. I dont know what you're trying for, but it could very well be that you don't understand the networking system in unity.

ANYWAY. the solution. you need to be using external revision control with unity, so that it stores a .meta file next to every asset in your assets directory. find this meta file for the prefab you want and edit it in a text editor. that guid entry that you see needs to match on both builds. this is how unity identifies that the objects are, in fact, the same...

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
avatar image
1

Answer by shame · Nov 25, 2012 at 05:41 PM

Put the prefab inside "Resources" folder or create a public reference to it in the scene. But actually you shouldn't make different projects for server and client.

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
avatar image
0

Answer by benni05 · Jun 04, 2012 at 01:51 PM

A good solution to this problem can be found here:

http://forum.unity3d.com/threads/50632-Network.Instantiate-Asset-couldn-t-be-found...

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

2 People are following this question.

avatar image avatar image

Related Questions

Brain freeze: declaring a prefab inside the same prefab 1 Answer

When using Network.instantiate, how to set an additional setting for all clients (such as a script variable) ? 1 Answer

Player Instantiate in online game 1 Answer

Network.Instantiate a non-prefab? 1 Answer

How can I spawn a GameObject on all players in my multiplayer game? 0 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