CylonSB / bounded-planet

Test Game Please Ignore
6 stars 1 forks source link

Unit selection v2 #63

Closed Jerald closed 3 years ago

Jerald commented 4 years ago

Closes #3.

Uses bevy_rapier to cast rays into object colliders to figure out what's under the cursor on the screen.

Jerald commented 3 years ago

Does Rapier support collision layers? (I.E can we have things have multiple colliders, so this collider would exist on a selection layer, etc.)

In the newest version of rapier it does support these, which it calls collider groups if I recall correctly. Once we do that update we'll be able to do it right. Right now you can select literally anything with a collider, including the ground :P