//The statistics are set. public Item(string hash, string name, int maxDurability) { this.hash = hash; this.name = name; durability = new CappedStatistic("durability", maxDurability); }
public Mob(String name, int health, int x, int y, bool player) : base(20, player) { this.x = x; this.y = y; this.name = name; this.width = 0; this.height = 0; this.health = new CappedStatistic("health", health); }
public Player(String name, int health, int x, int y) : base(name, health, x, y, true) { ammo = new CappedStatistic("ammo", 0); this.width = 32; this.height = 32; strength = new Statistic("strength", 0); intelligence = new Statistic("intelligence", 0); credits = new CappedStatistic("credits", 500); // stamina = new Statistic("stamina", 0); speed = new Statistic("speed", 0); wisdom = new Statistic("wisdom", 0); playerClass = PlayerClass.ROGUE; EquippableItem shirt = (EquippableItem)ItemFactoryManager.getInstance().createEquippableItem("Shirt.xml"); EquippableItem pants = (EquippableItem)ItemFactoryManager.getInstance().createEquippableItem("Pants.xml"); EquippableItem boots = (EquippableItem)ItemFactoryManager.getInstance().createEquippableItem("Boots.xml"); EquippableItem helm = (EquippableItem)ItemFactoryManager.getInstance().createEquippableItem("Helm.xml"); Weapon weapon = (Weapon)ItemFactoryManager.getInstance().createWeapon(); this.chest = this.boots = this.helm = this.weapon = this.legs = ""; weapon.addUsableEffect(new TimedEffectTest(weapon, 7 * 1000, 2 * 1000)); getAmmo().setMaxValue(120); getAmmo().setValue(16); credits.setValue(0); setIntelligenceValue(5); setWisdomValue(7); setStrengthValue(8); this.add(shirt); this.add(pants); this.add(boots); this.add(helm); this.add(weapon); equipItem(shirt); equipItem(pants); equipItem(boots); equipItem(helm); equipItem(weapon); }
public Weapon(String hash, string name, CappedStatistic durability, Statistic attack, Statistic speed) : base(hash,name,durability, EquipSlot.UNDEFINED) { this.attack = attack; this.speed = speed; }
public Item(string hash, string name, CappedStatistic durability) { this.hash = hash; this.name = name; this.durability = durability; }
public EquippableItem(String hash, string name, CappedStatistic durability, EquipSlot es) : base(hash, name, durability) { this.equipSlot = es; }