コード例 #1
0
ファイル: RaceTests.cs プロジェクト: Kindlar/Character-Gen
 public void HalfOrcReturn2Str()
 {
     HalfOrc race = new HalfOrc();
     int actual = race.StrRacialMod;
     int expected = 2;
     Assert.AreEqual(expected, actual);
 }
コード例 #2
0
 public void Init()
 {
     HalfOrc halforc = new HalfOrc();
     HalfOrc = halforc;
 }
コード例 #3
0
ファイル: Player.cs プロジェクト: Kindlar/Character-Gen
 public void CreatePlayerRace(string race)
 {
     switch (race)
     {
         case "Elf":
             Race = new Elf();
             break;
         case "Human":
             Race = new Human();
             break;
         case "Dwarf":
             Race = new Dwarf();
             break;
         case "Gnome":
             Race = new Gnome();
             break;
         case "Half-Elf":
             Race = new HalfElf();
             break;
         case "Half-Orc":
             Race = new HalfOrc();
             break;
         case "Halfing":
             Race = new Halfing();
             break;
     }
 }