I am trying to factor out some code(inspired from this)
part "game.dart":
part 'taps.dart';
class MyGame extends FlameGame with HasTappables {}
Trying to factor out to this file "taps.dart":
part of 'game.dart';
mixin Taps on MyGame {
@override
void onTapDown(int pointerId, TapDownInfo info) {
super.onTapDown(pointerId, info);
}
Problem is that "onTapDown" is not called?
Update:
This will not work:
class MainClass with OneMixin {
void test(){
helloOne();
}
}
mixin OneMixin on MainClass {
void helloOne() {
test();
}
}