Friday, May 6, 2011

UDK Collision Channels Tutorial

Like I mentioned I figured out collisions in UDK as they were really confusing to learn. When I did understand them all came together in an obvious and logical way. I realized it wasn't hard, it's easy... once you understand the logic. 
So here's a quick explanation and example of kActor collisions and I threw in cloth for good measure.

UDK Collision Channels Tutorial from destruct007 on Vimeo.

Text based explanation:
RBChannel = the channel or layer that that RBD is on
Block Rigid Body has to be on
RBCollide With Channel = the channels or layer that the RBD can collide with.

So lets say I want a wall that only my ninja can go through. I put the wall to
RBChannel = Untitled 1
don't worry about what collide with channels the wall has, b/c it won't collide with anything since its not moving, things will only collide with it.
Enemy soldier
RBCollide With Channel = Untitled 1 check box (in addition to other things like default etc)
Ninja has the same setup as Soldier but no Untitled 1 check box and the wall won't exist for him.

Same thing works for cloth but cloth's RBChannel is defaulted to "cloth" logically and you can change that but cloth will collide with everything on its layer.