improvement(actor): ignore by default collision with actor own hitboxes

This commit is contained in:
Kazhnuz 2019-06-23 15:32:25 +02:00
parent 5c5b3eed34
commit 3314f1e3f9

View file

@ -87,7 +87,10 @@ end
function BaseActor:setFilter() function BaseActor:setFilter()
-- Init the bump filter -- Init the bump filter
self.filter = function(item, other) self.filter = function(item, other)
if (other.isSolid) then if (other.owner == self) then
-- ignore every collision with our own hitboxes
return nil
elseif (other.isSolid) then
return "slide" return "slide"
else else
return "cross" return "cross"