C# – Creating iOS Plugin in Unity

c++iosunity3dxcode

I'm very new to Unity3d 3.5, and I've been reading over this manual for how to create iOS plugins in Unity (I'm using the pro version):
http://unity3d.com/support/documentation/Manual/PluginsForIOS.html

I'm under the impression that there is a script that will scan Plugins/iOS in Unity's project folder, and symlink everything in there into Xcode. The manual pretty much just scims over how to do it, and it is not very helpful for a beginner. I was wondering if there is just a single file floating around that will accomplish this, or if it is different for every app? Any help is much appreciated, thanks in advance!

Also, does anyone know if there is a way to have Unity include the .h files and plist's in the Plugins/iOS folder? That sounds like a much easier process.

Best Solution

And also make sure that you define all your C# methods are of the format :

[DllImport ("__Internal")] private static extern float FooPluginFunction ();

and your c functions should be wrapped inside

extern "C" {
  float FooPluginFunction ();
 } 

If they are not, your app will break

Related Question