simplified interpolate move comparison condition

pull/6/head
Sara 2023-06-18 13:15:03 +02:00
parent 0b32967c20
commit e32eb731c2
1 changed files with 1 additions and 2 deletions

View File

@ -195,9 +195,8 @@ object_t* interpolate_move(object_t* object, float target_x, float target_y, flo
for(int i = 0; i < WORLD_NUM_OBJECTS; ++i) { for(int i = 0; i < WORLD_NUM_OBJECTS; ++i) {
// get pointer to other object // get pointer to other object
object_t* other = g_objects + i; object_t* other = g_objects + i;
if(!_can_collide(other)) continue;
// check collision, return if found // check collision, return if found
if(object != other && _collision_check(other, object)) { if(_can_collide(other) && object != other && _collision_check(other, object)) {
other->collider.evt_collision(other, object); other->collider.evt_collision(other, object);
object->collider.evt_collision(object, other); object->collider.evt_collision(object, other);
return other; return other;