Skip to content

Commit ae72c8b

Browse files
committed
Hide entities we don't handle for now
1 parent 7afd829 commit ae72c8b

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

src/demo_player.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ use tf_demo_parser::{
2323
use weapons::Weapon;
2424

2525
const SECTION_SIZE: usize = 1024;
26+
const SHOW_UNKNOWN_ENTITIES: bool = false;
2627

2728
#[derive(Debug, Serialize)]
2829
enum Command {
@@ -648,8 +649,10 @@ impl DemoAnalyzer {
648649
| "CTFWrench" => self.handle_weapon(entity),
649650

650651
_ => {
651-
let class_name = class_name.into();
652-
self.handle_unknown_entity(entity, class_name);
652+
if SHOW_UNKNOWN_ENTITIES {
653+
let class_name = class_name.into();
654+
self.handle_unknown_entity(entity, class_name);
655+
}
653656
}
654657
}
655658
}

0 commit comments

Comments
 (0)