示例#1
0
 public static Abilities Map(Library.Abilities r) => new Abilities
 {
     AbilityId   = r.AbilityID,
     Name        = r.Name,
     Description = r.Description,
     NumDice     = r.NumDice,
     NumSides    = r.NumSides,
     Attack      = r.Attack
 };
示例#2
0
 public void UpdateAbility(Library.Abilities ability)
 {
     _db.Entry(_db.Abilities.Find(ability.AbilityID)).CurrentValues.SetValues(Mapper.Map(ability));
 }
示例#3
0
 public void CreateAbility(Library.Abilities ability)
 {
     _db.Add(Mapper.Map(ability));
 }