示例#1
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <Region> descriptor)
 {
     descriptor.Description(@"A region is an organized area of the pokémon world. 
     Most often, the main difference between regions is the species of pokémon that can be encountered within them.");
     descriptor.UseNamedApiResourceCollectionField <Region, Location, LocationType>(x => x.Locations);
     descriptor.UseNamedApiResourceField <Region, Generation, GenerationType>(x => x.MainGeneration);
     descriptor.UseNamedApiResourceCollectionField <Region, Pokedex, PokedexType>(x => x.Pokedexes);
     descriptor.UseNamedApiResourceCollectionField <Region, VersionGroup, VersionGroupType>(x => x.VersionGroups);
 }
示例#2
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <Generation> descriptor)
 {
     descriptor.Description(@"A generation is a grouping of the Pokémon games that separates them based on the Pokémon they include.
         In each generation, a new set of Pokémon, Moves, Abilities and Types that did not exist in the previous generation are released.");
     descriptor.UseNamedApiResourceCollectionField <Generation, Ability, AbilityType>(x => x.Abilities);
     descriptor.UseNamedApiResourceField <Generation, Region, RegionType>(x => x.MainRegion);
     descriptor.UseNamedApiResourceCollectionField <Generation, Move, MoveType>(x => x.Moves);
     descriptor.UseNamedApiResourceCollectionField <Generation, PokemonSpecies, PokemonSpeciesType>(x => x.PokemonSpecies);
     descriptor.UseNamedApiResourceCollectionField <Generation, Type, TypePropertyType>(x => x.Types);
     descriptor.UseNamedApiResourceCollectionField <Generation, VersionGroup, VersionGroupType>(x => x.VersionGroups);
 }
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <VersionGroup> descriptor)
 {
     descriptor.Description("Version groups categorize highly similar versions of the games.");
     descriptor.Field(x => x.Order)
     .Description("Order for sorting. Almost by date of release, except similar versions are grouped together.");
     descriptor.UseNamedApiResourceField <VersionGroup, Generation, GenerationType>(x => x.Generation);
     descriptor.UseNamedApiResourceCollectionField <VersionGroup, MoveLearnMethod, MoveLearnMethodType>(x => x.MoveLearnMethods);
     descriptor.UseNamedApiResourceCollectionField <VersionGroup, Pokedex, PokedexType>(x => x.Pokedexes);
     descriptor.UseNamedApiResourceCollectionField <VersionGroup, Region, RegionType>(x => x.Regions);
     descriptor.UseNamedApiResourceCollectionField <VersionGroup, Version, VersionType>(x => x.Versions);
 }
示例#4
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <Item> descriptor)
 {
     descriptor.Description(@"An item is an object in the games which the player can pick up, keep in their bag, and use in some manner. 
         They have various uses, including healing, powering up, helping catch Pokémon, or to access a new area.");
     descriptor.Field(x => x.Cost)
     .Description("The price of this item in stores.");
     descriptor.Field(x => x.FlingPower)
     .Description("The power of the move Fling when used with this item.");
     descriptor.UseNullableNamedApiResourceField <Item, ItemFlingEffect, ItemFlingEffectType>(x => x.FlingEffect);
     descriptor.UseNamedApiResourceCollectionField <Item, ItemAttribute, ItemAttributeType>(x => x.Attributes);
     descriptor.UseNamedApiResourceField <Item, ItemCategory, ItemCategoryType>(x => x.Category);
     descriptor.Field(x => x.HeldByPokemon)
     .Description("A list of pokémon that might be found in the wild holding this item.")
     .Type <ListType <ItemHolderPokemonType> >();
     descriptor.Field(x => x.GameIndices)
     .Description("A list of game indices relevent to this item by generation.")
     .Type <ListType <GenerationGameIndexType> >();
     descriptor.UseNullableApiResourceField <Item, EvolutionChain, EvolutionChainType>(x => x.BabyTriggerFor);
     descriptor.Field(x => x.EffectEntries)
     .Description("The effect of this ability listed in different languages.")
     .Type <ListType <VerboseEffectType> >();
     descriptor.Field(x => x.FlavorGroupTextEntries)
     .Description("The flavor text of this ability listed in different languages.")
     .Type <ListType <VersionGroupFlavorTextType> >();
 }
示例#5
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <PokemonColor> descriptor)
 {
     descriptor.Description(@"Colors used for sorting pokémon in a pokédex. 
         The color listed in the Pokédex is usually the color most apparent or covering each Pokémon's body. 
         No orange category exists; Pokémon that are primarily orange are listed as red or brown.");
     descriptor.UseNamedApiResourceCollectionField <PokemonColor, PokemonSpecies, PokemonSpeciesType>(x => x.PokemonSpecies);
 }
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <ItemFlingEffect> descriptor)
 {
     descriptor.Description("The various effects of the move \"Fling\" when used with different items.");
     descriptor.Field(x => x.EffectEntries)
     .Description("The result of this fling effect listed in different languages.")
     .Type <ListType <EffectsType> >();
     descriptor.UseNamedApiResourceCollectionField <ItemFlingEffect, Item, ItemType>(x => x.Items);
 }
        /// <inheritdoc/>
        protected override void ConcreteConfigure(IObjectTypeDescriptor <ItemAttribute> descriptor)
        {
            descriptor.Description("Item attributes define particular aspects of items, e.g. \"usable in battle\" or \"consumable\".");
            descriptor.UseNamedApiResourceCollectionField <ItemAttribute, Item, ItemType>(x => x.Items);

            // TODO add missing field
            descriptor.Ignore(x => x.Descriptions);
        }
示例#8
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <PokemonShape> descriptor)
 {
     descriptor.Description("Shapes used for sorting pokémon in a pokédex.");
     descriptor.Field(x => x.AwesomeNames)
     .Description("The \"scientific\" name of this pokémon shape listed in different languages.")
     .Type <ListType <AwesomeNameType> >();
     descriptor.UseNamedApiResourceCollectionField <PokemonShape, PokemonSpecies, PokemonSpeciesType>(x => x.PokemonSpecies);
 }
示例#9
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <Location> descriptor)
 {
     descriptor.Description("Locations that can be visited within the games. Locations make up sizable portions of regions, like cities or routes.");
     descriptor.UseNamedApiResourceField <Location, Region, RegionType>(x => x.Region);
     descriptor.Field(x => x.GameIndices)
     .Description("A list of game indices relevent to this location by generation.")
     .Type <ListType <GenerationGameIndexType> >();
     descriptor.UseNamedApiResourceCollectionField <Location, LocationArea, LocationAreaType>(x => x.Areas);
 }
示例#10
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <Gender> descriptor)
 {
     descriptor.Description(@"Genders were introduced in Generation II for the purposes of breeding pokémon 
         but can also result in visual differences or even different evolutionary lines.");
     descriptor.Field(x => x.PokemonSpeciesDetails)
     .Description("A list of pokémon species that can be this gender and how likely it is that they will be.")
     .Type <ListType <PokemonSpeciesGenderType> >();
     descriptor.UseNamedApiResourceCollectionField <Gender, PokemonSpecies, PokemonSpeciesType>(x => x.RequiredForEvolution);
 }
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <SuperContestEffect> descriptor)
 {
     descriptor.Description("Super contest effects refer to the effects of moves when used in super contests.");
     descriptor.Field(x => x.Appeal)
     .Description("The level of appeal this super contest effect has.");
     descriptor.UseNamedApiResourceCollectionField <SuperContestEffect, Move, MoveType>(x => x.Moves);
     descriptor.Field(x => x.FlavorTextEntries)
     .Description("The flavor text of this contest effect listed in different languages.")
     .Type <ListType <FlavorTextType> >();
 }
示例#12
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <GrowthRate> descriptor)
 {
     descriptor.Description("Growth rates are the speed with which pokémon gain levels through experience.");
     descriptor.Ignore(x => x.Descriptions);
     descriptor.Field(x => x.Formula)
     .Description("The formula used to calculate the rate at which the pokémon species gains level.")
     .Type <NonNullType <StringType> >();
     descriptor.Field(x => x.Levels)
     .Description("A list of levels and the amount of experienced needed to atain them based on this growth rate.")
     .Type <ListType <GrowthRateExperienceLevelType> >();
     descriptor.UseNamedApiResourceCollectionField <GrowthRate, PokemonSpecies, PokemonSpeciesType>(x => x.PokemonSpecies);
 }
示例#13
0
 protected override void Configure(IObjectTypeDescriptor <TypeRelations> descriptor)
 {
     descriptor.UseNamedApiResourceCollectionField <TypeRelations, TypeProperty, TypePropertyType>(x => x.NoDamageTo);
     descriptor.UseNamedApiResourceCollectionField <TypeRelations, TypeProperty, TypePropertyType>(x => x.HalfDamageTo);
     descriptor.UseNamedApiResourceCollectionField <TypeRelations, TypeProperty, TypePropertyType>(x => x.DoubleDamageTo);
     descriptor.UseNamedApiResourceCollectionField <TypeRelations, TypeProperty, TypePropertyType>(x => x.NoDamageFrom);
     descriptor.UseNamedApiResourceCollectionField <TypeRelations, TypeProperty, TypePropertyType>(x => x.HalfDamageFrom);
     descriptor.UseNamedApiResourceCollectionField <TypeRelations, TypeProperty, TypePropertyType>(x => x.DoubleDamageFrom);
 }
示例#14
0
        /// <inheritdoc/>
        protected override void ConcreteConfigure(IObjectTypeDescriptor <Pokedex> descriptor)
        {
            descriptor.Description(@"A Pokédex is a handheld electronic encyclopedia device; one which is capable of recording 
            and retaining information of the various Pokémon in a given region with the exception of the national dex
            and some smaller dexes related to portions of a region.");
            descriptor.Field(x => x.IsMainSeries)
            .Description("Whether or not this pokédex originated in the main series of the video games.");
            descriptor.Field(x => x.PokemonEntries)
            .Description("A list of pokémon catalogued in this pokédex  and their indexes.")
            .Type <ListType <PokemonEntryType> >();
            descriptor.UseNamedApiResourceField <Pokedex, Region, RegionType>(x => x.Region);
            descriptor.UseNamedApiResourceCollectionField <Pokedex, VersionGroup, VersionGroupType>(x => x.VersionGroups);

            // TODO: implement ignored field
            descriptor.Ignore(x => x.Descriptions);
        }
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <PokemonSpecies> descriptor)
 {
     descriptor.Description(@"A Pokémon Species forms the basis for at least one pokémon. 
         Attributes of a Pokémon species are shared across all varieties of pokémon within the species. 
         A good example is Wormadam; Wormadam is the species which can be found in three different varieties, Wormadam-Trash, Wormadam-Sandy and Wormadam-Plant.");
     descriptor.Ignore(x => x.FormDescriptions);
     descriptor.Field(x => x.Order)
     .Description(@"The order in which species should be sorted.
             Based on National Dex order, except families are grouped together and sorted by stage.");
     descriptor.Field(x => x.GenderRate)
     .Description("The chance of this Pokémon being female, in eighths; or -1 for genderless.");
     descriptor.Field(x => x.CaptureRate)
     .Description("The base capture rate; up to 255. The higher the number, the easier the catch.");
     descriptor.Field(x => x.BaseHappiness)
     .Description("The happiness when caught by a normal pokéball; up to 255. The higher the number, the happier the pokémon.");
     descriptor.Field(x => x.IsBaby)
     .Description("Whether or not this is a baby pokémon.");
     descriptor.Field(x => x.HatchCounter)
     .Description("Initial hatch counter: one must walk 255 × (hatch_counter + 1) steps before this Pokémon's egg hatches, unless utilizing bonuses like Flame Body's.");
     descriptor.Field(x => x.HasGenderDifferences)
     .Description("Whether or not this pokémon can have different genders.");
     descriptor.Field(x => x.FormsSwitchable)
     .Description("Whether or not this pokémon has multiple forms and can switch between them.");
     descriptor.UseNamedApiResourceField <PokemonSpecies, GrowthRate, GrowthRateType>(x => x.GrowthRate);
     descriptor.Field(x => x.PokedexNumbers)
     .Description("A list of pokedexes and the indexes reserved within them for this pokémon species.")
     .Type <ListType <PokemonSpeciesDexEntryType> >();
     descriptor.UseNamedApiResourceCollectionField <PokemonSpecies, EggGroup, EggGroupType>(x => x.EggGroups);
     descriptor.UseNamedApiResourceField <PokemonSpecies, PokemonColor, PokemonColorType>(x => x.Color);
     descriptor.UseNamedApiResourceField <PokemonSpecies, PokemonShape, PokemonShapeType>(x => x.Shape);
     descriptor.UseNullableNamedApiResourceField <PokemonSpecies, PokemonSpecies, PokemonSpeciesType>(x => x.EvolvesFromSpecies);
     descriptor.UseApiResourceField <PokemonSpecies, EvolutionChain, EvolutionChainType>(x => x.EvolutionChain);
     descriptor.UseNamedApiResourceField <PokemonSpecies, PokemonHabitat, PokemonHabitatType>(x => x.Habitat);
     descriptor.UseNamedApiResourceField <PokemonSpecies, Generation, GenerationType>(x => x.Generation);
     descriptor.Field(x => x.PalParkEncounters)
     .Description("A list of encounters that can be had with this pokémon species in pal park.")
     .Type <ListType <PalParkEncounterAreaType> >();
     descriptor.Field(x => x.Genera)
     .Description("The genus of this pokémon species listed in multiple languages.")
     .Type <ListType <GenusType> >();
     descriptor.Field(x => x.Varieties)
     .Description("A list of the pokémon that exist within this pokémon species.")
     .Type <ListType <PokemonSpeciesVarietyType> >();
     descriptor.Field(x => x.FlavorTextEntries)
     .Type <ListType <PokemonSpeciesFlavorTextsType> >();
 }
示例#16
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <TypeProperty> descriptor)
 {
     descriptor.Description(@"Types are properties for Pokémon and their moves. 
         Each type has three properties: which types of Pokémon it is super effective against, which types of Pokémon it is not very effective against
         and which types of Pokémon it is completely ineffective against.");
     descriptor.Field(x => x.DamageRelations)
     .Description("A detail of how effective this type is toward others and vice versa.")
     .Type <TypeRelationsType>();
     descriptor.Field(x => x.GameIndices)
     .Description("A list of game indices relevent to this item by generation.")
     .Type <ListType <GenerationGameIndexType> >();
     descriptor.UseNamedApiResourceField <TypeProperty, Generation, GenerationType>(x => x.Generation);
     descriptor.UseNamedApiResourceField <TypeProperty, MoveDamageClass, MoveDamageClassType>(x => x.MoveDamageClass);
     descriptor.Field(x => x.Pokemon)
     .Description("A list of details of pokemon that have this type.")
     .Type <ListType <TypePokemonType> >();
     descriptor.UseNamedApiResourceCollectionField <TypeProperty, Move, MoveType>(x => x.Moves);
 }
示例#17
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <Pokemon> descriptor)
 {
     descriptor.Description(@"Pokémon are the creatures that inhabit the world of the pokemon games. 
         They can be caught using pokéballs and trained by battling with other pokémon.");
     descriptor.Ignore(x => x.Sprites);
     descriptor.Field(x => x.BaseExperience)
     .Description("The base experience gained for defeating this pokémon.");
     descriptor.Field(x => x.Height)
     .Description("The height of this pokémon.");
     descriptor.Field(x => x.IsDefault)
     .Description("Set for exactly one pokémon used as the default for each species.");
     descriptor.Field(x => x.Order)
     .Description("Order for sorting. Almost national order, except families are grouped together.");
     descriptor.Field(x => x.Weight)
     .Description("The mass of this pokémon.");
     descriptor.Field(x => x.Abilities)
     .Description("A list of abilities this pokémon could potentially have.")
     .Type <ListType <PokemonAbilityType> >();
     descriptor.UseNamedApiResourceCollectionField <Pokemon, PokemonForm, PokemonFormType>(x => x.Forms);
     descriptor.UseNamedApiResourceField <Pokemon, PokemonSpecies, PokemonSpeciesType>(x => x.Species);
     descriptor.Field(x => x.Types)
     .Description("A list of details showing types this pokémon has.")
     .Type <ListType <PokemonTypeMapType> >();
     descriptor.Field(x => x.HeldItems)
     .Description("A list of items this pokémon may be holding when encountered.")
     .Type <ListType <PokemonHeldItemType> >();
     descriptor.Field(x => x.Moves)
     .Description("A list of moves along with learn methods and level details pertaining to specific version groups.")
     .Type <ListType <PokemonMoveType> >();
     descriptor.Field(x => x.Stats)
     .Description("A list of base stat values for this pokémon.")
     .Type <ListType <PokemonStatType> >();
     descriptor.Field(x => x.GameIndicies)
     .Description("A list of game indices relevent to pokémon item by generation.")
     .Type <ListType <VersionGameIndexType> >();
     descriptor.Field(x => x.LocationAreaEncounters)
     .Description("A list of location areas as well as encounter details pertaining to specific versions.")
     .Type <ListType <LocationAreaEncounterType> >()
     .Resolver((ctx, token) => ctx.Service <UrlResolver>().GetAsync <LocationAreaEncounter[]>(ctx.Parent <Pokemon>().LocationAreaEncounters));
 }
示例#18
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <ItemCategory> descriptor)
 {
     descriptor.Description("Item categories determine where items will be placed in the players bag.");
     descriptor.UseNamedApiResourceCollectionField <ItemCategory, Item, ItemType>(x => x.Items);
     descriptor.UseNamedApiResourceField <ItemCategory, ItemPocket, ItemPocketType>(x => x.Pocket);
 }
示例#19
0
 /// <inheritdoc/>
 protected override void Configure(IObjectTypeDescriptor <Encounter> descriptor)
 {
     descriptor.UseNamedApiResourceCollectionField <Encounter, EncounterConditionValue, EncounterConditionValueType>(x => x.ConditionValues);
     descriptor.UseNamedApiResourceField <Encounter, EncounterMethod, EncounterMethodType>(x => x.Method);
 }
示例#20
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <MoveAilment> descriptor)
 {
     descriptor.Description("Move Ailments are status conditions caused by moves used during battle.");
     descriptor.UseNamedApiResourceCollectionField <MoveAilment, Move, MoveType>(x => x.Moves);
 }
示例#21
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <ItemPocket> descriptor)
 {
     descriptor.Description("Pockets within the players bag used for storing items by category.");
     descriptor.UseNamedApiResourceCollectionField <ItemPocket, ItemCategory, ItemCategoryType>(x => x.Categories);
 }
示例#22
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <MoveTarget> descriptor)
 {
     descriptor.Description("Targets moves can be directed at during battle. Targets can be pokémon, environments or even other moves.");
     descriptor.Ignore(x => x.Descriptions);
     descriptor.UseNamedApiResourceCollectionField <MoveTarget, Move, MoveType>(x => x.Moves);
 }
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <EvolutionTrigger> descriptor)
 {
     descriptor.Description("Evolution triggers are the events and conditions that cause a pokémon to evolve.");
     descriptor.UseNamedApiResourceCollectionField <EvolutionTrigger, PokemonSpecies, PokemonSpeciesType>(x => x.PokemonSpecies);
 }
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <EncounterCondition> descriptor)
 {
     descriptor.Description("Conditions which affect what pokémon might appear in the wild, e.g., day or night.");
     descriptor.UseNamedApiResourceCollectionField <EncounterCondition, EncounterConditionValue, EncounterConditionValueType>(x => x.Values);
 }
示例#25
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <MoveLearnMethod> descriptor)
 {
     descriptor.Description("Methods by which pokémon can learn moves.");
     descriptor.Ignore(x => x.Descriptions);
     descriptor.UseNamedApiResourceCollectionField <MoveLearnMethod, VersionGroup, VersionGroupType>(x => x.VersionGroups);
 }
示例#26
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <MoveCategory> descriptor)
 {
     descriptor.Description("Very general categories that loosely group move effects.");
     descriptor.Ignore(x => x.Descriptions);
     descriptor.UseNamedApiResourceCollectionField <MoveCategory, Move, MoveType>(x => x.Moves);
 }
示例#27
0
 protected override void Configure(IObjectTypeDescriptor <NatureStatAffectSets> descriptor)
 {
     descriptor.UseNamedApiResourceCollectionField <NatureStatAffectSets, Nature, NatureType>(x => x.Increase);
     descriptor.UseNamedApiResourceCollectionField <NatureStatAffectSets, Nature, NatureType>(x => x.Decrease);
 }
示例#28
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <PokemonHabitat> descriptor)
 {
     descriptor.Description(@"Habitats are generally different terrain pokémon can be found in 
         but can also be areas designated for rare or legendary pokémon.");
     descriptor.UseNamedApiResourceCollectionField <PokemonHabitat, PokemonSpecies, PokemonSpeciesType>(x => x.PokemonSpecies);
 }
示例#29
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <MoveDamageClass> descriptor)
 {
     descriptor.Description("Damage classes moves can have, e.g. physical, special, or status (non-damaging).");
     descriptor.Ignore(x => x.Descriptions);
     descriptor.UseNamedApiResourceCollectionField <MoveDamageClass, Move, MoveType>(x => x.Moves);
 }
示例#30
0
 /// <inheritdoc/>
 protected override void ConcreteConfigure(IObjectTypeDescriptor <EggGroup> descriptor)
 {
     descriptor.Description(@"Egg Groups are categories which determine which Pokémon are able to interbreed. 
         Pokémon may belong to either one or two Egg Groups.");
     descriptor.UseNamedApiResourceCollectionField <EggGroup, PokemonSpecies, PokemonSpeciesType>(x => x.PokemonSpecies);
 }