Added null protected to playerLevelFulfillsQuestRequirement()
This commit is contained in:
parent
5107aeeeee
commit
c90b8670f2
@ -215,6 +215,12 @@ export class QuestController
|
|||||||
*/
|
*/
|
||||||
protected playerLevelFulfillsQuestRequirement(quest: IQuest, playerLevel: number): boolean
|
protected playerLevelFulfillsQuestRequirement(quest: IQuest, playerLevel: number): boolean
|
||||||
{
|
{
|
||||||
|
if (!quest.conditions)
|
||||||
|
{
|
||||||
|
// No conditions
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
const levelConditions = this.questConditionHelper.getLevelConditions(quest.conditions.AvailableForStart);
|
const levelConditions = this.questConditionHelper.getLevelConditions(quest.conditions.AvailableForStart);
|
||||||
if (levelConditions.length)
|
if (levelConditions.length)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user