#### trentallain

##### Member

Code:

```
// Look for attack positions
for (var u = _begin_x; u < _end_x+1; u ++) {
for (var v = _begin_y; v < _end_y+1; v ++) {
// If the location is within range
if global.grid_potential_range[# u, v] != -1 {
// If the enemy is at that location
if global.grid_potential_range[# u, v] == 0 {
draw_sprite(spr_grid_hover,2,19+19*u,19+19*v);
}
// If there are no more spaces in range right
if global.grid_potential_range[# u + 1, v] != -1 {
draw_sprite_ext(spr_grid_range_border,0,19+19*u+10,19+19*v+10,1,1,0,c_white,1);
}
// Up
if global.grid_potential_range[# u, v - 1] != -1 {
draw_sprite_ext(spr_grid_range_border,0,19+19*u+10,19+19*v+10,1,1,90,c_white,1);
}
// Left
if global.grid_potential_range[# u - 1, v] != -1 {
draw_sprite_ext(spr_grid_range_border,0,19+19*u+10,19+19*v+10,1,1,180,c_white,1);
}
// Down
if global.grid_potential_range[# u, v + 1] != -1 {
draw_sprite_ext(spr_grid_range_border,0,19+19*u+10,19+19*v+10,1,1,270,c_white,1);
}
}
}
}
```

This is what it looks like (the red):