Sign in to follow this  

creating realistic effect of a ball hitting a net

This topic is 2342 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I think this thread belongs to this forum, it is related to Physics.

I want to create realistic effects of a ball hitting a net, or say, like a football hitting the net in the goal, or a tennis ball hitting the net in a tennis court, the net moving, stretching, and coming back etc. And i am using Unity.

I have an idea of how to do this, but since i am new to game development, i wanted to discuss it before i do anything. Here is how I think i can accomplish it:

I should create the net in sections (square sections) in, say, 3ds max, and create a stretched version of each section as well, smaller the section, the more work required, but it'll make it more realistic.

Then, i need to place the net, and when i detect collision of the ball with any of the net sections, i should move that section back, and replace the sections around it with their stretched versions, and as the ball bounces back, i should replace the stretched sections with the default ones. Collision can be detected, and speed of the ball can be tracked, so i can make changes accordingly.

Is this approach ok? And what are the better ways of doing it and other similar things? It'll be very helpful if someone points me in the right direction of how to achieve it.

And as a second question, how to create a collision of a car, the damage etc?

Share this post


Link to post
Share on other sites
You could simulate the net using 'rigid cloth'.
Implementing this might be a little difficult if this is your first foray into physics programming however.

If you are using a game engine, it might come with cloth physics.
If you are programming in C++ you could use the Bullet Physics Engine ([url="http://bulletphysics.org/wordpress/"]Link[/url]).

As for how to simulate damage to a car, you can simply replace sections of the car with parts that are modeled to look like they have been damaged.

==EDIT==
I now see you're using Unity, which supports cloth physics through NVidia's PhysX. I would use that.

Share this post


Link to post
Share on other sites

This topic is 2342 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this