Page MenuHome

The number of particles is always 0
Closed, ArchivedPublic

Description

System Information
Operating system: Windows 7 64 bit
Graphics card: -

Blender Version
2.80, ae977d13f8e9, blender2.8, 2019-03-03

Short description of error
len (particlers) always returns 0

Exact steps for others to reproduce the error
Open the blend file and run the script in the text editor window.

Details

Type
Bug

Event Timeline

Jacques Lucke (JacquesLucke) closed this task as Archived.
Jacques Lucke (JacquesLucke) claimed this task.

Afaik the particles are no longer stored directly in the object.
Instead they are stored in the evaluated object, which is basically a copy the depsgraph made.

You can access the particles like this:

import bpy

object = bpy.context.active_object
evaluated_object = bpy.context.depsgraph.objects.get(object.name)
print(len(evaluated_object.particle_systems[0].particles))