I have a code for my game that lets me place the blocks I need in my room, and it will automaticly change sprite to best match based on objects around it. So, I would use something like...
if !instance_place(x+32,y,obj_wall) and !instance_place(x-32,y,obj_wall) image_index = 1
But, I am not sure this is the best way. It is also a bit messy, and hard to keep track of. Does anyone know of a better way, or is this fine and dandy?