Beispiel #1
0
 public CreateFacialFeatures()
 {
     hairStyles = GatewayProvider.Get <HairStyle>();
     hairColors = GatewayProvider.Get <HairColor>();
     facialHair = GatewayProvider.Get <FacialHair>();
     eyeColors  = GatewayProvider.Get <EyeColor>();
 }
Beispiel #2
0
        public void LoadsGatewayForCharacterCreator()
        {
            var creatorGateway = GatewayProvider.Get <SilverNeedle.Actions.CharacterGeneration.CharacterDesigner>();

            Assert.NotNull(creatorGateway);
            Assert.True(creatorGateway.Count() > 0);
        }
Beispiel #3
0
        public void Execute(Utility.ComponentContainer components)
        {
            // Select a simple weapon
            var choice = GatewayProvider.Get <Weapon>().SimpleWeapons().ChooseOne();

            components.Add(new WeaponProficiency(choice.ProficiencyName));
        }
Beispiel #4
0
 private static void RegisterSupportedHelpers()
 {
     helpers.Add(new ChooseDescriptor());
     helpers.Add(new ChooseWordFromGatewayObject <Color>(GatewayProvider.Get <Color>()));
     helpers.Add(new ChooseWordFromGatewayObject <Gem>(GatewayProvider.Get <Gem>()));
     helpers.Add(new ChooseWordFromGatewayObject <Occupation>(GatewayProvider.Get <Occupation>()));
     helpers.Add(SelectCharacterFavoriteColors.CreateAndRegister());
 }
Beispiel #5
0
        private CharacterDesigner FindDesigner(string name)
        {
            if (gateway == null)
            {
                gateway = GatewayProvider.Get <CharacterDesigner>();
            }

            return(gateway.Find(designerName));
        }
Beispiel #6
0
        private EntityGateway <Weapon> GetWeapons()
        {
            if (weaponsGateway == null)
            {
                weaponsGateway = GatewayProvider.Get <Weapon>();
            }

            return(weaponsGateway);
        }
Beispiel #7
0
        public IEnumerable <Feat> Load(IObjectStore configuration)
        {
            var craftsmanFeats = new List <Feat>();
            var skills         = GatewayProvider.Get <Skill>().Where(x => x.IsProfessionSkill || x.IsCraftSkill);

            foreach (var skl in skills)
            {
                var yaml = configuration.GetString("loader-template");
                yaml = yaml.Formatted(skl.Name);
                var crft = new Feat(yaml.ParseYaml());
                craftsmanFeats.Add(crft);
            }

            return(craftsmanFeats);
        }
Beispiel #8
0
        public bool IsProficient(string proficiencyName)
        {
            //Do a quick string check...
            foreach (var prof in proficiencyList)
            {
                if (prof.EqualsIgnoreCase(proficiencyName))
                {
                    return(true);
                }
            }

            var equip = GatewayProvider.Get <Weapon>().Where(x => x.Name.ContainsIgnoreCase(proficiencyName));

            foreach (var w in equip)
            {
                if (IsProficient(w))
                {
                    return(true);
                }
            }
            return(false);
        }
Beispiel #9
0
        public IActionResult Index()
        {
            var namer   = new NameCharacter();
            var races   = GatewayProvider.Get <Race>().All();
            var number  = 5;
            var results = new List <NamesViewModel>();

            //Foreach race and gender make a collection of names
            foreach (var r in races)
            {
                foreach (var g in EnumHelpers.GetValues <Gender>())
                {
                    var genderRaceNames = new NamesViewModel(r.Name, g);
                    for (int i = 0; i < number; i++)
                    {
                        var name = namer.CreateFullName(g, r.Name);
                        genderRaceNames.Names.Add(name);
                    }
                    results.Add(genderRaceNames);
                }
            }
            ViewData["names"] = results;
            return(View());
        }
Beispiel #10
0
 public SelectFavoriteColors()
 {
     this.colors = GatewayProvider.Get <Color>();
 }
Beispiel #11
0
 public SelectQuirks()
 {
     this.quirkGateway = GatewayProvider.Get <QuirkTemplate>();
 }
Beispiel #12
0
 public SelectRagePower()
 {
     _ragePowers = GatewayProvider.Get <RagePower>();
 }
Beispiel #13
0
 public HomelandSelector()
 {
     this.homelands = GatewayProvider.Get <HomelandGroup>();
 }
Beispiel #14
0
 public void Initialize(ComponentContainer components)
 {
     this.Weapon = GatewayProvider.Get <Weapon>().ChooseOne();
     components.Get <OffenseStats>().AddWeaponModifier(this.WeaponCriticalDamageBonus);
 }
Beispiel #15
0
 public WandCreator()
 {
     spells     = GatewayProvider.Get <Spell>();
     spellLists = GatewayProvider.Get <SpellList>();
 }
Beispiel #16
0
 public ClassOriginStoryCreator()
 {
     this.classOrigins = GatewayProvider.Get <ClassOriginGroup>();
 }
Beispiel #17
0
 public SelectBloodline() : this(GatewayProvider.Get <Bloodline>())
 {
 }
Beispiel #18
0
 public ChooseDescriptor()
 {
     this.descriptors = GatewayProvider.Get <Descriptor>();
     RegisterHelper();
 }
Beispiel #19
0
 public ClassSelector()
 {
     classes = GatewayProvider.Get <Class>();
 }
Beispiel #20
0
 public PurchaseShield()
 {
     this.armors = GatewayProvider.Get <Armor>();
 }
Beispiel #21
0
        public InitializeCharacterSheet()
        {
            skills = GatewayProvider.Get <Skill>();

            setups = GatewayProvider.Get <CharacterSheetSetup>();
        }
Beispiel #22
0
 public BirthCircumstanceSelector()
 {
     circumstances = GatewayProvider.Get <BirthCircumstance>();
 }
Beispiel #23
0
 public PersonalityBuilder()
 {
     personalities = GatewayProvider.Get <PersonalityType>();
     ideals        = GatewayProvider.Get <Ideal>();
 }
Beispiel #24
0
 public static SpellList CreateForTesting(string className)
 {
     return(CreateForTesting(className, GatewayProvider.Get <Spell>()));
 }
Beispiel #25
0
 public CreatePhysicalFeatures()
 {
     physical = GatewayProvider.Get <PhysicalFeature>();
 }
Beispiel #26
0
 public SpellList()
 {
     spellInformation = GatewayProvider.Get <Spell>();
 }
Beispiel #27
0
 public SpontaneousCasting(IObjectStore configuration) : this(configuration, GatewayProvider.Get <SpellList>())
 {
 }
Beispiel #28
0
 public ProcessFavoredClassToken() : this(GatewayProvider.Get <Class>())
 {
 }
Beispiel #29
0
 public PurchaseClothing()
 {
     clothing = GatewayProvider.Get <Clothes>();
 }
Beispiel #30
0
 public NameCharacter()
 {
     this.namesGateway = GatewayProvider.Get <NameInformation>();
 }