YaLTeR / bxt-rs

Fastest video recording and TAS tools for Half-Life & mods.
GNU General Public License v3.0
47 stars 10 forks source link

Panic when loading .hltasproj with no map #108

Closed YaLTeR closed 2 weeks ago

YaLTeR commented 2 weeks ago

It's trying to read player_data() when no map is loaded:

2024-11-10T17:42:39.336115Z ERROR bxt_rs::utils: The application panicked (crashed).
Message:  called `Option::unwrap()` on a `None` value
Location: src/modules/tas_studio/mod.rs:1778
YaLTeR commented 2 weeks ago

I added a check for the panic in 49819e972cf405c98134c0e1c3bc56c7c4059c45, but this should really be fixed in BXT. Because for example this branch doesn't trigger when trying to load a non-existing map from the main menu (rather from an already-loaded map).