Ejemplo n.º 1
0
 protected async Task SaveActionData(int taskId, GameAction action, ServerApi serverApi, user_role role, DateTime?expireTime = null, Dictionary <string, string> taskData = null)
 {
     var saveActionDataTask = new SaveActionDataTask()
     {
         taskId      = taskId,
         action      = action,
         expiresTime = expireTime,
         roleData    = GetRoleData(serverApi, role.id, role.user_id),
         taskData    = taskData
     };
     await saveDataActor.Ask(saveActionDataTask);
 }
Ejemplo n.º 2
0
 protected async Task SaveActionData(LoginTask task, GameAction action, role_data data, DateTime?expireTime = null, Dictionary <string, string> taskData = null)
 {
     var saveActionDataTask = new SaveActionDataTask()
     {
         taskId      = task.id,
         action      = action,
         expiresTime = expireTime,
         roleData    = data ?? GetRoleData(task.serverApi, task.role.id, task.role.user_id),
         taskData    = taskData == null ? task.task_data : taskData,
     };
     await saveDataActor.Ask(saveActionDataTask);
 }