Page MenuHome

Particle hair - Python API is not respected when using DupliObjects & hair
Closed, InvalidPublic


System Information
Windows 7 x64 GTX580

Blender Version
Broken: b0a7e77

Short description of error
We are trying to manually set the location / rotation of particle hair with the dupliobject function.

We have set the location of the particle via

bpy.context.active_object.particle_systems[0].particles[0].location = [10,10,0]

and this responds out correctly when no dupliobject is selected.. when dupliobject is selected, the dupliobject location goes back to where it was first generated.. Removing the dupliobject again moves the particle back to where it should be.

Ideally the dupliobjects should follow the location and rotation set via python.

Checking the particle location via python responds out correctly using the print command, whether the dupiobject is selected or not (in the attached file it is always 10,10,0)

Exact steps for others to reproduce the error

  1. open attached blend file
  2. notice where the particle is
  3. set dupli object to suzanne
  4. notice how suzanne isnt in the right location
  5. check particle location via the python script

Event Timeline

Bastien Montagne (mont29) changed the task status from Unknown Status to Unknown Status.Apr 1 2016, 1:22 PM
Bastien Montagne (mont29) claimed this task.

Yeah… In fact I think those attributes should be read-only, they are data that get regenerated every time the system is recomputed (just e.g. move the plane, and you lose your custom particle transform…). Point being, that part is more or less broken/half-functional, and needs a complete redesign from scratch. Until this happen, we can only fix serious issues (or those easy to tackle)… Thanks for the report anyway.

Just wanting to poke this archived issue, to flag for the upcoming blender 2.8 particle rewrite that is potentially happening. It would be extremely useful to be able to manipulate particle systems via python