chore: unroll

This commit is contained in:
cha0s 2019-05-01 20:06:05 -05:00
parent 07a0cfea63
commit 4a28cabc26

View File

@ -41,8 +41,10 @@ export class Damaging extends Trait {
const isCollidingWith = this.entity.isCollidingWith;
for (let i = 0; i < isCollidingWith.length; i++) {
const entity = isCollidingWith[i];
if (entity.is('vulnerable') && !entity.isInvulnerable) {
entity.takeDamageFrom(this.entity);
if (entity.is('vulnerable')) {
if (!entity.isInvulnerable) {
entity.takeDamageFrom(this.entity);
}
}
}
}