flutter_unity_widget 4.0.0-alpha.2 flutter_unity_widget: ^4.0.0-alpha.2 copied to clipboard
Flutter Unity 3D widget for embedding Unity game scenes in flutter. This library now supports Unity as a Library.
import 'package:flutter/material.dart';
import 'package:flutter_unity_widget_example/screens/orientation_screen.dart';
import 'menu_screen.dart';
import 'screens/api_screen.dart';
import 'screens/loader_screen.dart';
import 'screens/simple_screen.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Unity Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
visualDensity: VisualDensity.adaptivePlatformDensity,
),
initialRoute: '/',
routes: {
'/': (context) => MenuScreen(),
'/simple': (context) => SimpleScreen(),
'/loader': (context) => LoaderScreen(),
'/orientation': (context) => OrientationScreen(),
'/api': (context) => ApiScreen(),
},
);
}
}