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 Mitch Zelik · Jan 09, 2013 at 06:09 AM · rigidbodyraycastbulletarrow

Realistic Bow and Arrow Physics?

So I've been experimenting as a fairly new user to Unity, and I'm stumped on how to make a realistic arrow shot.

I've played around with launching Rigidbodies with the Instantiate function (using JavaScript exclusively in my scripting), but I find that if I bump up the speed of the arrow, it will sometimes go right through the colliders on meshes.

I have thought about switching over to Raycasting, but I need to have some travel time on the arrow for gameplay purposes, and obviously cant have it teleporting through meshes between frames at high speeds.

Any help would be appreciated!

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

2 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by Meater6 · Jan 19, 2013 at 01:06 PM

How fast does your arrow actually need to go? Most arrows & arrows only go up to 100 m/s max. Of course, since this is the game world, it may be upped a little ;). If its really fast, then you can use raycasting.

Going with the raycasting approach, you should increase the ray's length per frame to not make it instant. Then you have a particle effect, such as a grey line (like a arrow whizzing past), that grows in length like the raycast.

Unfortunately, this isn't really realistic movement of a normal arrow. Honestly, an arrow doesn't really need to move that fast. You can always decrease gravity for arrows so that it "feels" more realistic.

Sorry for the late answer, but better late than never ;). Good Luck! Hope this helps!

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 tosi · Jan 09, 2013 at 10:14 AM

Did you set the collision detection of your arrow's rigid body to 'dynamic'?

Or if you stay with Raycasting - you could try to raycast from the top of the arrow while it is flying.

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

10 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

Related Questions

Best way to shoot physical bullets? 2 Answers

Bullet Spread with Raycast/RigidBody Triangulation? 1 Answer

How to get right Physics with Follow on click 1 Answer

Collision misses - possibly not bullet through paper! (now with video) 1 Answer

Prevent Rigidbody to be pushed away by bullet 2 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