Beispiel #1
0
 internal Spell(string name, Unit con, SpellBook spells)
 {
     _unitContext  = con;
     _cd           = new Cooldown(Convert.ToUInt16(spells.SpellList[name]["Cooldown"]));
     _name         = name;
     _description  = spells.SpellList[name]["Description"];
     _damages      = Convert.ToUInt16(spells.SpellList[name]["Dégâts"]);
     _castingTime  = Convert.ToUInt16(spells.SpellList[name]["CastTime"]);
     _dotFrequency = (uint)Convert.ToUInt16(spells.SpellList[name]["Durée"]) / Convert.ToUInt16(spells.SpellList[name]["Fréquence"]);
     _range        = (float)Convert.ToDouble(spells.SpellList[name]["Range"]);
     _duration     = Convert.ToUInt16(spells.SpellList[name]["Durée"]);
     _areaOfEffect = (float)Convert.ToDouble(spells.SpellList[name]["Zone d'effet"]);
 }
Beispiel #2
0
 internal Unit(
     float posX,
     float posY,
     string name,
     Map context
     )
 {
     _job           = name;
     _lifePoints    = Convert.ToUInt32(context.GetVillage.Beasts.Beasts[name]["Vie"]);
     _maxLifePoints = Convert.ToUInt32(context.GetVillage.Beasts.Beasts[name]["Vie"]);;
     _dmg           = Convert.ToUInt32(context.GetVillage.Beasts.Beasts[name]["Dégâts"]);;
     _armor         = Convert.ToUInt32(context.GetVillage.Beasts.Beasts[name]["Armure"]);;
     _isMoving      = false;
     _aaCooldown    = new Cooldown(Convert.ToUInt32(context.GetVillage.Beasts.Beasts[name]["Cooldown"]));
     _speed         = (float)Convert.ToDouble(context.GetVillage.Beasts.Beasts[name]["Vitesse"]);;
     _context       = context;
     _range         = (float)Convert.ToDouble(context.GetVillage.Beasts.Beasts[name]["Range"]);;
     _position      = new Vectors(posX, posY);
 }