Inheritance: MonoBehaviour
示例#1
0
    public Fireball(float castTime, float cooldownTime, float manaCost, SpellAnimation spellAnimation, float animationSpeedOffset) : base(castTime, cooldownTime, manaCost, spellAnimation, animationSpeedOffset)
    {
        // Add variables for AoE, cast SFX, projectile SFX, Blast SFX

        projectile       = Resources.Load("Prefabs/Spells/FireballProjectile") as GameObject;
        castingParticles = Resources.Load("Prefabs/Spells/CastingParticles/FireCastingParticles") as GameObject;
    }
示例#2
0
    public Blink(float castTime, float cooldownTime, float manaCost, SpellAnimation spellAnimation, float animationSpeedOffset, float distance) : base(castTime, cooldownTime, manaCost, spellAnimation, animationSpeedOffset)
    {
        this.distance = distance;

        castingParticles = Resources.Load("Prefabs/Spells/CastingParticles/ArcaneCastingParticles") as GameObject;
        blinkParticles   = Resources.Load("Prefabs/Spells/BlinkParticles") as GameObject;
    }
示例#3
0
 public Spell(float castTime, float cooldownTime, float manaCost, SpellAnimation spellAnimation, float animationSpeedOffset)
 {
     this.castTime             = castTime;
     this.cooldownTime         = cooldownTime;
     this.manaCost             = manaCost;
     this.spellAnimation       = spellAnimation;
     this.animationSpeedOffset = animationSpeedOffset;
 }
示例#4
0
        /// <summary>
        /// Spawn an attack spell into the world.
        /// </summary>
        public void SpawnAttackSpell()
        {
            GameObject spell = Instantiate((GameObject)Resources.Load("Prefabs/Battle/Spells/sword_attack_0"), target.transform.position, Quaternion.identity);

            this.spellAnimation = spell.GetComponent <AttackMeleeAnimation>();
            this.spellAnimation.abilitySelection = this.abilitySelection;
            this.spellAnimation.source           = this.combatant;
            this.spellAnimation.target           = this.target;
        }
示例#5
0
 /// <summary>
 /// Spawn an attack spell into the world.
 /// </summary>
 public void SpawnAttackSpell()
 {
     foreach (Combatant target in targets)
     {
         GameObject spell = Instantiate((GameObject)Resources.Load(string.Format("Prefabs/Battle/Spells/{0}", this.abilitySelection.ability.Model.Metadata.SpellAnimation)), target.transform.position, Quaternion.identity);
         this.spellAnimation = spell.GetComponent <SpellAnimation>();
         this.spellAnimation.abilitySelection = this.abilitySelection;
         this.spellAnimation.source           = this.combatant;
         this.spellAnimation.target           = target;
     }
 }
示例#6
0
        public override void Core_Update()
        {
            try
            {
                Pointer address = Core.ReadPointer(Core.GetPointer("Spell Animation Array") + 4 * EntryArrayBox.Value);

                CurrentAnim = new SpellAnimation(address);
            }
            catch (Exception ex)
            {
                Program.ShowError("There has been an error while trying to load this spell animation.", ex);
            }
            Core_LoadAnimCode();
            Core_LoadValues();
            Core_FindAndDisplayGraphics();
        }
示例#7
0
        public void NotifySpellAnimation(IAttackableUnit u, string animation)
        {
            var sa = new SpellAnimation(u, animation);

            _packetHandlerManager.BroadcastPacketVision(u, sa, Channel.CHL_S2C);
        }
示例#8
0
 public ForceShield(float castTime, float cooldownTime, float manaCost, SpellAnimation spellAnimation, float animationSpeedOffset, float bonusShield) : base(castTime, cooldownTime, manaCost, spellAnimation, animationSpeedOffset)
 {
     castingParticles = Resources.Load("Prefabs/Spells/CastingParticles/ArcaneCastingParticles") as GameObject;
 }
示例#9
0
 public LunarBeam(float castTime, float cooldownTime, float manaCost, SpellAnimation spellAnimation, float animationSpeedOffset, float damage) : base(castTime, cooldownTime, manaCost, spellAnimation, animationSpeedOffset)
 {
     this.damage      = damage;
     beam             = Resources.Load("Prefabs/Spells/LunarBeam") as GameObject;
     castingParticles = Resources.Load("Prefabs/Spells/CastingParticles/ArcaneCastingParticles") as GameObject;
 }
示例#10
0
        public void notifySpellAnimation(Unit u, string animation)
        {
            var sa = new SpellAnimation(u, animation);

            _game.PacketHandlerManager.broadcastPacketVision(u, sa, Channel.CHL_S2C);
        }
示例#11
0
 public Rejuvenation(float castTime, float cooldownTime, float manaCost, SpellAnimation spellAnimation, float animationSpeedOffset) : base(castTime, cooldownTime, manaCost, spellAnimation, animationSpeedOffset)
 {
     castingParticles = Resources.Load("Prefabs/Spells/CastingParticles/NatureCastingParticles") as GameObject;
     rejuvParticles   = Resources.Load("Prefabs/Spells/RejuvenationParticles") as GameObject;
 }