IGL configuration updated!

IGL.Common was updated to include new configuration.  This is a breaking change and requires the configuration to be changed from:

// set the following once - this is using ACS 
 IGL.Client.Configuration.IssuerName = "IGLGuestClient";
 IGL.Client.Configuration.IssuerSecret = "...";
 IGL.Client.Configuration.ServiceNamespace = "indiegameslab";
// optional 
 IGL.Client.Configuration.GameId = 1;
 IGL.Client.Configuration.PlayerId = "TestingTesting";


// set the following once - this is using ACS 
 IGL.Configuration.CommonConfiguration.Instance.BackboneConfiguration.IssuerName = "IGLGuestClient";
 IGL.Configuration.CommonConfiguration.Instance.BackboneConfiguration.IssuerSecret = "...";
 IGL.Configuration.CommonConfiguration.Instance.BackboneConfiguration.ServiceNamespace = "indiegameslab";
// optional 
 IGL.Configuration.CommonConfiguration.Instance.GameId = 1;
 IGL.Configuration.CommonConfiguration.Instance.PlayerId = "TestingTesting";

This can also be driven from the web or app configuration files.

IGL.Samples Unity Sample

A new Unity project has been added to IGL.Samples.  The purpose of the project is to illustrate how a Unity game can send messages to and receive messages from the IGL Backbone.

The project contains a scene that has a button to start listening and a button to send a message.  The result of a message is shown in a message box as illustrated below:


When a message is received, then a message is shown in the console:



The Canvas object contains a script with the following implementation.

Setting up initial configuration

On the start, some initial configuration is required as well as setting up an event handler for GameEvent messages received and for when errors are encountered in the ServiceBusListener.

Note the settings below are for the IGL Backbone Service and its status can be viewed on the services tab.

void Start () {
_instance = Guid.NewGuid();
//// initial setup of IGL
 IGL.Client.Configuration.IssuerName = "IGLGuestClient";
 IGL.Client.Configuration.IssuerSecret = "2PenhRgdmlf6F1oNglk9Wra1FRH31pcOwbB3q4X0vDs=";
 IGL.Client.Configuration.ServiceNamespace = "indiegameslab";
IGL.Client.Configuration.GameId = 100;
 IGL.Client.Configuration.PlayerId = "TestingTesting";
_listener = new IGL.Client.ServiceBusListener();
 IGL.Client.ServiceBusListener.OnGameEventReceived += ServiceBusListener_OnGameEventReceived;
 IGL.Client.ServiceBusListener.OnListenError += ServiceBusListener_OnListenError; 

Listening for GameEvents

The following show the implementation of the event handlers and both write a message to the console.

private void ServiceBusListener_OnListenError(object sender, System.IO.ErrorEventArgs e)
 Debug.LogErrorFormat("Error:{0}", e.GetException().Message);
private void ServiceBusListener_OnGameEventReceived(object sender, IGL.GamePacketArgs e)
 if (e.GamePacket.GameEvent.Properties["Instance"] == null ||
 e.GamePacket.GameEvent.Properties["Instance"] != _instance.ToString())
 var sentTime = DateTime.Parse(e.GamePacket.GameEvent.Properties["Created"]);
 Debug.LogFormat("Packet:{0} Round Trip in {1} milliseconds.", 

The IGL.ServiceBusListener() contains a method that performs an async retrieve from the IGL Backbone for messages addressed to the player.  Though this message is called in Update(), only one request to the Backbone will be sent at a time.

void Update()
 if (_listenForMessages == true)

Sending a GameEvent

The SendEchoMessage() method is called when the send button is pressed and submits a simple GameEvent to the IGL Backbone:

public void SendEchoMessage()
 var gameEvent = new IGL.GameEvent
 Properties = new Dictionary<string, string>()
 { "Created", DateTime.UtcNow.ToString() },
 { "Instance", _instance.ToString() }
 bool wasSuccessful = IGL.Client.ServiceBusWriter.SubmitGameEvent("Echo", 1, gameEvent);
 MessageDisplay.text = "Sent message without error: " + wasSuccessful.ToString() + Environment.NewLine + MessageDisplay.text;


Echo Function

The Echo Function is live and available for general use while the 1 million free executions lasts!  The status of the Echo Function is on the Echo Function page (Service tab).

As an illustration, the Echo Function will read new messages that are published to the echo queue and publish to the specific player Topic.


Unity AssetServer – FATAL: could not reattach to shared memory

If you run into an issue where the Unity AssetServer fails to start, try a simple restart of the server in the first instance.  There are a heap of posts indicating it is postgres related but I have not gotten to the root of the error.  So far a simple restart of the server seems to clear the shared memory lock but I will be making regular backups as well as at least one person has not been so lucky.

LOG:  database system was interrupted; last known up at 2014-11-12 04:06:49 GMT
LOG:  database system was not properly shut down; automatic recovery in progress
LOG:  record with zero length at 1/F3E78290
LOG:  redo is not required
LOG:  database system is ready to accept connections
FATAL:  could not reattach to shared memory (key=256, addr=018D0000): 487
LOG:  background writer process (PID 2132) exited with exit code 1
LOG:  terminating any other active server processes
FATAL:  could not reattach to shared memory (key=256, addr=018D0000): 487
LOG:  autovacuum launcher started
LOG:  all server processes terminated; reinitializing
FATAL:  pre-existing shared memory block is still in use
HINT:  Check if there are any old server processes still running, and terminate them.

Asset Server on Azure

There are many advantages and disadvantages of using hosted team collaboration services like Visual Studio Online, Git and Subversion compared with the Unity Asset Server.  In some situations, standing up a self-hosted source control repository is a good choice.

Unity Asset Server is only available with a Team License holder.

The following are the steps required to create a Unity Asset Server on the Azure.  Assuming an Azure subscription is already in place, the first step is to provision a new virtual machine.  As we do not require any additional features, a quick create will suffice:


The setup is very simple.  A DNS name that has not been currently registered is required and some information about what type of VM.  For my purposes I went with the most inexpensive option with the idea that I could scale up as required (an advantage of using Azure to host the VM).  The user name and password specified here is primarily for remote desktop access to the VM.


Once the server has been fully created, connect to the server from the virtual machine dashboard:


Once a connection has been made then install Unity Asset Server.  Before this can be done though the .Net Framework version needs to be updated to include 3.5.  The first step is to start the Server Manager dashboard (at the bottom of the screen):


The next step is to enable a new feature:


The wizard will take you through several steps.  Most notably are selecting the type of feature-based installation:


The particular server needs to be selected:


Finally the framework needs to be selected:


Once this is complete, then the Asset Server can be installed.  The easiest way is to download the package via the Unity Collaboration page.  The setup is uneventful except for an Asset Server Admin password is required.  This password will be used to create projects and users on the Asset Server from the Unity IDE.


The Asset Server should then start and should display that it is running successfully:


Now for connectivity to the server remotely.  Back in the Azure Management Portal, the accessible endpoints are listed on the endpoints section of the VM:


Click ADD to launch the endpoint wizard.  As this is for a single VM, select the Add a stand-alone endpoint option:


On the next page the details of the endpoint are specified:


Great.  We are done!  The simplest way to verify the server is listening and available is to use a simple test test.  I used paging as it is free and simple:


From here, there are many posts about how to setup the Asset Server including:

Asset Server

Setting up Asset Server with Unity3D over local-network

Debugging Unity with Visual Studio

Congrats to SyntaxTree on being acquired by Microsoft.  I look forward to seeing more innovation in from SyntaxTree and Microsoft in regards to Unity.

You can download the latest tools from the Visual Studio Gallery and install them as normal.

After starting Unity you will see a new Asset available as Visual Studio 2013 Tools:


This will bring in two new dlls into the Unity IDE:


If you want to debug your solution in Visual Studio, check the build settings to allow Visual Studio to connect:



Winner KiwiGameStarter 2014

Great news!  Phantasmal has won the KiwiGameStarter 2014 competition run by the New Zealand Game Developers Association Incorporated (NZGDA).

KiwiGameStarter 2014 is a business start-up competition for New Zealand-based game development teams. Its purpose is to support the commercial success of one high-potential team or project

So what does it mean.  Kudos, a sense of achievement and

  • $10,000 cash
  • One one-year license for Autodesk Maya LT
  • One commercial suite license for Unity 3D
  • public relations and marketing strategy advice from Pursuit Public Relations to the value of $2,000
  • assistance by Hudson Gavin Martin (specialist Technology and IP lawyers) with the drafting of a licence agreement for the winning Entry to license the Winner’s Game to end users (worth $2,000 plus GST) and additional legal advice from Hudson Gavin Martin in relation to the Game up to the value of $2,000 plus GST
  • introductions from the NZGDA to experienced game development professionals in New Zealand (Mentors) who have expertise in a domain or genre relevant to the Winner’s Entry

The pressure is on.  If you haven’t done so, please head over and look at Steam Greenlight: http://steamcommunity.com/sharedfiles/filedetails/?id=291861158&result=1