Particle depth not changing

Toxic Tom

Member
I've created a particle system and emitted some particles (I've tried this by directly creating the particles and by using an emitter).

Code:
globalvar particleSystem, bloodParticle, bloodEmitter;

particleSystem=part_system_create();
part_system_depth(particleSystem, -1);
bloodParticle=part_type_create();
part_type_shape(bloodParticle,pt_shape_pixel);          
part_type_size(bloodParticle,1,10,0,2);            
part_type_scale(bloodParticle,1,1);                     
part_type_color1(bloodParticle,c_red);               
part_type_alpha1(bloodParticle,1);                    
part_type_speed(bloodParticle,0.50,20,-0.10,0);           
part_type_direction(bloodParticle,0,359,0,20);          
part_type_orientation(bloodParticle,0,0,0,0,1);          
part_type_blend(bloodParticle,1);                        
part_type_life(bloodParticle,1,20);                       
bloodEmitter=part_emitter_create(particleSystem);
then to create the particles:
Code:
repeat(50)
{
    var xx = phy_position_x + 20 - random(40);
    var yy = phy_position_y + 20 - random(40);
    part_particles_create(particleSystem, xx, yy, bloodParticle, 1);
}
or

Code:
part_emitter_region(particleSystem, bloodEmitter, x, x, y, y, ps_shape_ellipse, ps_distr_linear);
part_emitter_burst(particleSystem, bloodEmitter, bloodParticle, 50);
And the particles are drawn behind the depth 0 objects. Why is this?
 
Top