diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2018-04-13 12:37:55 +0200 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2018-04-13 12:37:55 +0200 |
commit | cf7c38f58f350350580241fae7f5543e44b5d1ad (patch) | |
tree | 2e28c61afd9bc7a612bf2198705400274eb08b28 /src/game/unit_soldier.cpp | |
parent | 2cada8d93653324cb90fc81d4eb670bab9af089a (diff) |
Breakable decos.
Diffstat (limited to 'src/game/unit_soldier.cpp')
-rw-r--r-- | src/game/unit_soldier.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/game/unit_soldier.cpp b/src/game/unit_soldier.cpp index c6ed4dd..433f88d 100644 --- a/src/game/unit_soldier.cpp +++ b/src/game/unit_soldier.cpp @@ -107,10 +107,8 @@ void unit_soldier_t::shoot(v2f_t aim) assets::soldier.fire.play_3d(x); if (trace.hit && trace.ent) { - if (trace.ent->type == ET_UNIT) { - unit_t *unit = dynamic_cast<unit_t*>(trace.ent); - unit->damage(3, this); - } + entity_t *ent = dynamic_cast<entity_t*>(trace.ent); + ent->damage(3, this); } } |