-
Notifications
You must be signed in to change notification settings - Fork 14
Home
The LightBuzz Azure App Service SDK for Unity3D is a framework that allows you to consume remote Azure services and even store data locally. It's secured using HTTPS. Supports Android, iOS, Windows Standalone, Mac OS, and UWP (including HoloLens).
It's across-platform SDK you can actually use in your apps and games without compatibility problems.
To use the SDK, you can either clone the current repository or download the .unitypackage file from the Releases section.
The LightBuzz Azure SDK for Unity consumes Azure App Service APIs. Azure App Services are integrated services that enable you to create web and mobile apps for any platform or device.
The LightBuzz SDK is built with security in mind. The native Microsoft HttpClient
modules do not support HTTPS in Unity. Our team has built the HTTP requests from scratch using the UnityWebRequest
class. This way, your data are encrypted and transmitted securely.
The LightBuzz SDK supports all of the HTTP(S) method requests.
- GET
- POST
- PUT
- PATCH
- DELETE
Unlike most of the available SDKs, the LightBuzz Azure SDK for Unity fully supports local database storage. This means you can use the Azure App Services to store data into a local SQLite database. You can sync your local data with the remote server, performing pull and push operations. As a result, your customers can use your app/game without an active Internet connection!
The local database is using the official version of SQLite. SQLite is the most popular and lightweight relational database system for desktop and mobile devices. For UWP, we are using SQLitePCL, which is Microsoft's recommendation for Windows Store apps.
The LightBuzz Azure SDK for Unity supports the following platforms:
- Unity Editor
- Android
- iOS
- Windows Desktop (Standalone)
- MacOS (Standalone)
- Universal Windows Platform (UWP) + HoloLens
To use the SDK, Unity 2017 LTS or Unity 2018 is recommended.
The SDK is built with the latest C# features, so you need to use the .NET 4.x Scripting Runtime version.
In Unity 2018, the scripting runtime is set to 4.x by default.
In Unity 2017, you need to explicitly select "Experimental (.NET 4.6 Equivalent)".
The SDK works with the following Scripting Backend options:
Platform | Scripting Backend |
---|---|
Standalone | Mono |
Android | Mono |
iOS | IL2CPP |
UWP | .NET |
Using the SDK, you can apply the proper Unity Build Settings automatically. On the Unity menu bar, select LightBuzz → Apply Build Settings for... and then select the target platform. The SDK will automatically apply the proper build settings for you.
In the included samples, we have created a simple demo that implements Microsoft's ToDo List example.
We have implemented a generic Data Access Object for you to use, called MobileAppsTableDAO
. The MobileAppsTableDAO
supports all of the common HTTP & HTTPS operations out-of-the-box. All you need to do is call the proper C# methods.
Using the code is fairly simple:
private MobileServiceClient azureClient;
private MobileAppsTableDAO<TodoItem> todoTableDAO;
private async Task Init()
{
azureClient = new MobileServiceClient(mobileAppUri, new LightBuzzMobileServiceClient());
todoTableDAO = new MobileAppsTableDAO<TodoItem>(azureClient);
if (todoTableDAO.SupportsLocalStore)
{
await LocalStore.Init(azureClient);
await LocalStore.Sync();
}
}
private async Task Get()
{
List<TodoItem> list = await todoTableDAO.FindAll();
foreach (TodoItem item in list)
{
Debug.Log("Text: " + item.Text);
}
}
private async Task Insert()
{
TodoItem item = new TodoItem
{
Text = "Hello World!"
};
await todoTableDAO.Insert(item);
}
private async Task Delete()
{
List<TodoItem> list = await todoTableDAO.FindAll();
TodoItem item = list.LastOrDefault();
if (item != null)
{
await todoTableDAO.Delete(item);
}
}
private async Task Sync()
{
if (todoTableDAO.SupportsLocalStore)
{
await LocalStore.Sync();
}
}
The SDK is brought to you by LightBuzz Inc., a New York based company.
- Georgia Makoudi, Azure Specialist
- Vangos Pterneas, Microsoft MVP
- George Karakatsiotis, AI Scientist
If you would like to contribute to the SDK, please make a pull request.
The LightBuzz Azure App Service SDK for Unity3D is the only SDK that supports local database storage. Also, it supports every major platform, including iOS, Android, MacOS, Windows Desktop, and UWP. It's also supporting HTTPS. The LightBuzz SDK is the most feature-complete Unity SDK for Microsoft Azure.
Currently, the following alternatives exist:
- DeadlyFingers' SDK Unity3D Azure AppServices
- Brian Peek's SDK Azure SDK for Unity3D
LightBuzz SDK | DeadlyFingers SDK | Brian Peek SDK | |
---|---|---|---|
App Services | ![]() |
![]() |
![]() |
HTTPS | ![]() |
![]() |
![]() |
Local database | ![]() |
![]() |
![]() |
Unity Editor | ![]() |
![]() |
![]() |
Windows Desktop | ![]() |
![]() |
![]() |
Mac OS X | ![]() |
![]() |
![]() |
Android | ![]() |
![]() |
![]() |
iOS | ![]() |
![]() |
![]() |
UWP | ![]() |
![]() |
![]() |
LightBuzz has been developing Mobile and Cloud solutions for Fortune 500 and startup companies since 2012. Get in touch with us to start a project with a reliable and trusted partner.