View difference between Paste ID: PYqMzWnr and 8iKFH70C
SHOW: | | - or go back to the newest paste.
1
///Shadow
2
var max_length=96;
3
4
for (var i=0; i<max_length; i++)
5
{
6
  var ly=y+lengthdir_y(i,270);
7
  if (collision_point(x,ly,obj_wall,true,true))
8
    break;
9
}
10
shadow_size=(max_length/i)/4;
11
if (i<64)
12
{
13
draw_sprite_ext(sprite_index,image_index,x,ly-2,
14
shadow_size*image_xscale,-shadow_size/4,0,c_black,0.4)
15
}
16
draw_self();