Exemple #1
0
        public async Task <bool> DeleteAsync_CharacterParty(Character data)
        {
            var myData = _characterDataset.FirstOrDefault(arg => arg.Id == data.Id);

            _characterParty.Remove(myData);

            return(await Task.FromResult(true));
        }
Exemple #2
0
        //character party

        public async Task <bool> RecruitAsync_Character(Character data)
        {
            if (_characterParty.Count < 6)
            {
                _characterParty.Add(data);
            }

            return(await Task.FromResult(true));
        }
Exemple #3
0
        public async Task <bool> DeleteAsync_CharacterParty(Character data)
        {
            var result = await App.Database.DeleteAsync(data);

            if (result == 1)
            {
                return(true);
            }

            return(false);
        }
Exemple #4
0
        public async Task <bool> RecruitAsync_Character(Character data)
        {
            var result = await App.Database.InsertAsync(data);

            if (result == 1)
            {
                return(true);
            }

            return(false);
        }
        public async Task <bool> UpdateAsync_Character(Character data)
        {
            var myData = _characterDataset.FirstOrDefault(arg => arg.Id == data.Id);

            if (myData == null)
            {
                return(false);
            }

            myData.Update(data);

            return(await Task.FromResult(true));
        }
        // Character
        public async Task <bool> AddAsync_Character(Character data)
        {
            _characterDataset.Add(data);

            return(await Task.FromResult(true));
        }