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
2
Question by Fletch · Dec 23, 2011 at 05:11 AM · cameraguinetworkdisappear

GUI and spawning at runtime

I built my game with a player that was in the scene and had the GUI all working correctly with sound effects for the opening of windows and the closing of windows. There are a series of prefabs with GUI scripts attached to them so when you bump into them they display a GUI window.

I used the network example file from Unity's site to bring over the needed networking elements and allow users to play together. This requires that the player be removed from the scene and be spawned in at runtime. Now, when I bump into something that once open up a GUI, it does nothing... with the exception that it's still playing the sounds for opening and closing of the GUI. So something is happening but I can't tell what.

Does the GUI script that is attached to the game object need to reference a particular camera? If so, how do I do that?

Where did these GUI elements vanish to? Man, this is a really abstract question. I hope someone out there understands what I'm saying.

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 88bueno · Apr 12, 2012 at 08:29 AM 0
Share

Okay, it seems it didn't want to post my answer. I've been looking for something similar, but a few things that helped my GUI read properly is adding " @RPC " before and functions you want the network to calculate, such as losing health. I've seen something about attaching a NetworkID to the GUI as well, but haven't looked into it. Send me a personal e$$anonymous$$ail and I'll keep in touch with anything I find. I'm sorry I can't give you a cold hard answer for it.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by 88bueno · Apr 12, 2012 at 09:28 AM

Not an answer, not too sure on this, but I think it has something to do with RPC functions. I know I've been running a similar project, and my GUI wasn't doign the math on losing health until I put the losing health in an individual function and prefaced it with " @RPC " before the word function. I will keep looking, but maybe this can be used to help you. I think I saw something about assigning a NetworkID to the GUI? Hope this helps. Send me a personal Email and I will keep in touch if I find an answer.

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

FLYING from Camera Position A to B per Buttom click? 5 Answers

GUI Window on GameObject location? 1 Answer

GUI Label over network??? 0 Answers

Is there a way to change the order of the "Layers" Tab? 0 Answers

GUI button disappears 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