New answers tagged physics
1
vote
Accepted
Best way to implement a carrying tray in VR using Unity
I have found a suitable solution using both Unity's built-in materials and a script that uses a trigger as a parent modifier.
Both the tray's and mug's collider has a material attached that raises ...
2
votes
Best way to implement a carrying tray in VR using Unity
It sounds like you've already figured out the solution:
I'm thinking of some kind of magnet-like system where if you drop an item onto the tray, it becomes stuck until you manually take it off.
From ...
1
vote
How do I Rigidbody.AddForce(Vector3) in Unreal Engine?
If you want to add a one-time force to the object you should use the AddImpulse function instead of the AddForce, because AddForce applies a force continually.
To use the AddImpulse function you need ...
0
votes
Handling movement on sloped surfaces - clamping character to sloped surface
This is a very easy solve. All you have to do is apply a downward force if you are in the air. First, you have to detect if you are actually on a slope, assuming you have a "jump" in your ...
0
votes
Getting the scalar speed from an X and Y velocity
Was able to get the answer as:
let speed = Math.sqrt(velocity.x ** 2 + velocity.y ** 2)
1
vote
OnCollisionStay outputs strange contactpoints
What ended up being my issue is that OnCollisionStay() can call multiple times per FixedUpdate. It actually calls per collision. So my collider had two collisions, making my contact point counter ...
1
vote
Bouncing balls miss collisions, bounce the wrong direction, of lose momentum on one axis when hitting a corner
These issues can be solved by calculating the average normal, instead of the first collision normal.
...
3
votes
Bouncing balls miss collisions, bounce the wrong direction, of lose momentum on one axis when hitting a corner
It appears that your code is fighting with the physics engine about who gets to control the velocity vectors of the balls.
When there is a collision between two rigidbodies, then the Unity physics ...
1
vote
Order of updates in falling sand simulation
The default method is to just always process cells from bottom-left to top-right to handle the problem of realistic physics. One particular youtuber MARF has documented his process for this in the ...
0
votes
Implementing proportional navigation in 3D
I know this is a "little" late, but as they say better late than never; so for those still searching for an answer to this topic...
The most simplistic proportional navigation implementation ...
2
votes
Order of updates in falling sand simulation
I don't know much about the technicalities of simulation design, but it seems to me that you could update all the sand-like particles from the bottom up, and then update all the steam-like particles ...
Top 50 recent answers are included
Related Tags
physics × 2367unity × 665
collision-detection × 369
2d × 346
c# × 271
mathematics × 207
box2d × 187
movement × 140
c++ × 132
collision-resolution × 118
physics-engine × 118
rigidbody × 109
java × 101
xna × 95
3d × 86
platformer × 70
rotation × 63
simulations × 61
vector × 59
javascript × 58
libgdx × 55
projectile-physics × 54
rigid-body-dynamics × 52
bullet-physics × 46
opengl × 43