bspinfo: don't crash if light data is missing
This commit is contained in:
parent
fe5ce3765a
commit
54ada5be6d
|
|
@ -400,6 +400,10 @@ static void export_obj_and_lightmaps(const mbsp_t &bsp, const bspxentries_t &bsp
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (bsp.dlightdata.empty()) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
auto in_pixel =
|
auto in_pixel =
|
||||||
bsp.dlightdata.begin() + rect.lightofs + (rect.extents.numsamples() * (is_rgb ? 3 : 1) * style_index);
|
bsp.dlightdata.begin() + rect.lightofs + (rect.extents.numsamples() * (is_rgb ? 3 : 1) * style_index);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue