Skip to content

Commit

Permalink
Added missing gui nil check
Browse files Browse the repository at this point in the history
  • Loading branch information
schwiti6190 committed Apr 8, 2022
1 parent c723223 commit 4ae535b
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion scripts/ai/parameters/AIParameterSettingList.lua
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ function AIParameterSettingList.new(data,vehicle,class,customMt)

self.isDisabled = false
self.isVisible = true
self.setupDone = true

return self
end
Expand Down
2 changes: 1 addition & 1 deletion scripts/gui/CpAIFrameExtended.lua
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ function CpInGameMenuAIFrameExtended:bindCourseGeneratorSettings()
end

function CpInGameMenuAIFrameExtended:updateCourseGeneratorSettings()
if self.courseGeneratorLayout:getIsVisible() then
if self.courseGeneratorLayout and self.courseGeneratorLayout:getIsVisible() then
CpInGameMenuAIFrameExtended.bindCourseGeneratorSettings(self)
FocusManager:loadElementFromCustomValues(self.courseGeneratorLayoutElements)
self.courseGeneratorLayoutElements:invalidateLayout()
Expand Down

0 comments on commit 4ae535b

Please sign in to comment.