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
0
Question by HSMInteractive · Nov 06, 2013 at 01:30 AM · networkingmultiplayerfpscharactermodel

Multiplayer FPS Character Model Question

So I've been wondering. I've made an FPS before where there is just a camera, the arms, and the gun. But I want to make a multiplayer game which obviously means there has to be a character model. How does this work? Are the guns and stuff actually part of the character model or is it like where your camera renders only your arms and guns and stuff but you can see other players characters (if that makes sense). Basically, what I'm asking is, how do you make a multiplayer fps with a character where there are animations and such and you can see the other players' characters. I was watching this and it seemed to be what I'm asking how to do.

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
Best Answer

Answer by xt-xylophone · Nov 06, 2013 at 02:24 AM

Yup you have the right idea. Its done using render layers. Set it up so when you start, your body is set to a layer your camera cannot see and vice-versa for the arms/gun model. Other players are set to always show the body, never the hands. The layers setup is done locally so its always correct on your own machine.

This is also how you can do some swapping between 3rd and 1st person cam if you need. Have a cam behind the player that only renders body layers and one in your head that only renders arm layers.

Comment
Add comment · Show 3 · 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 HSMInteractive · Nov 06, 2013 at 11:04 PM 0
Share

Alright, this sounds like what I was thinking. I just have to think of how how to do this locally.

avatar image HSMInteractive · Nov 06, 2013 at 11:12 PM 0
Share

I think I got it.

How does this look:

 #pragma strict
  
 var fpsView : GameObject;
 var tpsView : GameObject;
 
 
      Screen.lockCursor = true;
      Screen.showCursor = false;
  
      //$$anonymous$$ine
  
      if(networkView.is$$anonymous$$ine == true){
         fpsView.active = true;
         tpsView.renderer.enabled = false;
  
         
      //Not $$anonymous$$ine
      }else{
         fpsView.active = false;
         tpsView.renderer.enabled = true;
         
 }
avatar image thingimibob · Mar 23, 2014 at 06:13 AM 0
Share

Take a look at fps kit 2.0 multiplayer

avatar image
0

Answer by figman123456 · Nov 06, 2013 at 01:49 AM

From what i would think it works exactly the same as single player for the player character but on the other players screen you place a model of that player at there positions so they see you as a character and you see them as a character, but the players character is itself is exactly the same. I'm pretty sure that's how it works, that's how i would do it anyway :)

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 jrlowe · Mar 24, 2014 at 04:12 AM

There's also a different, easier way. I'm assuming you don't want to see feet or anything of your character so just have the hand model. The way multiplayer works, the other players don't actually see "you". They render a model representing your location.

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

19 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

Related Questions

Unity networking tutorial? 6 Answers

FPS Multiplayer setup - TPS models for other clients 1 Answer

Multiplayer projectiles 0 Answers

Network.Instatiate Problem 0 Answers

Frames Per Second Cost from Multiplayer? 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