Hi, I would like to talk about how you made your conveyor belts. I tried making some a little while ago in Unity and my items just seemed to keep glitching after they moved. I would greatly appreciate it if you could help or show me the way you made yours.
Sure thing, here's the source: https://github.com/daleblackwood/package-delivery/blob/master/Props/Conveyor/Con... The conveyor has a list of kinematic bodies and a speed. The trick here is that they're kinematic and don't collide with other physics objects (at least, not traditionally). The kinematic bodies are added to the list upon collision enter and removed upon exit. The conveyor belt moves each body in the list deltaTime * speed * forwards every frame.
If you need to add rigidbody collisions, I'd recommend using a fixed contraint or axis lock and moving it using an velocitychange of deltaTime * speed * forwards instead.
← Return to game
Comments
Log in with itch.io to leave a comment.
How did you make multiplayer?
It's local only, so I just mapped multiple gamepads. I've made a utility that simplifies the process a bit here: https://github.com/daleblackwood/cookpot
Hi, I would like to talk about how you made your conveyor belts. I tried making some a little while ago in Unity and my items just seemed to keep glitching after they moved. I would greatly appreciate it if you could help or show me the way you made yours.
Thank you,
Mplu3s.
Sure thing, here's the source:
https://github.com/daleblackwood/package-delivery/blob/master/Props/Conveyor/Con...
The conveyor has a list of kinematic bodies and a speed. The trick here is that they're kinematic and don't collide with other physics objects (at least, not traditionally). The kinematic bodies are added to the list upon collision enter and removed upon exit. The conveyor belt moves each body in the list deltaTime * speed * forwards every frame.
If you need to add rigidbody collisions, I'd recommend using a fixed contraint or axis lock and moving it using an velocitychange of deltaTime * speed * forwards instead.
So sorry haven't been on my itch in a while, thank you for the reply I will be sure to look into this method.
Thank you
Mplu3s.
Congratulations. Nice game. One thing, I tried to play with my joy-con, but it didn't work.