title: Wall collision problems AS3
body: <p>I'm making a game where a character walks around different rooms, but I want to keep it from going through the walls. I tried making a barrier symbol to stop it, but since the four walls enclose the character, hitTestObject returns true every time, not just when it hits the solid parts of the walls. My problem with simply using hero.x &lt; 0 is that there are items that the character can equip that cause the hero's symbol to extend below 0. All of the symbols have been resized so I can't just get the width of the symbol within the hero's symbol. Any ideas for a better method of detecting collision? Possibly hitTestPoint, but not really sure how that would work without a huge array of points to test . . .</p>