From 90bc97688e6e19fb7ec04d7fe2be09928a498bd6 Mon Sep 17 00:00:00 2001 From: BrandonPacewic Date: Thu, 20 Jun 2024 13:25:59 -0700 Subject: [PATCH] Formatting --- .../src/Parser/ExporterOptions.py | 6 ++++-- .../SynthesisFusionAddin/src/UI/ConfigCommand.py | 16 +++++++++++----- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/exporter/SynthesisFusionAddin/src/Parser/ExporterOptions.py b/exporter/SynthesisFusionAddin/src/Parser/ExporterOptions.py index fe26fb48f5..ac13c7823f 100644 --- a/exporter/SynthesisFusionAddin/src/Parser/ExporterOptions.py +++ b/exporter/SynthesisFusionAddin/src/Parser/ExporterOptions.py @@ -36,7 +36,7 @@ class Joint: signalType: SignalType = field(default=None) speed: float = field(default=None) force: float = field(default=None) - + @dataclass class Gamepiece: @@ -85,7 +85,9 @@ class ExporterOptions: joints: list[Joint] = field(default=None) gamepieces: list[Gamepiece] = field(default=None) preferredUnits: PreferredUnits = field(default=PreferredUnits.IMPERIAL) - robotWeight: float = field(default=0.0) # Always stored in kg regardless of 'preferredUnits' + robotWeight: float = field( + default=0.0 + ) # Always stored in kg regardless of 'preferredUnits' compressOutput: bool = field(default=True) exportAsPart: bool = field(default=False) diff --git a/exporter/SynthesisFusionAddin/src/UI/ConfigCommand.py b/exporter/SynthesisFusionAddin/src/UI/ConfigCommand.py index db39c8de71..4bb2ad5d2d 100644 --- a/exporter/SynthesisFusionAddin/src/UI/ConfigCommand.py +++ b/exporter/SynthesisFusionAddin/src/UI/ConfigCommand.py @@ -402,7 +402,9 @@ def notify(self, args): ) for wheel in exporterOptions.wheels: - wheelEntity = gm.app.activeDocument.design.findEntityByToken(wheel.jointToken)[0] + wheelEntity = gm.app.activeDocument.design.findEntityByToken( + wheel.jointToken + )[0] typeWheel = type(wheelEntity) addWheelToTable(wheelEntity) @@ -1182,8 +1184,10 @@ def notify(self, args): _exportWheels.append( Wheel( WheelListGlobal[row - 1].entityToken, - wheelTypeIndex + 1, # TODO: More explicit conversion to 'enum' - Brandon - signalTypeIndex + 1, # TODO: More explicit conversion to 'enum' - Brandon + wheelTypeIndex + + 1, # TODO: More explicit conversion to 'enum' - Brandon + signalTypeIndex + + 1, # TODO: More explicit conversion to 'enum' - Brandon # onSelect.wheelJointList[row-1][0] # GUID of wheel joint. if no joint found, default to None ) ) @@ -1219,7 +1223,8 @@ def notify(self, args): Joint( JointListGlobal[row - 1].entityToken, JointParentType.ROOT, - signalTypeIndex + 1, # TODO: More explicit conversion to 'Enum' - Brandon + signalTypeIndex + + 1, # TODO: More explicit conversion to 'Enum' - Brandon jointSpeed, jointForce / 100.0, ) # parent joint GUID @@ -1243,7 +1248,8 @@ def notify(self, args): Joint( JointListGlobal[row - 1].entityToken, parentJointToken, - signalTypeIndex + 1, # TODO: More explicit conversion to 'Enum' - Brandon + signalTypeIndex + + 1, # TODO: More explicit conversion to 'Enum' - Brandon jointSpeed, jointForce, )