当前位置: 首页>>代码示例>>C#>>正文


C# Spell类代码示例

本文整理汇总了C#中Spell的典型用法代码示例。如果您正苦于以下问题:C# Spell类的具体用法?C# Spell怎么用?C# Spell使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


Spell类属于命名空间,在下文中一共展示了Spell类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: SpellShapeshiftFormSelector

 public SpellShapeshiftFormSelector(Spell spell, bool stance)
 {
     InitializeComponent();
     _spell = spell;
     _stance = stance;
     Load();
 }
开发者ID:shilvasa,项目名称:LegacyToolBox,代码行数:7,代码来源:SpellShapeshiftFormSelector.xaml.cs

示例2: Do

    public override void Do(Mage caster, Spell origin_spell)
    {
        SEDispelOldestSlot dispel = Instantiate(this);
        dispel.StartCoroutine(dispel.UpdateDispel(caster));

        base.Do(caster, origin_spell);
    }
开发者ID:RPITeamTree,项目名称:Spelleo_RGS2015,代码行数:7,代码来源:SEDispelOldestSlot.cs

示例3: Start

 public void Start()
 {
     player = GameMainReferences.Instance.PlayerCharacter;
     _spell = player.GetSpellAtIndex(_spellIndex);
     ChangeSpellIcon(_spell);
     player.OnSpellChanged += OnSpellChanged;
 }
开发者ID:Barabicus,项目名称:ATOMFIACHRA,代码行数:7,代码来源:SpellButton.cs

示例4: Input

 public Input(Obj_AI_Base _target, Spell s, Vector3 _from, Vector3 _rangeCheckFrom)
 {
     Target = _target;
     SpellDelay = s.Delay;
     SpellMissileSpeed = s.Speed;
     SpellWidth = s.Width;
     SpellRange = s.Range;
     SpellCollisionable = s.Collision;
     SpellSkillShotType = s.Type;
     Path = Target.GetWaypoints();
     if (Target is Obj_AI_Hero)
     {
         Obj_AI_Hero t = Target as Obj_AI_Hero;
         AvgReactionTime = t.AvgMovChangeTime();
         LastMovChangeTime = t.LastMovChangeTime();
         AvgPathLenght = t.AvgPathLenght();
     }
     else
     {
         AvgReactionTime = 0;
         LastMovChangeTime = 0;
         AvgPathLenght = 0;
     }
     From = _from;
     RangeCheckFrom = _rangeCheckFrom;
 }
开发者ID:MrWenzoxfs,项目名称:elobuddy,代码行数:26,代码来源:Prediction.cs

示例5: CureMezzSpellHandler

 // constructor
 public CureMezzSpellHandler(GameLiving caster, Spell spell, SpellLine line)
     : base(caster, spell, line)
 {
     // RR4: now it's a list
     m_spellTypesToRemove = new List<string>();
     m_spellTypesToRemove.Add("Mesmerize");
 }
开发者ID:uvbs,项目名称:Dawn-of-Light-core,代码行数:8,代码来源:Curemezz.cs

示例6: TriggerSpellRefresh

 /// <summary>
 /// Triggers a spell refresh event. The spell refresh indicates that the spells destroy timer has been refreshed. 
 /// Typically this will be an attached spell refreshing the timer.
 /// </summary>
 /// <param name="obj"></param>
 private void TriggerSpellRefresh(Spell obj)
 {
     if(OnSpellRefresh != null)
     {
         OnSpellRefresh();
     }
 }
开发者ID:Barabicus,项目名称:ATOMFIACHRA,代码行数:12,代码来源:EffectSetting.cs

示例7: SpellDamage

 public SpellDamage(Spell.SpellBase spell, float[] spellDamageValue, float[] spellDamageModifier, DamageType damageType)
 {
     Spell = spell;
     SpellDamageValue = spellDamageValue;
     SpellDamageModifier = spellDamageModifier;
     DamageType = damageType;
 }
开发者ID:WujuSan,项目名称:Elobuddy-1,代码行数:7,代码来源:SpellDamage.cs

示例8: MagicInfo

        public MagicInfo (BinaryReader reader, int version = int.MaxValue, int Customversion = int.MaxValue)
        {
            Name = reader.ReadString();
            Spell = (Spell)reader.ReadByte();
            BaseCost = reader.ReadByte();
            LevelCost = reader.ReadByte();
            Icon = reader.ReadByte();
            Level1 = reader.ReadByte();
            Level2 = reader.ReadByte();
            Level3 = reader.ReadByte();
            Need1 = reader.ReadUInt16();
            Need2 = reader.ReadUInt16();
            Need3 = reader.ReadUInt16();
            DelayBase = reader.ReadUInt32();
            DelayReduction = reader.ReadUInt32();
            PowerBase = reader.ReadUInt16();
            PowerBonus = reader.ReadUInt16();
            MPowerBase = reader.ReadUInt16();
            MPowerBonus = reader.ReadUInt16();

            if (version > 66)
                Range = reader.ReadByte();
            if (version > 70)
            {
                MultiplierBase = reader.ReadSingle();
                MultiplierBonus = reader.ReadSingle();
            }
        }
开发者ID:Pete107,项目名称:Mir2,代码行数:28,代码来源:MagicInfo.cs

示例9: SearingPetEffect

        private int currentTick = 0;		// Count ticks

        public SearingPetEffect(GamePlayer owner)
            : base(RealmAbilities.SearingPetAbility.DURATION)
        {
            EffectOwner = owner;

            // Build spell
            DBSpell tSpell = new DBSpell();
            tSpell.AllowAdd = false;
            tSpell.Description = "Damage the target.";
            tSpell.Name = "PBAoE damage";
            tSpell.Target = "Enemy";
            tSpell.Radius = 0;
            tSpell.Range = WorldMgr.VISIBILITY_DISTANCE;
            tSpell.CastTime = 0;
            tSpell.Duration = 0;
            tSpell.Frequency = 0;
            tSpell.Pulse = 0;
            tSpell.Uninterruptible = true;
            tSpell.Type = "DirectDamage";
            tSpell.Damage = spellDamage;
            tSpell.DamageType = (int)eDamageType.Heat;
            tSpell.Value = 0;
            tSpell.Icon = 476;			// not official effect
            tSpell.ClientEffect = 476;	// not official effect
            petSpell = new Spell(tSpell, 1);
            petSpellLine = new SpellLine("RAs", "RealmAbilitys", "RealmAbilitys", true);
        }
开发者ID:uvbs,项目名称:Dawn-of-Light-core,代码行数:29,代码来源:SearingPetEffect.cs

示例10: LoadOKTW

        public void LoadOKTW()
        {
            Q = new Spell(SpellSlot.Q);
            E = new Spell(SpellSlot.E);
            W = new Spell(SpellSlot.W);
            R = new Spell(SpellSlot.R);

            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWard", "Auto Ward").SetValue(true));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("autoBuy", "Auto buy blue trinket after lvl 6").SetValue(false));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWardBlue", "Auto Blue Trinket").SetValue(true));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWardCombo", "Only combo mode").SetValue(true));
            Config.SubMenu("AutoWard OKTW©").AddItem(new MenuItem("AutoWardPink", "Auto VisionWard, OracleLens").SetValue(true));

            foreach (var hero in ObjectManager.Get<Obj_AI_Hero>())
            {
                if (hero.IsEnemy)
                {
                    if (hero.ChampionName == "Rengar")
                        rengar = true;
                    if (hero.ChampionName == "Vayne")
                        Vayne = hero;
                }
            }
            
            Game.OnUpdate += Game_OnUpdate;
            Obj_AI_Base.OnProcessSpellCast += Obj_AI_Base_OnProcessSpellCast;
            GameObject.OnCreate +=GameObject_OnCreate;
            GameObject.OnDelete += GameObject_OnDelete;
        }
开发者ID:MrWenzoxfs,项目名称:elobuddy,代码行数:29,代码来源:OKTWward.cs

示例11: InitPositionInfo

        public static PositionInfo InitPositionInfo(Vector2 pos, float extraDelayBuffer, float extraEvadeDistance, Vector2 lastMovePos, Spell lowestEvadeTimeSpell) //clean this shit up
        {
            var extraDist = Evade.menu.SubMenu("MiscSettings").SubMenu("ExtraBuffers").Item("ExtraCPADistance").GetValue<Slider>().Value;

            var posInfo = canHeroWalkToPos(pos, myHero.MoveSpeed, extraDelayBuffer + Game.Ping, extraDist);
            posInfo.isDangerousPos = CheckDangerousPos(pos, 6);
            posInfo.hasExtraDistance = extraEvadeDistance > 0 ? CheckDangerousPos(pos, extraEvadeDistance) : false;// ? 1 : 0;            
            posInfo.closestDistance = posInfo.distanceToMouse;
            posInfo.intersectionTime = GetIntersectTime(lowestEvadeTimeSpell, myHero.ServerPosition.To2D(), pos);
            posInfo.distanceToMouse = pos.Distance(lastMovePos);
            posInfo.posDistToChamps = GetDistanceToChampions(pos);

            if (Evade.menu.SubMenu("MiscSettings").SubMenu("FastEvade").Item("RejectMinDistance").GetValue<Slider>().Value > 0
            && Evade.menu.SubMenu("MiscSettings").SubMenu("FastEvade").Item("RejectMinDistance").GetValue<Slider>().Value >
                posInfo.closestDistance) //reject closestdistance
            {
                posInfo.rejectPosition = true;
            }

            if (Evade.menu.SubMenu("MiscSettings").SubMenu("ExtraBuffers").Item("MinComfortZone").GetValue<Slider>().Value >
                posInfo.posDistToChamps)
            {
                posInfo.hasComfortZone = false;
            }

            return posInfo;
        }
开发者ID:qktlfflzk,项目名称:Backup5.4,代码行数:27,代码来源:EvadeHelper.cs

示例12: GetAttackRange

	public static TileGroup GetAttackRange(Unit caster, Spell spell)
	{
		List<Tile> AttackRange = new List<Tile>();
		AttackRange.Add(caster.CurrentTile);

		for (int ii = spell.MaxRange; ii > 0; ii--)
		{
			for (int jj = AttackRange.Count - 1; jj >= 0; jj--)
			{
				Tile rootTile = AttackRange[jj];
				foreach (Tile curTile in rootTile.NeighboringTiles.Tiles)
				{
					if (!AttackRange.Contains(curTile))
					{
						AttackRange.Add(curTile);
					}
				}
			}
		}

		for (int ii = AttackRange.Count - 1; ii >= 0; ii--)
		{
			if(Knowledge.NaiveDistance(caster.CurrentTile, AttackRange[ii]) < spell.MinRange)
			{
				AttackRange.RemoveAt(ii);
			}
		}

		return new TileGroup(AttackRange);
	}
开发者ID:WispyMouse,项目名称:Wispy-Tactics,代码行数:30,代码来源:Pathfinding.cs

示例13: SpellState

 public SpellState(Spell spellToTrack, byte priority)
 {
     TrackedSpell = spellToTrack;
     _Cooldown = 0M;
     _ActiveOnTarget = 0M;
     Priority = priority;
 }
开发者ID:LucasPeacecraft,项目名称:rawr,代码行数:7,代码来源:SpellState.cs

示例14: OnGameLoad

      private static void OnGameLoad(EventArgs args)
        {

            if (Player.ChampionName != "Riven") return;
            Game.PrintChat("Hoola Riven - Loaded Successfully, Good Luck! :):)");
            Q = new Spell(SpellSlot.Q);
            W = new Spell(SpellSlot.W);
            E = new Spell(SpellSlot.E, 300);
            R = new Spell(SpellSlot.R, 900);
            R.SetSkillshot(0.25f, 45, 1600, false, SkillshotType.SkillshotCone);

            OnMenuLoad();


            Timer = new Render.Text("Q Expiry =>  " + ((double)(LastQ - Utils.GameTimeTickCount + 3800) / 1000).ToString("0.0"), (int)Drawing.WorldToScreen(Player.Position).X - 140, (int)Drawing.WorldToScreen(Player.Position).Y + 10, 30, Color.MidnightBlue, "calibri");
            Timer2 = new Render.Text("R Expiry =>  " + (((double)LastR - Utils.GameTimeTickCount + 15000) / 1000).ToString("0.0"), (int)Drawing.WorldToScreen(Player.Position).X - 60, (int)Drawing.WorldToScreen(Player.Position).Y + 10, 30, Color.IndianRed, "calibri");

            Game.OnUpdate += OnTick;
            Drawing.OnDraw += Drawing_OnDraw;
            Drawing.OnEndScene += Drawing_OnEndScene;
            Obj_AI_Base.OnProcessSpellCast += OnCast;
            Obj_AI_Base.OnDoCast += OnDoCast;
            Obj_AI_Base.OnDoCast += OnDoCastLC;
            Obj_AI_Base.OnPlayAnimation += OnPlay;
            Obj_AI_Base.OnProcessSpellCast += OnCasting;
            Interrupter2.OnInterruptableTarget += Interrupt;
        }
开发者ID:AristoLOL,项目名称:EloBuddy-1,代码行数:27,代码来源:Program.cs

示例15: Apply

		protected override void Apply()
		{
			var channel = m_aura.Controller as SpellChannel;
			SpellCast origCast = null;
			if (spell == null)
			{
				if (channel != null)
				{
					origCast = channel.Cast;
				}
				else
				{
					origCast = m_aura.Auras.Owner.SpellCast;
				}

				spell = m_spellEffect.TriggerSpell;
				if (spell == null)
				{
					LogManager.GetCurrentClassLogger().Warn("Found invalid periodic TriggerSpell in Spell {0} ({1}) ",
						m_aura.Spell, 
						(uint)m_spellEffect.TriggerSpellId);
					return;
				}
			}

			SpellCast.ValidateAndTriggerNew(spell, m_aura.CasterReference, Owner, Owner, channel, origCast != null ? origCast.UsedItem : null,
				null, m_spellEffect);
		}
开发者ID:NVN,项目名称:WCell,代码行数:28,代码来源:PeriodicTriggerSpell.cs


注:本文中的Spell类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。