-- -- Silage Plate -- -- @author Manuel L. -- @date 27/03/2010 -- SilagePlate = {}; function SilagePlate.prerequisitesPresent(specializations) return SpecializationUtil.hasSpecialization(Attachable, specializations); end; function SilagePlate:load(xmlFile) self.plate = Utils.indexToObject(self.components, getXMLString(xmlFile, "vehicle.silagePlate#plate")); --self.forks = Utils.indexToObject(self.components, getXMLString(xmlFile, "vehicle.silagePlate#forks")); end; function SilagePlate:delete() end; function SilagePlate:mouseEvent(posX, posY, isDown, isUp, button) end; function SilagePlate:keyEvent(unicode, sym, modifier, isDown) end; function SilagePlate:update(dt) if self:getIsActive() then if self.plate ~= nil then if InputBinding.hasEvent(InputBinding.IMPLEMENT_EXTRA2) then setVisibility(self.plate, not getVisibility(self.plate)); --setVisibility(self.forks, not getVisibility(self.forks)); end end; end; end; function SilagePlate:draw() g_currentMission:addHelpButtonText(string.format(g_i18n:getText("toggle_Plate"), self.typeDesc), InputBinding.IMPLEMENT_EXTRA2); if g_currentMission.attachableInMountRange ~= nil then g_currentMission.hudAttachmentOverlay:render(); end; end;