Exemple #1
0
 public void SetUserProfile(uint userId, byte[] profileBytes)
 {
     if (profileBytes == null)
     {
         throw new NullReferenceException();
     }
     EmoEngine.errorHandler(EdkDll.EE_SetUserProfile(userId, profileBytes, (uint)profileBytes.Length));
 }
Exemple #2
0
 public void SetUserProfile(uint userId, Profile profile)
 {
     if (profile == null)
     {
         throw new NullReferenceException();
     }
     byte[] bytes = profile.GetBytes();
     EmoEngine.errorHandler(EdkDll.EE_SetUserProfile(userId, bytes, (uint)bytes.Length));
 }
Exemple #3
0
        public void LoadProfile(string profileName)
        {
            Profile = profileName;

            FileStream fileStream = new FileStream(GetProfilePath(profileName), FileMode.Open, FileAccess.Read);

            Byte[] buffer = new byte[fileStream.Length];
            fileStream.Read(buffer, 0, (int)fileStream.Length);
            fileStream.Close();
            EdkDll.EE_SetUserProfile(UserID, buffer, (uint)buffer.Length);
            emoEngine.LoadUserProfile(UserID, GetProfilePath(profileName));
            LoadTrainedActions();
        }