Hi Manuel and @rb_rodrigo,
Many thanks for the tips about the Python console and help with the code. I'm a beginner (not even that!) in scripting, so much appreciated. It works as expected now!
Cheers,
Frederik
Hi Manuel and @rb_rodrigo,
Many thanks for the tips about the Python console and help with the code. I'm a beginner (not even that!) in scripting, so much appreciated. It works as expected now!
Cheers,
Frederik
Hi! I've tried to create a simple Python-script for switching to selections tools using my own "personal" selection settings.. but it doesn't work as I want it to.
For example, when I select the 'Rectangle selection' tool, then I want "Tolerant Selection" to be checked by default. And 'Only Select visible' should be off.. but it doesn't work. The script doesn't change these settings if they are set to something else before.
My script looks like this (below). Would really appreciate if someone could help me with the correct code for this (I don't understand programming, I only copy and paste the code from the Script Log..). Or point me in a direction where I can learn it. Many thanks!
import c4d
from c4d import documents, plugins
#Welcome to the world of Python
def main():
c4d.CallCommand(12139) # Points
c4d.CallCommand(200000084) # Rectangle Selection
tool()[c4d.MDATA_SELECTION_TOLERANCE] = True
tool()[c4d.MDATA_SELECTION_VISIBLE] = False
if __name__=='__main__':
main()
c4d.EventAdd()()