import clr
clr.AddReference('Soti.Connect.SemanticEngine.Conversions')

from Soti.Connect.SemanticEngine.Conversions import Converter

print("Loading MicroplexDarknessToPercent Converter")

class MicroplexDarknessToPercent(Converter):
    def Execute(self, args):
        return round(int(100 * (int(int(args[0])-10)) / 110))




plugin = MicroplexDarknessToPercent("MicroplexDarknessToPercent")

store.AddConverter(plugin)