Manuel, thanks for taking the time and posting some links. Last night I was reading up on the Matrix and trying wrapping my head around it. I think I was stuck in the wrong area, I was trying to convert a baseObject to a pointObject to do the transformations.I would perfer not to have to open the axis window, but instead handle all this in a Python Function. I will look over the docs and samples to get a better idea of what I need to do.
Thanks again for taking the time to respond to my post!
Hi Everyone, had a question. First I have little Python experience but lots of C# and Objective-C, and C. I have Kitbash libraries that I am trying to create a script to copy to a new document, process the object and export as an OBJ file. The problem that I am having is when I run the command to to open the Center Axis, it opens but continues to execute the code. I thought I might be able to have a MessageDialog pop up to pause the script, which it does, but I can't axis the Axis Center window.
My guess is the best approach is to try and move the axis center to the center of the model but the Y axis to 0.
from c4d import gui
# Welcome to the world of Python
# Script state in the menu or the command palette
# Return True or c4d.CMD_ENABLED to enable, False or 0 to disable
# Alternatively return c4d.CMD_ENABLED|c4d.CMD_VALUE to enable and check/mark
# return True
# Main function
c4d.CallCommand(12107, 12107) # Copy
c4d.CallCommand(12094, 12094) # New Project
c4d.CallCommand(100004821) # Paste
c4d.CallCommand(100004768, 100004768) # Select Children
c4d.CallCommand(16768, 16768) # Connect Objects + Delete
c4d.CallCommand(1010819) # Center Axis
# Execute main()
If anyone can help me, or direct me to documentation that will outline the steps needed to set the axis of the object to the bottom center, the reset of the code to export works fine, but I didn't include it here. Thanks you!