Very useful feature, that should help with making animatable buttons etc..
When extending FlareControls and overriding setViewTransform, one should add call to "super.setViewTransform(viewTransform);" in order to make it work.
Example:
wrap your FlareActor with GestureDetector. add onTapDown Event, and ask the flare controller which nodes were clicked.
GestureDetector(child: FlareActor(
"assets/Teddy.flr",
shouldClip: false,
alignment: Alignment.bottomCenter,
fit: BoxFit.contain,
controller: _teddyController,
), onTapDown : (details){
print (_teddyController.deepHitTest(details.globalPosition));
}
)
Very useful feature, that should help with making animatable buttons etc.. When extending FlareControls and overriding setViewTransform, one should add call to "super.setViewTransform(viewTransform);" in order to make it work. Example: wrap your FlareActor with GestureDetector. add onTapDown Event, and ask the flare controller which nodes were clicked. GestureDetector(child: FlareActor( "assets/Teddy.flr", shouldClip: false, alignment: Alignment.bottomCenter, fit: BoxFit.contain, controller: _teddyController, ), onTapDown : (details){ print (_teddyController.deepHitTest(details.globalPosition)); } )