- Home /
How do I make it so that a FPS camera cannot see it's own playerModel but can see everyone else + Full Body Awareness
This is to make so that in a first person shooter game, the user controlling his own player character won't actually see his own character model, but he can see his friend's player characters and vice versa.
Although I've seen people put the player character's camera slightly in front of the 3d model, I would like to how say CSGO does it because I think CSGO and other FPS games simply have their cameras inside the player model.
Also how would one also implement full body awareness (Look down see your legs)while using this system?
You can put the player model on a layer so that the owner's camera cannot see their own model, but ins$$anonymous$$d can only see the arms and hands (possibly legs if you want them) model like most FPS games. You can learn more about that here:
Answer by NFMynster · Aug 26, 2016 at 08:31 AM
Yeah, check if the player is the local player and hide the model if not.
Answer by Rob2309 · Aug 24, 2016 at 07:00 PM
An easy solution would be to give your player a model which only includes the parts of the body you want to be able to see. This is probably the way most games do it (correct me if I'm wrong). If your game is an online game, you should choose the appropriate mesh for the player you are spawning (Mesh with only arms if the player is the local player; Mesh with entire body if the player is some other client). This is how I would do it, but there are certainly different solutions, I hope I could help :)
Answer by iuripujol · Feb 19, 2018 at 11:33 AM
https://drive.google.com/open?id=14pbaelY8hQM7frhMNYIEkf_DDlds3ub_
This is just a small sample of my work regarding parkour mechanics in FPS with full body awareness.
Contact me if you need some help: iuripujol@gmail.com.
Hey man , help me I also suffering from this problem But you delete this sample fps with full body awareness, I need that as help plz provide it me, Thanks
Answer by Aditya2581 · Jul 21, 2020 at 02:37 PM
to solve this issue a trick of layer masking is used. 1) change layer name of guns and hand to something like "PlayerCanOnlySeeThis". Do not select the legs as you don't want to see your own legs. 2) Add a camera to the position and in the inspector change the clear flags to "Depth only" and culling mask to "PlayerCanOnlySeeThis", and Depth to 50. (What this will do is render only the objects with this layer on top of the main camera) 3) Use another camera in that same position so see the world and under the culling mask deselect the "PlayerCanOnlySeeThis".
What do you mean by "add a camera to the position" and "in the inspector change the clear tags to depth only"? what clear flags?