Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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 MC HALO · Jun 21, 2011 at 04:32 AM · fps

GUN QUESTION ?

Hi all,

i was wondering if someone could help me. Basically if you guys know in fps games if you go next to a wall with the gun facing out it will stay viewable. But in unity if i go next to all with the gun facing out it will go trough the mesh how can i stop this ?

thank you in advance :)

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

1 Reply

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by · Jun 21, 2011 at 04:42 AM

Typically, the PlayerCharacter in FPS will have a larger bounding box (physics proxy) than the actual character. The gun stays viewable because the character's physics prevent them getting close enough to the wall to cause intersection.

Comment
Add comment · Show 4 · 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 MC HALO · Jun 21, 2011 at 04:47 AM 0
Share

So if i add a big box in front of the gun it would prevent it from going trough the walls ?

avatar image · Jun 21, 2011 at 04:50 AM 0
Share

Assu$$anonymous$$g you've set up your character to move around using physics - Rigidbody.$$anonymous$$ove(), iirc. You'd probably want a large box shape ins$$anonymous$$d of the actual physics of the gun, or it could get caught (and stop movement) in all sorts of places that you wouldn't want.

avatar image MC HALO · Jun 21, 2011 at 04:52 AM 0
Share

hmm the problem is the player is not controlled by physics its all done by character controller i have used the standard fps input controller :)

avatar image MC HALO · Jun 21, 2011 at 04:59 AM 0
Share

Thank you so so so so so so so lol much it worked even tough i did not use physics you are a life saver cheers mate :)

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

Simply Importing Assests Breaks my Unity Game 0 Answers

FPS control camera 1 Answer

Lens-Flare Muzzleflash 0 Answers

What is AutoWayPoint 1 Answer

How to swap an animation between two different models? 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