public Task <Item> ModifyItem(Guid id, ModifiedItem modItem, Guid itemId)
 {
     if (players.ContainsKey(id))
     {
         for (int i = 0; i < players[id].items.Count; i++)
         {
             if (players[id].items[i]._itemId == itemId)
             {
                 players[id].items[i]._level = modItem._level;
                 return(Task.FromResult(players[id].items[i]));
             }
         }
         return(null);
     }
     else
     {
         return(Task.FromResult <Item>(null));
     }
 }
示例#2
0
 public Task <Item> ModifyItem(Guid id, ModifiedItem modIt, Guid itemId)
 {
     return(memRep.ModifyItem(id, modIt, itemId));
 }