One SDK to serve them all

Summary

At Ubisoft Mobile Barcelona, we worked on several games at the same time. This inevitably meant that when we face an issue with mobile, most probably all other games will end up facing it aswell.

In order to reduce the need to copy paste solutions or to double-test them. We created an internal SDK which provided solution for common needs the games may have. Including (although not limited to): Advertising, tracking, push notifications, etc…

My job was to maintain and expand the functionality of an existing SDK to deliver new features to both games under development at that time: Might & Magic: Elemental Guardians and Hungry Dragon

The project

First of all, I needed to know what both teams were expecting to get from the common SDK and how can we work together to make it even better.

After spending some time with the code and with each team. I got to the conclusion that building an API-like interface they could know what to expect and what information needed to be included was the best approach. With this idea in mind I started to sketch an architecture that would make it possible to include the needed libraries for every project and to let the teams choose what they need for their specific project. And at the same time give the option for me to upgrade those said libraries when new versions arise.

 

Challenges

The most impactful feature was to be able to access from a single code language (C#) to both native-specific language (Java for Android and Objective-C for iOS). This needed a really careful approach and was challenging on it’s own.

In the end using a chain of languages let me get through it.

Result

This way we accomplished our goal, every SDK can reach natively the specific platform and we provide a common place to do our business logic within C# in order to provide a common API to each game. This relieves the pain of dealing with multiple implementations and having to rely on Unity-developed SDK. This approach allowed us to use the more commonly available Android or iOS implementations of the SDK we needed.

Lessons learnt

Having to work with different teams at the same time, with different needs showed that documentation and clear communication is key to success on complex projects.

Lots of bugs were found at different stages of implementation or deploy that cross-benefit each of the teams. Meaning that features could be deployed and tested on a project, to be later implemented on the other one with much more confidence.

The team

Developed at Ubisoft Barcelona Mobile, Barcelona.

  • Live Producer – Emiliano Córdova
  • Lead Programmer – Andrés Fernández Munuera
  • Senior Tech Developer – Javier Calet Toledo
  • Lead Programmer – Alger Ortín Castellví
  • Senior Game Developer – David Germade
  • Senior Programmer – Marc Saña Forrellach
  • Platform Mobile Engineer – Eloi Navarro Serrano