One method I often use is Flags. If your map is a array(I would image so) you could have a flag for each array space called Occupied%% (or type defined Occupied as _byte) and if there is something in that space or some reason you(or a NPC) could not walk in that space you set the flag, Occupied%%, to TRUE (-1) then in the movement routine you check if that map square is walkable ore not by checking the flag.
Simple Example of checking
'allow movement to that square
'block movement to that square
or if you didn't want to have a UDT for you map array you could have a second array Occupied(100,100) AS _BYTE
and just change the initial IF
rest would be the same.
personally I like assigning a TYPE to my map array to allow for more control options but this is a simple way I have found to block out whole map squares from movement.