Exemple #1
0
 public override void ParseXML(XMLNode x)
 {
     base.ParseXML(x);
     Type    = x.Key;
     onEquip = x.Select <Spell>("OnEquipEffect");
     onUse   = x.Select <Spell>("OnUseEffect");
     onEaten = x.Select <Spell>("OnEatenEffect");
     onHit   = x.Select <Spell>("OnHitEffect");
     stats   = x.Select <ItemStats>("stats");
     Icon    = x.SelectString("icon");
 }
Exemple #2
0
 public void ParseXML(XMLNode x)
 {
     Weight        = x.SelectInt("weight");
     Cost          = x.SelectInt("cost");
     Nutrition     = x.SelectInt("nutrition");
     damage        = x.Select <Damage>("damage");
     EquipType     = x.SelectEnum <EquipType>("equiptype");
     NumberOfSlots = x.SelectInt("slots", 1);
 }
Exemple #3
0
    public void ParseXML(XMLNode x)
    {
        this.Name     = x.SelectString("name");
        this.Hardness = x.SelectInt("hardness");
        this.Burns    = x.SelectBool("burns");
        this.Oxidizes = x.SelectBool("oxidizes");

        XMLNode densityNode = x.Select("density");

        density[0]   = densityNode.SelectFloat("min");
        density[2]   = densityNode.SelectFloat("max");
        density[1]   = (density[0] + density[2]) / 2;
        this.Density = density[Probability.getRandomInt(3)];

        this.MeltingPoint = x.SelectInt("meltingpoint");
    }
Exemple #4
0
 public override void ParseXML(XMLNode x)
 {
     base.ParseXML(x);
     Attributes    = x.Select <AttributesData>("attributes");
     Stats         = x.Select <Stats>("stats");
     Flags         = new GenericFlags <NPCFlags>(x.SelectEnums <NPCFlags>("flags"));
     SpawnKeywords = new GenericFlags <SpawnKeywords>(x.SelectEnums <SpawnKeywords>("spawnkeywords"));
     KnownSpells   = x.Select <Spells>("spells");
     StartingItems = x.Select <StartingItems>("startingitems");
     Equipment     = x.Select <Equipment>("equipslots");
     NaturalWeapon = x.Select <Item>("naturalweapon");
     //parse AI packages
 }
Exemple #5
0
 protected override void ParseParams(XMLNode node)
 {
     strength = node.Select <Damage>("strength");
 }