Exemplo n.º 1
0
 public void ParseXML(XMLNode x)
 {
     MaxHealth = x.SelectInt("maxhealth");
     MaxPower  = x.SelectInt("maxpower");
     Level     = x.SelectUShort("level");
     initialize();
 }
Exemplo n.º 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);
 }
Exemplo n.º 3
0
    public void ParseXML(XMLNode spell)
    {
        range = spell.SelectInt("range");
        cost  = spell.SelectInt("cost");
        // If no targeter specified, assume self
        AddAspect(new Self(), GetEffects(spell.SelectList("effect")));

        foreach (XMLNode targeter in spell.SelectList("targeter"))
        {
            string targeterType = targeter.SelectString("type");
            AddAspect(BigBoss.Types.Instantiate <ITargeter>(targeterType), GetEffects(targeter.SelectList("effect")));
        }
    }
Exemplo n.º 4
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");
    }
Exemplo n.º 5
0
 //This initialize is called upon parsing the XML
 public void ParseXML(XMLNode x)
 {
     // Call this once at parsing
     InitTargetTypes();
     TurnsToProcess = x.SelectInt("turns");
     this.IsActive  = false;
     ParseParams(x);
 }
Exemplo n.º 6
0
 public void ParseXML(XMLNode x)
 {
     Strength     = x.SelectInt("strength");
     Charisma     = x.SelectInt("charisma");
     Intelligence = x.SelectInt("intelligence");
     Wisdom       = x.SelectInt("wisdom");
     Dexterity    = x.SelectInt("dexterity");
     Constitution = x.SelectInt("constitution");
     Size         = x.SelectEnum <Size>("size");
 }
Exemplo n.º 7
0
 public void ParseXML(XMLNode x)
 {
     Arms  = x.SelectInt("arms");
     Legs  = x.SelectInt("legs");
     Heads = x.SelectInt("heads");
 }
Exemplo n.º 8
0
 protected override void ParseParams(XMLNode x)
 {
     strength       = x.SelectInt("strength");
     slowPercentage = x.SelectFloat("slow");
 }
Exemplo n.º 9
0
 protected override void ParseParams(XMLNode x)
 {
     strength = x.SelectInt("strength");
 }