예제 #1
0
        public void CreateBaseStat()
        {
            BAZOWE_STATYSTYKI bs = new BAZOWE_STATYSTYKI();

            bs.BASE_AG      = Utils.GetIntFromConsole("BASE AG");
            bs.BASE_HP      = Utils.GetIntFromConsole("BASE HP");
            bs.BASE_INT     = Utils.GetIntFromConsole("BASE INT");
            bs.BASE_MP      = Utils.GetIntFromConsole("BASE MP");
            bs.BASE_STAMINA = Utils.GetIntFromConsole("BASE STAMINA");
            bs.BASE_STR     = Utils.GetIntFromConsole("BASE STR");
            _unitOfWork.BaseStatisticsRepository.Add(bs);
            _unitOfWork.BaseStatisticsRepository.Save();
            Console.WriteLine("Base stat created");
            Thread.Sleep(1000);
        }
예제 #2
0
        public void DeleteBaseStat()
        {
            int id = Utils.GetIntFromConsole("Base stat ID to delete:");
            BAZOWE_STATYSTYKI rec = _unitOfWork.BaseStatisticsRepository.GetById(id);

            if (rec != null)
            {
                _unitOfWork.BaseStatisticsRepository.Delete(rec);
                _unitOfWork.BaseStatisticsRepository.Save();
                Console.WriteLine("Base stat deleted");
                Thread.Sleep(1000);
            }
            else
            {
                Console.WriteLine("Base stat not found");
                Thread.Sleep(1000);
            }
        }
예제 #3
0
        public void PrintOneBaseStat()
        {
            int id = Utils.GetIntFromConsole("Base stat ID:");
            BAZOWE_STATYSTYKI rec = _unitOfWork.BaseStatisticsRepository.GetById(id);

            if (rec != null)
            {
                Console.WriteLine(
                    $"ID:{rec.ID} BASE HP: {rec.BASE_HP} BASE AG: {rec.BASE_AG} BASE INT: {rec.BASE_INT} BASE MP: {rec.BASE_MP} BASE STAMINA:{rec.BASE_STAMINA} BASE STR{rec.BASE_STR} ");
                Console.WriteLine("Click any button to continue");
                Console.ReadKey();
            }
            else
            {
                Console.WriteLine("Base stat not found");
                Thread.Sleep(1000);
            }
        }
예제 #4
0
        public void ModifyBaseStat()
        {
            int id = Utils.GetIntFromConsole("Base stat ID to modify:");
            BAZOWE_STATYSTYKI bs = _unitOfWork.BaseStatisticsRepository.GetById(id);

            if (bs != null)
            {
                bs.BASE_AG      = Utils.GetIntFromConsole("BASE AG");
                bs.BASE_HP      = Utils.GetIntFromConsole("BASE HP");
                bs.BASE_INT     = Utils.GetIntFromConsole("BASE INT");
                bs.BASE_MP      = Utils.GetIntFromConsole("BASE MP");
                bs.BASE_STAMINA = Utils.GetIntFromConsole("BASE STAMINA");
                bs.BASE_STR     = Utils.GetIntFromConsole("BASE STR");
                _unitOfWork.BaseStatisticsRepository.Edit(bs);
                _unitOfWork.BaseStatisticsRepository.Save();
                Console.WriteLine("Base stat modified");
            }
            else
            {
                Console.WriteLine("Base stat not found");
            }
            Thread.Sleep(2000);
        }