C# Class DivineRightGame.ItemFactory.ItemFactoryManagers.InventoryItemManager

For creating inventory items
Inheritance: IItemFactoryManager
Afficher le fichier Open project: Haedrian/Divine-Right Class Usage Examples

Méthodes publiques

Méthode Description
CreateItem ( List parameters ) : MapItem
CreateItem ( int internalID ) : MapItem
CreateItem ( int itemID, string name, string description, string graphic, int value, bool equippable, int armourRating, int damageRating, string damageType, string category, string equippableLocation, int woundPotential, int stunAmount, bool stackable, int effect, int effectPower, bool isRanged ) : MapItem
FillTreasureChest ( InventoryCategory categories, int spendValue ) : List

Fills a treasure chest as follows: 1. Pick a random category. Produce an item of that category costing between 1/5 and 3/3 of the remaining value 2. Repeat 1 for 6 more times 3. Done

GetBestCanAfford ( string tag, int maximum ) : InventoryItem

Returns the most expensive item of that particular tag which still costs less or equal to the maximum

GetItemWithinPriceRange ( string category, int minimum, int maximum ) : InventoryItem

Creates an item with an optional category costing between a minimum and maximum price

GetItemsWithAMaxValue ( string category, int maximum ) : List

Creates a number of items having a total maximum value (or as close as possible to) the assigned value.

Method Details

CreateItem() public méthode

public CreateItem ( List parameters ) : MapItem
parameters List
Résultat DRObjects.MapItem

CreateItem() public méthode

public CreateItem ( int internalID ) : MapItem
internalID int
Résultat DRObjects.MapItem

CreateItem() public méthode

public CreateItem ( int itemID, string name, string description, string graphic, int value, bool equippable, int armourRating, int damageRating, string damageType, string category, string equippableLocation, int woundPotential, int stunAmount, bool stackable, int effect, int effectPower, bool isRanged ) : MapItem
itemID int
name string
description string
graphic string
value int
equippable bool
armourRating int
damageRating int
damageType string
category string
equippableLocation string
woundPotential int
stunAmount int
stackable bool
effect int
effectPower int
isRanged bool
Résultat DRObjects.MapItem

FillTreasureChest() public méthode

Fills a treasure chest as follows: 1. Pick a random category. Produce an item of that category costing between 1/5 and 3/3 of the remaining value 2. Repeat 1 for 6 more times 3. Done
public FillTreasureChest ( InventoryCategory categories, int spendValue ) : List
categories InventoryCategory
spendValue int
Résultat List

GetBestCanAfford() public méthode

Returns the most expensive item of that particular tag which still costs less or equal to the maximum
public GetBestCanAfford ( string tag, int maximum ) : InventoryItem
tag string
maximum int
Résultat DRObjects.Items.Archetypes.Local.InventoryItem

GetItemWithinPriceRange() public méthode

Creates an item with an optional category costing between a minimum and maximum price
public GetItemWithinPriceRange ( string category, int minimum, int maximum ) : InventoryItem
category string
minimum int
maximum int
Résultat DRObjects.Items.Archetypes.Local.InventoryItem

GetItemsWithAMaxValue() public méthode

Creates a number of items having a total maximum value (or as close as possible to) the assigned value.
public GetItemsWithAMaxValue ( string category, int maximum ) : List
category string
maximum int
Résultat List