"[DllImport("__Internal")]" - what does the "__Internal" mean?
- Plugins link their code to C# unity using
[DllImport()]
. __internal
is a keyword used for static linking needed by specific platforms, such as XBox and iOS.- Other platforms usually use dynamic linking, hence this is not needed.
Please for more info refer to: https://docs.unity3d.com/Manual/NativePlugins.html
Just the minor tip.
If the library being loaded is __Internal
, then the main program is searched for method symbols. This happens to be the case on iOS platform.
The plugins on iOS cannot load dynamically. Only statically as @RaxelZ explained.
It is different for OSX, Windows, Android ... those platforms may load plugins dynamically. For iOS, only statically.