This commit is contained in:
2020-07-04 14:41:25 +08:00
parent 70c346d2c1
commit a8f02e4da5
3748 changed files with 587372 additions and 0 deletions

View File

@@ -0,0 +1,55 @@
using UnityEngine;
using System.Collections;
//helper class
//it listen for messages comming from plugin
public class MssageReceiver : MonoBehaviour {
void OnInitializeDone( string message )
{
Contacts.OnInitializeDone ();
}
void OnInitializeFail( string message )
{
Debug.LogError( "OnInitializeFail : " + message );
Contacts.OnInitializeFail (message);
}
void Log( string message )
{
Debug.Log( "internal log : " + message );
}
void Error( string error )
{
Debug.LogError( "internal error : " + error );
}
void OnContactReady( string id )
{
debug( "OnContactReady: " + id);
if( string.IsNullOrEmpty( id ))
return;
int index = int.Parse( id);
Contacts.GetContact( index );
}
/*void OnContactReady( string data )
{
return;
//debug( data );
byte[] bytes = System.Text.Encoding.UTF8.GetBytes( data );
Contact c = new Contact();
c.FromBytes( bytes );
Contacts.ContactsList.Add( c );
}*/
void debug( string message )
{
//Debug.Log( message );
}
}