ksys: Change isSensorLayer to getContactLayerType

The == 0 and == 1 comparisons suggest that the function actually
returns a ContactLayerType rather than a boolean
This commit is contained in:
Léo Lam
2021-12-15 11:21:13 +01:00
parent c0a24e1611
commit fb8f0c636e
5 changed files with 9 additions and 6 deletions
@@ -2,8 +2,10 @@
namespace ksys::phys {
u32 isSensorLayer(ContactLayer layer) {
return layer > ContactLayer::EntityEnd;
ContactLayerType getContactLayerType(ContactLayer layer) {
if (layer > ContactLayer::EntityEnd)
return ContactLayerType::Sensor;
return ContactLayerType::Entity;
}
u32 makeContactLayerMask(ContactLayer layer) {