How do I use collisions when I don't want my objects to be moveable?
After doing some testing this afternoon, I was surprised to find that having the 'Collisions' option turned on doesn't actually do anything unless the object in question is set to moveable.
I'm making a 2d game in which I don't want to use any of the in-built physics, my objects ignore gravity and only move when manipulated by the game logic. However, if I turn on 'Moveable' then I have to start giving everything gyroscopes and followers to keep them where I want them. I don't want to do this but I do want things to collide with each other.
Is there a way to do this with the 'Collision' option without having them moveable or do I just have to make my own colliders with trigger zones (which to be honest would kind of ruin my game mechanics :()?
-
"Collidable" means things can collide with it. "Movable" means it moves physically--for example in response to collisions. Collision reactions are all part of the physics simulation, so I don't think there is any way of divorcing the two.
So I'd recommend just turning on "movable," and adding a separate actually-collidable object such as a cylinder so it will stop hitting things. But if the ground is flat (which I'm guessing might be the case) then the flat bottom of the cylinder will just coast along it (if you give it low friction maybe), and shouldn't ever bounce funny and become angled. Hope this helps. -
I'm having trouble to, I simply want to do something like, if the player run into a tree it can't go throught it, for now I have the options of goingthough or hiting the tree and make it slide away :/
댓글을 남기려면 로그인하세요.