Ejemplo n.º 1
0
 protected Spell(Character source, GameWorld gameWorld, int range)
 {
     Source = source;
     GameWorld = gameWorld;
     Range = range;
     Init();
 }
 public SpellShieldNova(Character source, GameWorld gameWorld, int range)
     : base(source, gameWorld, range)
 {
     Image = Properties.Resources.SpellNova;
     DrawBehavior.IsCircle = true;
     MotionBehavior = new StationaryMotionBehavior(this, gameWorld);
 }
Ejemplo n.º 3
0
 public Frostball(Character source, GameWorld gameWorld, int range)
     : base(source, gameWorld, range)
 {
     Image = Properties.Resources.Frostbolt_small;
     if(!SpellHandler.Cooldowns.ContainsKey(typeof(IceGround)))
         SpellHandler.Cooldowns.Add(typeof(IceGround), new Cooldown(0));
 }
Ejemplo n.º 4
0
 public SpellTree(Character character)
 {
     this.character = character;
     AttackMap = new Dictionary<Type, Func<Spell>>();
     spells = new Dictionary<Type, int>();
     LoadSpells();
 }
Ejemplo n.º 5
0
 public IceGround(Character source, GameWorld gameWorld, int range) : base(source, gameWorld, range)
 {
     Image = Properties.Resources.IceGround;
     this.MotionBehavior = new StationaryMotionBehavior(this, gameWorld);
     Paralax = Paralax.Background;
     affectedCharacters = new List<Character>();
     Cost = 0;
     gameWorld.Split += gameWorld_Split;
     SlowPercentage = 25;
     Exit();
 }
Ejemplo n.º 6
0
 public SpellHandler(GameWorld gameWorld, Character source)
 {
     this.GameWorld = gameWorld;
     this.Source = source;
     Init();
 }
 public NormalDamageBehavior(Character source, IEnumerable<Type> targetTypes, int damage)
 {
     Damage = damage;
     this.Source = source;
     this.TargetTypes = targetTypes.ToList();
 }
Ejemplo n.º 8
0
 public Lightningbolt(Character source, GameWorld gameWorld, int range)
     : base(source, gameWorld, range)
 {
 }
Ejemplo n.º 9
0
 public Fireball(Character source, GameWorld gameWorld, int range)
     : base(source, gameWorld, range)
 {
     Image = Properties.Resources.Fireball;
 }
Ejemplo n.º 10
0
 public void TakeDamage(IDamageBehavior damageBehavior, Character source)
 {
     Health.Use(damageBehavior.Damage);
     if (Health.Current <= 0) Killed(this, source);
 }