Solved Reset Scale With Compensate Points?

Hi,

Is there a python equivalent of Reset Scale With Compensate Points command?

Illustration of what it does:

  1. Supposing you have a point in 200cm (in xyz) with the polygon object at 100 (in xyz)
  2. If you reset scale with no compensate, the point will be at 2cm and polygon at 1 scale.
  3. But if you scale with compensate, the point will still be at 200cm and polygon at 1 scale, which is what I'm after.

cbda9028-d764-4a19-9cd3-3938d4fc26bf-image.png

P.S. There is an existing thread regarding the topic but its not resolved. Also its referring to a rig, which has complicated hierarchy. I'm only referring to ,

Hi @bentraje you cna use the SendModelingCommang with the MDATA_RESETSYSTEM_COMPENSATE flag. All settings are explained in Python MCOMAND page. So do to what you are aiming for, you should do:

import c4d

def main() -> None:
    settings = c4d.BaseContainer()
    settings[c4d.MDATA_RESETSYSTEM_COMPENSATE] = True
    settings[c4d.MDATA_RESETSYSTEM_RECURSIVE] = True
    
    res = c4d.utils.SendModelingCommand(command=c4d.MCOMMAND_RESETSYSTEM,
                                    list=[op],
                                    mode=c4d.MODELINGCOMMANDMODE_ALL,
                                    bc=settings,
                                    doc=doc)

    c4d.EventAdd()

if __name__ == '__main__':
    main()

Cheers,
Maxime.

@m_adam

Gotcha. Thanks for the response.
It works but I was kinda looking for the thought process on how to implement it.
Mainly because the command is only limited to scale. I was hoping I can modify it to include also rotation.