tink icon indicating copy to clipboard operation
tink copied to clipboard

Tink and hitArea?

Open ESPWarren opened this issue 8 years ago • 0 comments

Am I right to assume that Tink does not support custom defined sprite hitAreas (i.e. using a PIXI Polygon...)?

It seems that when I define a sprite hitArea, and do NOT use Tink to make it interactive, thus:

 var p=new PIXI.Polygon(0,0,100,100,50,200);
 tree.hitArea=p;
 tree.interactive=1; tree.buttonMode=1;

Then it works - I get a hit area defined by the polygon.

But if I replace that last line like this:

t=new Tink(PIXI, appmain.view);
var p=new PIXI.Polygon(0,0,100,100,50,200);
tree.hitArea=p;
tink.makeInteractive(tree);

Then I get a hitArea defined by the sprite bounding rectangle...

???

Thanks

ESPWarren avatar Nov 13 '17 13:11 ESPWarren