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 Castino · Oct 16, 2011 at 03:37 AM · physicsgravityballbounce

Bouncy Ball Game

Hi folks, I'm trying to create a game where a player has to keep a ball bouncing up and down while having control of a paddle. It's a little like BreakOut apart from the fact that I would like the player to have to play keepy-uppy with the ball and dodge falling objects.

As an example of how the game would start off; the ball will fall at a fairly slow pace of say, 1 (using gravity, but if you can think of a better way then please, let me know =]) and when the player hits the ball with the paddle, it bounces back up. Once again this would still be at a fairly slow pace but goes quite high (around 5 units on the Y).

As the game progresses I would like the gravity to be higher, so about 10 near the end and the force from the bounce to be smaller so the ball doesn't bounce as high so it can come down faster.

I've tried a few different way of doing it and each time something else goes wrong. using the bouncy physics isn't very good for this because it only increases the height of the ball as it bounces and I can see no way to make it the opposite...unless I have missed it somewhere.

Any help is most welcome and it can be written in C# or JS.

Regards,

Cas

Comment
Add comment · Show 3
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 syclamoth · Oct 16, 2011 at 03:51 AM 0
Share

I wouldn't use physics for this kind of game. It'd really be simpler to either write your own simplified physics engine or just use transform.translate with basic collision detection. As for the gravity thing, I don't quite understand what you're talking about- the force from the bounce is directly proportional to the incident force! If it strikes the paddle harder, it will naturally bounce higher. Unless, of course, you are using some kind of exotic physics.

avatar image Castino · Oct 16, 2011 at 07:50 PM 0
Share

Ok, cheers. With regards to the ball bouncing higher; I meant that if I used the bouncy physics and dropped it from a height of 5 it would bounce back to 5, second bounce = 5.2, third bounce = 5.4 and so on. Surely if something is dropped it will lose height for each bounce it does, not gain height unless it has extra forces added to it on the way down....

avatar image syclamoth · Oct 16, 2011 at 11:36 PM 0
Share

That's what I thought... If you turn the bounciness down, it should act more naturally.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by morrison · Oct 17, 2011 at 06:56 AM

I actually just got a book for class called Unity 3D Game Development by Example that teaches you how to make the exact game you want to make. It's actually pretty basic and fun to make.

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

4 People are following this question.

avatar image avatar image avatar image avatar image

Related Questions

How could I make a bouncy object move mostly along the Z axis? 1 Answer

Ball bouncing up after rolling over a cliff when it should be rolling down? 0 Answers

Why does a rolling ball not accelerate past a slow speed? 1 Answer

Bounce ball with constant speed and height. 0 Answers

Constant force, with gravity, and correct collisions. 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