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 jorgon · Oct 24, 2011 at 09:10 AM · cameranetworkserverclient

How can I make that one player could watch other player's game as an observer?

Hi mates!.

I'm trying to make a version of my game which consits of a "super" player that can control the developement of the game of other players.

The fact is that I want that the "super" player could watch the developement of the others player's game as if he was them...Like when you are playing to other FPS games (Team Fortress 2 for instance) and you are waiting into the lobby to respawn.

I only need to redirect or send the camera's view of the other player to the "super" player in order that the "super" player can handle some golbal variables if he considers it based on what's happening to the normal player...

I think I now how to create GameObjects in the server version but, how should I do the instantiation of the same camera view of the other player in the server version of my game (what I called as the "supper" player)?.

Do you understand me?. I know that it must be something very simple but it's my first time and I've spent too much time with it...

Any idea?.

Thanks in advance.

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 syclamoth · Oct 24, 2011 at 09:11 AM 0
Share

Well, as long as you have proper synchronisation going on between all your players, it should be as simple as putting a camera up in the sky somwhere which your 'super player' uses! I'm not actually sure where the problem is, here.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by jorgon · Oct 24, 2011 at 10:43 AM

What do you wanna mean with the "proper syncronisation"?. I'm trying to understand the MultiplayerNetworking.pdf from the Official Unity3D website and I suppose that you are referring to the creation in the network of the client/server via somthing like this:

 var SpaceCraft : Transform;
 function OnNetworkLoadedLevel () {
 // Instantiating SpaceCraft when Network is loaded
 Network.Instantiate(SpaceCraft, transform.position, transform.rotation, 0);
 }
 function OnPlayerDisconnected (player : NetworkPlayer) {
 Network.RemoveRPCs(player, 0);
 Network.DestroyPlayerObjects(player);
 }

I don't know if you wanna mean something like this...I'm really new at networking in Unity3D. And I figure out that this is really simple, the only problem is that I'm really new with it and I've never make a server/client application but I know what I want to do.

Could you be a bit more specific, please?. Thanks for your help syclamoth.

P.S.: (for administrators/moderators only) I needed to write a new answer and not a new comment because I wanted to post some code and a comment didn't allow to me to do this.

Comment
Add comment · Show 7 · 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 timsk · Oct 24, 2011 at 11:03 AM 1
Share

write your comment out with full formatting in the answer box, then cut and paste it into the comment box. Easy :).

avatar image jahroy · Oct 24, 2011 at 10:31 PM 1
Share

I agree that your question should not be downvoted. You are actually trying to learn, which is more than many people do.

For the record, you could add this code to your original post and format it there.

It is perfectly ok to edit your original question so it changes over time as you change your approach to solving it.

avatar image syclamoth · Oct 24, 2011 at 10:33 PM 1
Share

Well, what I mean is, are all the objects which are important to your game the same on all computers? Have you been doing a lot of multi-player testing of this? In my experience, Network.Instantiate can cause unexpected problems, despite being somewhat easier to use than manual network instantiation, however for simple stuff it works quite nicely.

Also, what negative vote?

avatar image jahroy · Oct 24, 2011 at 10:39 PM 1
Share

Look at those karma points adding up!

avatar image jorgon · Oct 25, 2011 at 07:00 AM 1
Share

Thanks for your support and excuse me for my inexperience. I've voted up your right comments towards me. And I didn't know that I could make the trick of copy&paste a formatted code inside the answer textfield for the final paste as a comment: the format of code-text could be mantained even inside a comment textfield!.

But related to the original question syclamoth :I'm still trying to connect a client with a server: I'm trying to create a web version of my game and I'm trying to connect it to me server version. I'm in a very early stage of learning about networking in Unity3D. There are some functions, necessary preocedures and basic concepts I'm still trying to assimilate and learn how they work. I don't know how to share (or if it's possible) the same camera for both, (server and client) and I have to study how to access to the global variables I've created in my single playerversion of my game.I will tell you more when I achieve my objective. Don't you know how much I desire to put in green color the indicator of this question/answer. :-).

Thank you very much for your support and comprehension.

Show more comments

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

Client side prediction from the Networking Example 0 Answers

use Network.InitializeServer multiple time - multiple hosts 0 Answers

Server and Network no communication 1 Answer

Syncronization issues between server and client, using the OnStartServer() function, 0 Answers

Can anyone help me with my network script? 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