if (y < (scr_get_box(5) + 75)) { if (hspeed < 0 && x <= (scr_get_box(4) - 64) && !bounce) { x = scr_get_box(4) - 64; memspeed = hspeed * -1; memspeed2 = vspeed * 0.5; hspeed = -2; vspeed = 0; bounce = true; snd_play(snd_petaldrain); } if (hspeed > 0 && x >= (scr_get_box(4) + 64) && !bounce) { x = scr_get_box(4) + 64; memspeed = hspeed * -1; memspeed2 = vspeed * 0.5; hspeed = 2; vspeed = 0; bounce = true; snd_play(snd_petaldrain); } } else { image_alpha -= 0.05; } if (bounce) { timer = scr_approach(timer, pi, 0.7853981633974483); image_xscale = 2 - (sin(timer) * 1); image_yscale = 2 + (sin(timer) * 1); if (timer == 2.356194490192345) { hspeed = memspeed; vspeed = memspeed2; } if (timer == pi) { bounce = false; timer = 0; } } if (image_alpha == 0) instance_destroy();