LUADOC - Farming Simulator 19

Script v1.7.1.0

Engine v1.7.1.0

Foundation Reference

CylinderedFoldable

Description
Specialization to repeat the loading of cylindered states after the folding state was loaded, in case the animation overlaps with the moving tools
Functions

onPostLoad

Description
Definition
onPostLoad()
Code
29function CylinderedFoldable:onPostLoad(savegame)
30 if Utils.getNoNil(getXMLBool(self.xmlFile, "vehicle.cylindered#loadMovingToolStatesAfterFolding"), false) then
31 Cylindered.onPostLoad(self, savegame)
32 end
33end

prerequisitesPresent

Description
Checks if all prerequisite specializations are loaded
Definition
prerequisitesPresent(table specializations)
Arguments
tablespecializationsspecializations
Return Values
booleanhasPrerequisitetrue if all prerequisite specializations are loaded
Code
17function CylinderedFoldable.prerequisitesPresent(specializations)
18 return SpecializationUtil.hasSpecialization(Cylindered, specializations) and SpecializationUtil.hasSpecialization(Foldable, specializations)
19end

registerEventListeners

Description
Definition
registerEventListeners()
Code
23function CylinderedFoldable.registerEventListeners(vehicleType)
24 SpecializationUtil.registerEventListener(vehicleType, "onPostLoad", CylinderedFoldable)
25end