Copy link to clipboard
Copied
hi guys ....When i draw a line other than vertical or horizontal line not only hitting the letters which was under the line ,,it also hitting other letter too.. like which was show in image ...In second pic shows ..the whole letters which was inside the right angled triangle are shows hitting ..when i trace what are all hitting it shows all inside the right angled triangle ..so i can keep the words in the cross form ...can
anyone knows whats the problem was.....
Copy link to clipboard
Copied
use the bitmapdata hittest or make your letters buttons and store which undergo a mouseover or make sure your letters have no border white space.
p.s. i can see you would have problems, but i can't see how you would have that many letters extraneously added to the list of letters moused-over. you must be using some pretty screwy way of detecting a mouseover/positive hittest.
Copy link to clipboard
Copied
can u give some example or some reference for this
Copy link to clipboard
Copied
var lettersA:Array=[your letters]
var selected_lettersA:Array = [];
for(var i:int=0;i<lettersA.length;i++){
lettersA.addEventListener(MouseEvent.MOUSE_OVER,overF);
}
function new_word_selectionF():void{
selected_lettersA.length=0;
}
function overF(e:MouseEvent):void{
selected_lettersA.push(e.currentTarget);
}
function check_lettersF():void{
for(var i:int=0;i<selected_lettersA.length;i++){
trace(selected_lettersA.name);
}
}
Copy link to clipboard
Copied
Thanks ..i will try this way
Copy link to clipboard
Copied
you're welcome.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now