Пример #1
0
 /// <summary>
 /// Creates a new weapon with specified name and attributes.
 /// </summary>
 public Weapon(WeaponProperties data, CombatProperties propes, Attributes attri, StatusEffectProperties effect)
 {
     WeaponData = data;
     CombatProperties = propes;
     Attributes = attri;
     Effect = effect;
 }
Пример #2
0
 /// <summary>
 /// Applies a status effect to this entity
 /// </summary>
 public void ApplyStatusEffect(StatusEffectProperties attributes)
 {
     var constructor = Helper.GetObjectConstructor<StatusEffect>(string.Format("Corvus.Components.Gameplay.StatusEffects.{0}", attributes.EffectType), new Type[] { typeof(Entity), typeof(StatusEffectProperties) });
     var statusEffect = constructor(this.Parent, attributes);
     if (!_StatusEffects.Contains(statusEffect.Name))
         CorvEngine.AudioManager.PlaySoundEffect((statusEffect.IsPositive) ? "StatusEffectGood" : "Curse2");
     _StatusEffects.Add(statusEffect);
 }
Пример #3
0
 /// <summary>
 /// Creates a new instance of StatusEffect.
 /// </summary>
 /// <param name="entity">The entity being affected.</param>
 public StatusEffect(Entity entity, StatusEffectProperties attributes)
 {
     var effect = CorvusGame.Instance.GlobalContent.LoadSprite(SpriteName);
     var animation = effect.Animations.First();
     effect.PlayAnimation(animation.Name);
     this._Sprite = effect;
     this._Entity = entity;
     this._Attributes = attributes;
     FloatingTextComponent = entity.GetComponent<FloatingTextComponent>();
 }
Пример #4
0
        /// <summary>
        /// Creates a new instance of StatusEffect.
        /// </summary>
        /// <param name="entity">The entity being affected.</param>
        public StatusEffect(Entity entity, StatusEffectProperties attributes)
        {
            var effect    = CorvusGame.Instance.GlobalContent.LoadSprite(SpriteName);
            var animation = effect.Animations.First();

            effect.PlayAnimation(animation.Name);
            this._Sprite          = effect;
            this._Entity          = entity;
            this._Attributes      = attributes;
            FloatingTextComponent = entity.GetComponent <FloatingTextComponent>();
        }
Пример #5
0
 //Unfortunately, need to specify this in order for StatusEffectsComponent to work properly.
 public Poison(Entity entity, StatusEffectProperties attributes) : base(entity, attributes)
 {
 }
Пример #6
0
 public Fleet(Entity entity, StatusEffectProperties prop)
     : base(entity, prop)
 {
 }
Пример #7
0
 //Unfortunately, need to specify this in order for StatusEffectsComponent to work properly.
 public Poison(Entity entity, StatusEffectProperties attributes)
     : base(entity, attributes)
 {
 }
Пример #8
0
 public Healing(Entity entity, StatusEffectProperties attributes)
     : base(entity, attributes)
 {
 }
Пример #9
0
 public Pierce(Entity entity, StatusEffectProperties prop)
     : base(entity, prop)
 {
 }
Пример #10
0
 public Slow(Entity entity, StatusEffectProperties prop) : base(entity, prop)
 {
 }
Пример #11
0
 public Recover(Entity entity, StatusEffectProperties prop)
     : base(entity, prop)
 {
 }
Пример #12
0
 public Fleet(Entity entity, StatusEffectProperties prop) : base(entity, prop)
 {
 }
Пример #13
0
 public ManaHeal(Entity entity, StatusEffectProperties sep)
     : base(entity, sep)
 {
 }
Пример #14
0
 public Healing(Entity entity, StatusEffectProperties attributes) : base(entity, attributes)
 {
 }
Пример #15
0
 public Vigor(Entity entity, StatusEffectProperties prop) : base(entity, prop)
 {
 }
Пример #16
0
 public ManaHeal(Entity entity, StatusEffectProperties sep) : base(entity, sep)
 {
 }
Пример #17
0
 public IWorkOut(Entity entity, StatusEffectProperties prop) : base(entity, prop)
 {
 }
Пример #18
0
 public IWorkOut(Entity entity, StatusEffectProperties prop)
     : base(entity, prop)
 {
 }
Пример #19
0
 public Pierce(Entity entity, StatusEffectProperties prop) : base(entity, prop)
 {
 }
Пример #20
0
 public Weakness(Entity entity, StatusEffectProperties prop)
     : base(entity, prop)
 {
 }
Пример #21
0
 public Vigor(Entity entity, StatusEffectProperties prop)
     : base(entity, prop)
 {
 }
Пример #22
0
 public Recover(Entity entity, StatusEffectProperties prop) : base(entity, prop)
 {
 }
Пример #23
0
 public Slow(Entity entity, StatusEffectProperties prop)
     : base(entity, prop)
 {
 }
Пример #24
0
 public Weakness(Entity entity, StatusEffectProperties prop) : base(entity, prop)
 {
 }