Applying collision to multiple meshes via Python
This is a continuation of an old thread from 2014, here:
I’m using the python plugin by Roberto De Loris to generate collisions for multiple meshes (Thanks for the tip ex3me). Source: https://github.com/20tab/UnrealEnginePython
Currently with one mesh selected in the scene, I run the following Python:
This generates no collision and prints the following:
I’ve tried with only one mesh or multiple meshes selected and get the same outcome.
Looking at lines 7 and 8 where I guess the action is supposed to be I see nothing but variable assignments so I’m not sure how this supposed to do anything anyway!
I’m kinda stumped!
Any help much appreciated!
asked Jul 11 '18 at 03:16 PM in Using UE4
Hey, me again :)
It seems the error you are getting on line 11 is caused by not passing enough parameters to function set_field(). As a first parameter you should pass the name of the field (string, as you do) and the second parameter should be the object (value) you are setting.
I assume second parameter should be the collision object you want to set. I think this piece of code should help you to generate some of the basic kdop collision objects available in UE: https://github.com/20tab/UnrealEnginePython/blob/master/examples/kdop.py
Hope it helps.
answered Jul 11 '18 at 03:47 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here