You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -34,7 +34,7 @@ is not compatible with other versions, it just mean it's been tested to work wit
34
34
35
35
## Installation
36
36
37
-
This plugin requires Flutter >= 3.3.0
37
+
This plugin requires Flutter >= 3.16.0.
38
38
39
39
First depend on the library by adding this to your packages `pubspec.yaml`:
40
40
```yaml
@@ -62,7 +62,7 @@ You will need to open and export a Unity project, even for running the example.
62
62
63
63
## Setup
64
64
65
-
In the tutorial below, there are steps specific to each platform, denoted by a :information_source: icon followed by
65
+
In the tutorial below, there are steps specific to each platform, denoted by a ℹ️ icon followed by
66
66
the platform name (Android or iOS). You can click on its icon to expand it.
67
67
68
68
### Prerequisites
@@ -74,6 +74,23 @@ the platform name (Android or iOS). You can click on its icon to expand it.
74
74
- A `fuw-XXXX.unitypackage` file, found in the [*unitypackages*](https://github.com/juicycleff/flutter-unity-view-widget/tree/master/unitypackages) folder.
75
75
Try to use the most recent unitypackage available.
76
76
77
+
### Unity versions for publishing
78
+
If you want to publish your app for Android or iOS, you need to satisfy certain Unity version requirements.
79
+
80
+
**iOS**
81
+
Apple's [privacy manifest requirements](https://discussions.unity.com/t/apple-privacy-manifest-updates-for-unity-engine/936052) need a minimal Unity version of:
82
+
* 2021.3.35+
83
+
* 2022.3.18+
84
+
* 6000.0.0+
85
+
86
+
**Android**
87
+
> Starting November 1st, 2025, all new apps and updates to existing apps submitted to Google Play and targeting Android 15+ devices must support 16 KB page sizes.
88
+
89
+
This requires [Unity versions](https://discussions.unity.com/t/info-unity-engine-support-for-16-kb-memory-page-sizes-android-15/1589588):
90
+
* 2021.3.48+ (Enterprise and Industry only)
91
+
* 2022.3.56+
92
+
* 6000.0.38+
93
+
77
94
78
95
### Unity project setup
79
96
These instructions assume you are using a new Unity project. If you open the example project from this repository, you can move on to the next section **Unity Exporting**.
@@ -142,7 +159,7 @@ After exporting Unity, you will need to make some small changes in your iOS or A
142
159
You will likely need to do this **only once**. These changes remain on future Unity exports.
> Because of Apple's privacy manifest requirements, you need a minimal Unity version of 2021.3.35 or 2022.3.18 to publish an app.
329
-
343
+
<summary>ℹ️ <b>iOS</b></summary>
330
344
331
345
1. Open the *ios/Runner.xcworkspace* (workspace, not the project) file in Xcode, right-click on the Navigator (not on an item), go to **Add Files to "Runner"** and add
332
346
the *ios/UnityLibrary/Unity-Iphone.xcodeproj* file.
@@ -396,7 +410,7 @@ allprojects {
396
410
397
411
398
412
<details>
399
-
<summary>:information_source: <b>AR Foundation Android</b></summary>
413
+
<summary>ℹ️ <b>AR Foundation Android</b></summary>
400
414
401
415
1. Check the version of the `XR Plugin Management` in the Unity package manager. Versions `4.3.1 - 4.3.3` contain a bug that breaks Android exports.
402
416
Make sure to use a version <=`4.2.2` or >=`4.4`.
@@ -425,7 +439,7 @@ allprojects {
425
439
</details>
426
440
427
441
<details>
428
-
<summary>:information_source: <b>AR Foundation iOS</b></summary>
442
+
<summary>ℹ️ <b>AR Foundation iOS</b></summary>
429
443
430
444
1. Open the *ios/Runner/Info.plist* and add a camera usage description.
These steps are based on these [Vuforia docs](https://developer.vuforia.com/library/unity-extension/using-vuforia-engine-unity-library-uaal#ios-specific-steps) and [this comment](https://github.com/juicycleff/flutter-unity-view-widget/issues/314#issuecomment-785302253)
458
472
@@ -486,7 +500,7 @@ We recommend using a physical iOS or Android device, as emulator support is limi
486
500
Below are the limited options to use an emulator.
487
501
488
502
<details>
489
-
<summary> <b>iOS Simulators</b> </summary>
503
+
<summary>ℹ️ <b>iOS Simulators</b> </summary>
490
504
491
505
The `Target SDK` option in the Unity player settings is important here.
492
506
-`Device SDK` exports an ARM build. (Which does **NOT** work on ARM simulators)
@@ -530,7 +544,7 @@ The rest depends on the type of processor in your mac:
530
544
</details>
531
545
532
546
<details>
533
-
<summary> <b>Android emulators</b></summary>
547
+
<summary>ℹ️ <b>Android emulators</b></summary>
534
548
535
549
Unity only supports ARM build targets for Android. However most Android emulators are x86 which means they simply won't work.
536
550
@@ -570,19 +584,40 @@ If you computer does not have an ARM processor, like most computers running on I
570
584
571
585
2. Use the method `postMessage` to send a string, using the GameObject name and the name of a behaviour method that should be called.
572
586
587
+
```dart
588
+
// Snippet of postMessage usage in the example project.
589
+
_unityWidgetController?.postMessage(
590
+
'Cube', // GameObject name
591
+
'SetRotationSpeed', // Function name in attached C# script
592
+
speed, // Function parameter (string)
593
+
);
594
+
```
573
595
### Unity-Flutter
574
596
575
597
1. Select the GameObject that should execute the communication and go to **Inspector > Add Component > Unity Message Manager**.
0 commit comments