Hot answers tagged

2

The answer to your question is: no, as long as the system you're referring to implies no friction, there are no external forces, and the material the two ball are made of can be ignored. In Classical Mechanics, the linear momentum of a body (any object) is defined as mass times velocity, p = mv, and it is a vector, so that you can consider the linear ...


2

If you want to stop a physics object from moving, you need to zero the forces and the velocity of the RigidBody. rb.velocity = new Vector3(0,0,0); For zeroing the force, you can apply a force opposite to the forces you've added that frame already. However, I'd suggest simply not adding those forces if you're stopping. It means a slight rearrangement of ...


1

The clearest way to make sense of any equation is to figure out the units. In this case, it's a bit ambiguous, but you know that velocity is m/h and that radius would be some kind of distance. v^2 is a good assumption in this case, but it is not immediately obvious why without knowing something about the units of the denominator. Just by looking at this, ...


1

The code provided by Ilmari Karonen is almost correct, but there is a slight glitch. You actually compute the acceleration 2 times per tick, this does not follow the textbook equations. acceleration = force(time, position) / mass; // Here time += timestep; position += timestep * (velocity + timestep * acceleration / 2); newAcceleration = force(time, ...


1

This is actually a multi-particle system based game. The position of the mouse cursor is used to determine the X and Y of the plane. This is done by splitting the screen into quads. Each quad giving the negative and positive values for each axis. Mouse_X = MousePosition.X - (1023 / 2) Mouse_Y = MousePosition.Y - (767 / 2) The plane on the other hand is ...


1

Physical 4 State Linear Translation---------- FORCE- The amount of force the ball was hit.(kg) ACCELERATION- That same force divided by the mass of the ball (Force/Mass) VELOCITY- Acceleration over time is Velocity (Force/Mass)*T POSITION- Velocity over time changes the position (Force/Mass)*T^2 DIRECTION Position is determined by direction on ...


1

Assuming that you mean the x,y passed in is the point on the ball that you hit. A bit like the cue position when you hit a ball with a snooker cue. You can do it with a bit of vector maths. // create direction vector for ball to go. var dirX = ball.centerX - x; var dirY = ball.centerY - y; // convert dir to unit vector. this'll make it ...



Only top voted, non community-wiki answers of a minimum length are eligible