diff --git a/server/gameserver/obstacle.cc b/server/gameserver/obstacle.cc index c6a4c3d3..a76e802d 100644 --- a/server/gameserver/obstacle.cc +++ b/server/gameserver/obstacle.cc @@ -616,7 +616,7 @@ bool Obstacle::CanThroughable(Creature* c) return false; } -bool Obstacle::CanThroughable(Bullet* bullet) +bool Obstacle::CanThroughable(IBullet* bullet) { switch (meta->i->bullet_hit()) { case kBulletHitPass: @@ -627,7 +627,7 @@ bool Obstacle::CanThroughable(Bullet* bullet) case kBulletHitOnlySpecDmg: { return !(meta->receive_special_damage_type != 0 && - ((bullet->gun_meta->special_damage_type & meta->receive_special_damage_type) != 0)); + ((bullet->GetGunMeta()->special_damage_type & meta->receive_special_damage_type) != 0)); } break; default: diff --git a/server/gameserver/obstacle.h b/server/gameserver/obstacle.h index 4b2a4575..eb787bee 100644 --- a/server/gameserver/obstacle.h +++ b/server/gameserver/obstacle.h @@ -46,7 +46,7 @@ class Obstacle : public Entity virtual void OnExplosionHit(Explosion* explosion) override; virtual bool Attackable(Room* room) override; virtual bool CanThroughable(Creature* c); - virtual bool CanThroughable(Bullet* bullet); + virtual bool CanThroughable(IBullet* bullet); virtual bool DoInteraction(Human* sender); virtual int OnCollisionTrigger(Creature* c, ColliderComponent* collider); virtual bool CanSeeMe(Human* hum);