예제 #1
0
        void ExecuteLoadArmasCommand()
        {
            if (IsBusy)
            {
                return;
            }

            IsBusy = true;

            try
            {
                Armas.Clear();



                foreach (var item in (new ArmaService()).GetArmas())
                {
                    Armas.Add(new Tuple <int, string>(item.Key, item.Value));
                }
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex);
            }
            finally
            {
                IsBusy = false;
            }
        }
예제 #2
0
 public void getArma(Arma arma)
 {
     Armas.Add(arma);
     ArmaActiva = arma;
     //recupera un arma
 }