Hi
I had a look at some posts on the topic but I don’t get it. :crying:
There are twelve docks and twelve boats. The user drags the boats into the docks. You can have multiple boats in a dock or none. When you roll two dice, you need to know if there is a boat in the corredsponding dock number.
The code below is supposed to tell me whether there is one of twelve boats in dock 1 and it’s not happening.
loadBoatsDone_btn.onRelease = function(){
for(i=1;i<13;i++){
if(dock1.hitTest(["boat"+i+"_mc"])) {
trace(this["boat"+i+"_mc"]);
}
}
}
Does anyone have advice? What the heck am I doing?
thank you