Deltarune (Chapter 4) script viewer

← back to main script listing

gml_Object_obj_ppfx_motionblur_Step_0

(view raw script w/o annotations or w/e)
1
if (instance_exists(obj_camera))
2
{
3
    var c = obj_camera;
4
    motion_blur_angle = point_direction(c.cam_x, c.cam_y, c.cam_x + c.cam_x_delta, c.cam_y + c.cam_y_delta);
5
    motion_blur_speed = mean(c.cam_x_delta, c.cam_y_delta) * motion_blur_velocity;
6
    ppfx_effect_set_parameter(ppfx_id, PP_EFFECT.MOTION_BLUR, PP_MOTION_BLUR_ANGLE, motion_blur_angle);
7
    ppfx_effect_set_parameter(ppfx_id, PP_EFFECT.MOTION_BLUR, PP_MOTION_BLUR_RADIUS, motion_blur_speed);
8
}