Sort of a hard thing to explain, but i have a database that holds the enemies that are generated within the game.
This is the only way i can think of doing it. If meep(any number) hits another one, execute code. This, however, does not work. I don't see why because if i use a different array, say:Code:for(var i = 0; i < meepsArray.length; i++) { if(["meep"+i].hitTest(["meep"+i])){ trace("success") } }
That seems to work. How can i make it so they can hittest each other? In the long wrong, i'm just going to use a distance formula to execute the code since hitTest isn't the most accurate thing in the world. But for testing purposes i've been using hittest.Code:if(["blah"+i].hitTest(["meep"+i])){ trace("success") }
-Holsey




Reply With Quote