Hi all!
I've made some easy simulation about moving particles, it was very interesting to unterstand how to use cache grid to make such simulations faster.
The first version without collisions, but squares show where I need to check this collisions
Yellow: no collision, green: two circle bodies in this grid square.
Particle collisions (with cache)
Particle collisions (with cache)
- Attachments
-
- particle-collisions-01.love
- (1.36 KiB) Downloaded 338 times
Last edited by darkfrei on Sun May 02, 2021 5:39 pm, edited 1 time in total.
Re: [WIP] Particle collisions (with cache)
Second version:
Added collision detection (red).
Added collision detection (red).
- Attachments
-
- particle-collisions-02.love
- (2.08 KiB) Downloaded 326 times
Re: [WIP] Particle collisions (with cache)
The last version, all collisions work as expected.
Here can be better static resolution: move circles back to the collision, calculate the rest dt and move particles in the new direction. Same as continuous collision detection.
Here can be better static resolution: move circles back to the collision, calculate the rest dt and move particles in the new direction. Same as continuous collision detection.
- Attachments
-
- particle-collisions-03.love
- (2.16 KiB) Downloaded 314 times
Re: Particle collisions (with cache)
hi,i am from china , your game its the only one i can understand in this fourm, its very helpul ,i must say thanks to you
Re: Particle collisions (with cache)
Thanks! I am learning how to code and I've made alot of small programs: https://github.com/darkfrei/love2d-lua-tests
Who is online
Users browsing this forum: No registered users and 1 guest