mirror of
https://github.com/pagefaultgames/pokerogue.git
synced 2025-02-17 01:37:36 +00:00
Ignore erroring modifiers when loading session
This commit is contained in:
parent
eae0d907c5
commit
2d1fabdc03
@ -32,6 +32,7 @@ export default class ModifierData {
|
|||||||
if (!typeFunc)
|
if (!typeFunc)
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
|
try {
|
||||||
let type = typeFunc();
|
let type = typeFunc();
|
||||||
type.id = this.typeId;
|
type.id = this.typeId;
|
||||||
type.generatorId = this.typeGeneratorId;
|
type.generatorId = this.typeGeneratorId;
|
||||||
@ -45,5 +46,9 @@ export default class ModifierData {
|
|||||||
ret.stackCount = ret.getMaxStackCount(scene);
|
ret.stackCount = ret.getMaxStackCount(scene);
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
} catch (err) {
|
||||||
|
console.error(err);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
x
Reference in New Issue
Block a user