forked from mirror/openmw-tes3mp
Avoid exception if class ID is not found, instead don't show any fields in the gui.
This commit is contained in:
parent
aaa80d1eb0
commit
e6ad68b8d0
1 changed files with 3 additions and 1 deletions
|
@ -240,7 +240,9 @@ void PickClassDialog::updateStats()
|
|||
return;
|
||||
WindowManager *wm = environment.mWindowManager;
|
||||
ESMS::ESMStore &store = environment.mWorld->getStore();
|
||||
const ESM::Class *klass = store.classes.find(currentClassId);
|
||||
const ESM::Class *klass = store.classes.search(currentClassId);
|
||||
if (!klass)
|
||||
return;
|
||||
|
||||
ESM::Class::Specialization specialization = static_cast<ESM::Class::Specialization>(klass->data.specialization);
|
||||
|
||||
|
|
Loading…
Reference in a new issue