Integrate TestFlight SDK to Unity Project (improved)

Previously I posted a blog regarding an easy integration of TestFlight SDK to Unity project. However, it’s far from perfect, since you would have to manually update the generated code whenever the iOS project are rebuilt.

I worked more to find a much better way to handle it, and put the relate code to github so everyone could access it.

Here is the new integration steps:

  1. Sync it to your Unity project folder, make sure the source files (TestFlight*.*) are put in Assets/Plugins/iOS
  2. Get the TestFlight SDK from official website. Put TestFlight.h & libTestFlight.a under the same folder.

And how to use it:

Currently, these functions are now available in Unity:

TestFlightUnity.TakeOff(“<your TestFlight token>”); // Start the TestFlight. Call it once when your game starts

TestFlightUnity.PassCheckpoint(“<checkpoint name>”); // Log a checkpoint, which you could view later on TestFlight website

All the TestFlight functionality will be automatically integrated and activated after you build the project for iOS platform. No extra step is needed now!


MeshParticleRenderer for Unity3D

The mesh particles are frequently used in 3D games. But the Unity Engine only have a billboard particle renderer. Luckily, it’s not difficult to create a mesh-based particle renderer, which works together with Unity’s built-in ParticleEmitter component.

Here is the code: MeshParticleRenderer on Github

To use it, use “Components -> Particles -> Mesh Particle Renderer” to add it to an existing particle system. You could remove / disable the original ParticleRenderer component if you like.

All the meshes are pre-allocated. So if you make the particle object a prefab and use an object-pool to manage them, most of the memory allocation in run-time could be avoided. That’s important for games, especially on mobile platforms.