A
Arkanio
Guest
Using Game Maker Studio 2
ok for a little bit of context i'm doing a game of puzzle where you have to switch between dimension to get to impossible places and since there is particle in dimension 1 when you switch of dimension (dimension 2) we can see the particle disappear but slowly and i want them to disappear instantly (totally not see them disappear)
i set the part_particles_clear but it dont work :/
here's the code
________________________________________________________________________________________
Create Event :
alarm[0] = 3
alarm[1] = 10
CorruptedSmokeSys = part_system_create()
CorruptedSmokePart = part_type_create()
part_type_sprite(CorruptedSmokePart,SSmoke,0,0,0)
part_type_life(CorruptedSmokePart,60,120)
part_type_size(CorruptedSmokePart,1,0.5,0,0)
part_type_direction(CorruptedSmokePart,0,0,0,0)
part_type_speed(CorruptedSmokePart,0.2,0.4,0,0)
part_type_alpha3(CorruptedSmokePart,0,0.1,0)
MyEmitter = part_emitter_create(CorruptedSmokeSys)
part_emitter_region(CorruptedSmokeSys,MyEmitter,x-32,x+32,y-32,y+32,ps_shape_rectangle, ps_distr_linear)
CorruptedSmokeSysL = part_system_create()
CorruptedSmokePartL = part_type_create()
part_type_sprite(CorruptedSmokePartL,SSmoke,0,0,0)
part_type_life(CorruptedSmokePartL,60,120)
part_type_size(CorruptedSmokePartL,1,0.5,0,0)
part_type_direction(CorruptedSmokePartL,180,180,0,0)
part_type_speed(CorruptedSmokePartL,0.2,0.4,0,0)
part_type_alpha3(CorruptedSmokePartL,0,0.1,0)
MyEmitterL = part_emitter_create(CorruptedSmokeSysL)
part_emitter_region(CorruptedSmokeSysL,MyEmitterL,x-32,x+32,y-32,y+32,ps_shape_rectangle, ps_distr_linear)
FlameSys = part_system_create()
FlamePart = part_type_create()
part_system_depth(FlamePart,layer_get_depth(layer_get_id("CorruptedBG")))
part_type_sprite(FlamePart,sprite82,0,0,1)
part_type_life(FlamePart,60,180)
part_type_size(FlamePart,1,0.5,0,0)
part_type_direction(FlamePart,90,90,0,0)
//part_type_orientation(FlamePart,-25,-25,0,0,0)
part_type_speed(FlamePart,0.5,0.8,0,0)
part_type_alpha3(FlamePart,0,1,0)
part_system_layer(FlameSys, layer_get_id("CorruptedParticles"));
MyEmitterF = part_emitter_create(FlameSys)
part_emitter_region(FlameSys,MyEmitterF,x-32,x+32,y-32,y+32,ps_shape_rectangle, ps_distr_linear)
__________________________________________________________________________________
alarm 0 event :
alarm[0] = 3
part_emitter_burst (CorruptedSmokeSys, MyEmitter, CorruptedSmokePart,1)
part_emitter_burst (CorruptedSmokeSysL, MyEmitterL, CorruptedSmokePartL,1)
__________________________________________________________________________________
alarm 1 event :
alarm[1] = 60
part_emitter_burst (FlameSys, MyEmitterF, FlamePart, 1)
___________________________________________________________________________________
Press A (the key to switch the dimension : (also when you press A global.dimension switch between 0 and 1)
if global.dimension != 0
{
part_particles_clear(CorruptedSmokeSys)
part_emitter_clear(CorruptedSmokeSys,MyEmitter)
part_particles_clear(CorruptedSmokeSysL)
part_emitter_clear(CorruptedSmokeSysL,MyEmitterL)
part_particles_clear(FlameSys)
part_emitter_clear(FlameSys,MyEmitterF)
}
ok for a little bit of context i'm doing a game of puzzle where you have to switch between dimension to get to impossible places and since there is particle in dimension 1 when you switch of dimension (dimension 2) we can see the particle disappear but slowly and i want them to disappear instantly (totally not see them disappear)
i set the part_particles_clear but it dont work :/
here's the code
________________________________________________________________________________________
Create Event :
alarm[0] = 3
alarm[1] = 10
CorruptedSmokeSys = part_system_create()
CorruptedSmokePart = part_type_create()
part_type_sprite(CorruptedSmokePart,SSmoke,0,0,0)
part_type_life(CorruptedSmokePart,60,120)
part_type_size(CorruptedSmokePart,1,0.5,0,0)
part_type_direction(CorruptedSmokePart,0,0,0,0)
part_type_speed(CorruptedSmokePart,0.2,0.4,0,0)
part_type_alpha3(CorruptedSmokePart,0,0.1,0)
MyEmitter = part_emitter_create(CorruptedSmokeSys)
part_emitter_region(CorruptedSmokeSys,MyEmitter,x-32,x+32,y-32,y+32,ps_shape_rectangle, ps_distr_linear)
CorruptedSmokeSysL = part_system_create()
CorruptedSmokePartL = part_type_create()
part_type_sprite(CorruptedSmokePartL,SSmoke,0,0,0)
part_type_life(CorruptedSmokePartL,60,120)
part_type_size(CorruptedSmokePartL,1,0.5,0,0)
part_type_direction(CorruptedSmokePartL,180,180,0,0)
part_type_speed(CorruptedSmokePartL,0.2,0.4,0,0)
part_type_alpha3(CorruptedSmokePartL,0,0.1,0)
MyEmitterL = part_emitter_create(CorruptedSmokeSysL)
part_emitter_region(CorruptedSmokeSysL,MyEmitterL,x-32,x+32,y-32,y+32,ps_shape_rectangle, ps_distr_linear)
FlameSys = part_system_create()
FlamePart = part_type_create()
part_system_depth(FlamePart,layer_get_depth(layer_get_id("CorruptedBG")))
part_type_sprite(FlamePart,sprite82,0,0,1)
part_type_life(FlamePart,60,180)
part_type_size(FlamePart,1,0.5,0,0)
part_type_direction(FlamePart,90,90,0,0)
//part_type_orientation(FlamePart,-25,-25,0,0,0)
part_type_speed(FlamePart,0.5,0.8,0,0)
part_type_alpha3(FlamePart,0,1,0)
part_system_layer(FlameSys, layer_get_id("CorruptedParticles"));
MyEmitterF = part_emitter_create(FlameSys)
part_emitter_region(FlameSys,MyEmitterF,x-32,x+32,y-32,y+32,ps_shape_rectangle, ps_distr_linear)
__________________________________________________________________________________
alarm 0 event :
alarm[0] = 3
part_emitter_burst (CorruptedSmokeSys, MyEmitter, CorruptedSmokePart,1)
part_emitter_burst (CorruptedSmokeSysL, MyEmitterL, CorruptedSmokePartL,1)
__________________________________________________________________________________
alarm 1 event :
alarm[1] = 60
part_emitter_burst (FlameSys, MyEmitterF, FlamePart, 1)
___________________________________________________________________________________
Press A (the key to switch the dimension : (also when you press A global.dimension switch between 0 and 1)
if global.dimension != 0
{
part_particles_clear(CorruptedSmokeSys)
part_emitter_clear(CorruptedSmokeSys,MyEmitter)
part_particles_clear(CorruptedSmokeSysL)
part_emitter_clear(CorruptedSmokeSysL,MyEmitterL)
part_particles_clear(FlameSys)
part_emitter_clear(FlameSys,MyEmitterF)
}