• 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 /
This post has been wikified, any user with enough reputation can edit it.
avatar image
0
Question by Max1mus · Jun 22, 2015 at 03:24 PM · parabola

Projectiles. Simple parabolic path.

I am trying to write a script to allow me to flick an object close to the screen, and it would slide along the z-axis until in reaches a certain point. There will be wind applied to it along the x-axis. Much like "Paper Toss"

A few important points. It has to stop in line on the z-axis with the target it's trying to reach. Like in "Paper Toss" it cannot go behind the bin or fall in front of it. It doesn't change it's y-position and last thing, it has to have a parabolic path.

I don't want you to think that I did no work, and I just want someone to write the script, I am just looking for any help I can get. I understand that this is a very simple question but due to my lack of experience with 3d games I can't solve it. I have done a few years of Applied Maths and I understand how the Physics of it works. I just don't know what it the best approach.

Here are my thoughts on it: 1. I cannot simply add an Impulse because I won't have control over where it will stop. Unless I manually type something like (if z <= -10 {stop;} // pseudo code), but that will lead to a sudden stop. 2. I can pre-calculate the path in the following way (look at the .png). The player will drag their finger away from the cross and let go somewhere along the 180 degrees. I can draw a straight line from where he lets the finger go to the target. But that will not feel realistic because even a throw completely to the right will end up in range of sight if you know what I mean.

Please ask a question if you don't understand what I mean at any point.

alt text

untitled.png (3.8 kB)
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

0 Replies

· Add your reply
  • Sort: 

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.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

2 People are following this question.

avatar image avatar image

Related Questions

Jump to position (Worms style) 1 Answer

position coins in parabolic path 1 Answer

How to have player fire projectile in a parabola? 4 Answers

How To Calculate Speed For Projectile Based On Target Distance And Height 1 Answer

Parabolic movement doing strange things with certain angles 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