Stwórz sobie obj_pixel_blur;
W create:
GML
t_surf = surface_create(room_width,room_height);
d_surf = surface_create(room_width,room_height);
p_amt = 1; // siła
p_plus = 0.05; // do animacji
p_max = 10; // max do animacji
surface_set_target(d_surf);
draw_clear_alpha(0,0);
screen_redraw();
surface_reset_target();
W end step:
GML
texture_set_interpolation(false); // jak ustawimy interpolacje wyjdzie na blur
surface_set_target(d_surf);
screen_redraw();
surface_set_target(t_surf);
draw_surface_ext(d_surf,0,0,1/p_amt,1/p_amt,0,c_white,1); // dzielenie
surface_set_target(d_surf);
draw_surface_ext(t_surf,0,0,1*p_amt,1*p_amt,0,c_white,1); // mnozenie
surface_reset_target();
if p_amt < p_max p_amt += p_plus; // jak chcesz prosta animke
//p_amt = 5</span>
w droł:
GML
draw_surface_ext(d_surf,0,0,1,1,0,c_white,1);