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


C# muhSkills类代码示例

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


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

示例1: AccurateShotsActivate

 public void AccurateShotsActivate()
 {
     // i didn't add a !busy here because the button will go away if you do something else anyway
     if (GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex].GetEnergy()>= Skill.FromListOfSkills(muhSkills.AccurateShots).EnergyCost)
         SwitchThis = muhSkills.AccurateShots;
     else Debug.Log("NO ENERGY");
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:7,代码来源:SkillMethods.cs

示例2: AdvanceTime2

 public void AdvanceTime2()
 {
     if (GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex].GetEnergy()>= Skill.FromListOfSkills(muhSkills.AdvanceTime).EnergyCost)
     {
         GameManager.instance.CurrentTime +=4;
         TroopScript Caster = GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex];
         muhSkills thisSkill = muhSkills.AdvanceTime2;
         Caster.SkillRecoveryTime = Skill.FromListOfSkills(thisSkill).SkillRecoveryTime;
         GameManager.instance.removeTileHighlights();
         Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
         Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
         if (Skill.FromListOfSkills(thisSkill).DepleteEnergy == true)
             Caster.SetEnergy(0);
         Caster.actionPoints--;
         SwitchThis = muhSkills.NoSkill;}
     else Debug.Log("NO ENERGY");
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:17,代码来源:SkillMethods.cs

示例3: SweepingFireActivate

 public void SweepingFireActivate()
 {
     if (GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex].GetEnergy()>= Skill.FromListOfSkills(muhSkills.SweepingFire).EnergyCost)
         SwitchThis = muhSkills.SweepingFire;
     else Debug.Log("NOT ENOUGHTTTTTT ENERGY");
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:6,代码来源:SkillMethods.cs

示例4: FollowThroughActivate

 public void FollowThroughActivate()
 {
     if (GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex].GetEnergy()>= Skill.FromListOfSkills(muhSkills.FollowThrough).EnergyCost)
         SwitchThis = muhSkills.FollowThrough;
     else Debug.Log("NOT ENOUGHTTTTTT ENERGY");
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:6,代码来源:SkillMethods.cs

示例5: SummonTrashEffect

 public void SummonTrashEffect(TroopScript Caster,Tile TargetTile)
 {
     muhSkills thisSkill = muhSkills.SummonTrash;
     TroopScript Target = null;
     for (int i = 0;i<GameManager.instance.players.Count;i++)
     if (GameManager.instance.players[i].gridPosition == TargetTile.gridPosition){
         Target = GameManager.instance.players[i];
         NewFightScript.SummonYogurtOntoPlayer(Target,Caster);
     }
     if (Target == null)
         GameManager.instance.SummonYogurt (TargetTile.gridPosition,Caster);
     Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
     if (Skill.FromListOfSkills(thisSkill).DepleteEnergy == true)
         Caster.SetEnergy(0);
     SwitchThis = muhSkills.NoSkill;
     Caster.SkillRecoveryTime = Skill.FromListOfSkills(thisSkill).SkillRecoveryTime;
     Caster.actionPoints--;
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:18,代码来源:SkillMethods.cs

示例6: RemoveSkillToList

 public void RemoveSkillToList(muhSkills _skill)
 {
     SkillsPossessed.Remove(_skill);
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:4,代码来源:TroopScript.cs

示例7: UpgradeSkill

    void UpgradeSkill(muhSkills SkillYouWant)
    {
        bool FoundIt = false;
        if (Skill.FromListOfSkills(SkillYouWant).PrerequisiteSkill != muhSkills.NoSkill){
        muhSkills Prerequisite = (Skill.FromListOfSkills(SkillYouWant).PrerequisiteSkill);

        for (int i = 0;i<SkillsPossessed.Count;i++){
            if (SkillsPossessed[i]==Prerequisite){
                SkillsPossessed.Remove(SkillsPossessed[i]);
                SkillsPossessed.Add(SkillYouWant);
                FoundIt = true;
                break;
            }
        }
         if (!FoundIt)
        Debug.Log("YOU ARE MISSING THE PRE-REQUISITE SKILL: "+Prerequisite);

        }
        else if (Skill.FromListOfSkills(SkillYouWant).PrerequisiteSkill == muhSkills.NoSkill)
            SkillsPossessed.Add(SkillYouWant);
    }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:21,代码来源:TroopScript.cs

示例8: AccurateShots

    void AccurateShots()
    {
        muhSkills thisSkill = muhSkills.AccurateShots;

        TroopScript Caster = GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex];
        Vector2 Origin = Caster.gridPosition;
        List<TroopScript> Targets = new List<TroopScript>();

        if (AccurateShotsArea > -1f && AccurateShotsArea < 5.1f)
            AccurateShotsArea +=Input.GetAxis("Mouse ScrollWheel");
        else if (AccurateShotsArea < 0)
            AccurateShotsArea =0;
        else if (AccurateShotsArea > 5)
            AccurateShotsArea = 5;

        int	mArea = Mathf.RoundToInt(AccurateShotsArea);
        if (mArea < 1)
            mArea = 0;
        else if (mArea > 3)
            mArea = 4;
        Caster.attacking = true;
        List<Tile>Targetcells = GameManager.instance.AccurateShotsHighlights(Origin,GameManager.instance.MousePosition,mArea,Skill.FromListOfSkills(thisSkill).SkillMinRange,Skill.FromListOfSkills(SwitchThis).SkillMaxRange);
            int cells = Targetcells.Count;
            for (int i = 0; i<cells;i++){
                for (int j = 0; j<GameManager.instance.players.Count;j++){
                    //if (Targetcells[i].gridPosition == GameManager.instance.players[j].gridPosition && GameManager.instance.players[j].Faction !=GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex].Faction)
                    if (Targetcells[i].gridPosition == GameManager.instance.players[j].gridPosition)

                        if (!Targets.Contains(GameManager.instance.players[j])){
                            Targets.Add(GameManager.instance.players[j]);
                //	Debug.Log ("added "+GameManager.instance.players[j].GetChief().GetName()+" to the list of targets");
                }
                //Debug.Log("count zz:"+Targets.Count);
            }}
        if (Input.GetMouseButtonDown(0))

                if (Targets.Count > 0){
                //Debug.Log("count:"+Targets.Count);
                for (int k = 0;k<Targets.Count;k++){

                    float TotalDamage = (float)5/cells;
                    Skill damageados = Skill.FromListOfSkills(muhSkills.AccurateShots);
                    damageados.DamageScaling = TotalDamage;
                    NewFightScript.MeleeFightingScript(Caster,Targets[k],damageados);
                    //Targets[i].SetNumber(Targets[i].GetNumber()-kills);
                    //if (Targets[i].GetNumber()<0) Targets[i].SetNumber(0);
                //	Debug.Log(Targets[k].GetChief().GetName());
                //	Debug.Log("value of k: "+k);

                    if (Targets[k].GetEnergy()>0)Targets[k].SetEnergy(Targets[k].GetEnergy()-1);
                }
                SwitchThis = muhSkills.NoSkill;

            //animations and shit go here
            Caster.actionPoints--;
            GameManager.instance.removeTileHighlights();
            Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
            if (Skill.FromListOfSkills(thisSkill).DepleteEnergy == true)
                Caster.SetEnergy(0);
            Caster.SkillRecoveryTime = Skill.FromListOfSkills(thisSkill).SkillRecoveryTime;

        }
    }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:63,代码来源:SkillMethods.cs

示例9: AddSkillToList

 public void AddSkillToList(muhSkills _skill)
 {
     SkillsPossessed.Add(_skill);
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:4,代码来源:TroopScript.cs

示例10: TenshiDivineTrash2

    public void TenshiDivineTrash2()
    {
        muhSkills thisSkill = muhSkills.TenshiDivineTrash2;
        TroopScript Caster = GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex];
        if (Caster.GetEnergy()>= Skill.FromListOfSkills(thisSkill).EnergyCost)
        {

            NewFightScript.HealingTarget(Caster,Caster,Skill.FromListOfSkills(thisSkill).HealScaling);
            GameManager.instance.removeTileHighlights();
            Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
            if (Skill.FromListOfSkills(thisSkill).DepleteEnergy == true)
                Caster.SetEnergy(0);
            SwitchThis = muhSkills.NoSkill;
            Caster.SkillRecoveryTime = Skill.FromListOfSkills(thisSkill).SkillRecoveryTime;
            Caster.actionPoints--;}
        else Debug.Log("NOT ENOUGHTTTTTT ENERGY");
    }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:17,代码来源:SkillMethods.cs

示例11: WhiteDestructionBeam

    public void WhiteDestructionBeam()
    {
        muhSkills thisSkill = muhSkills.WhiteDestructionBeam;
        TroopScript Caster = GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex];
        List <Tile> TilesHit = GameManager.instance.WhiteDestructionBeam(Caster);
        List <TroopScript> Targets;

        if (Input.GetMouseButtonDown(0)){
            for (int i = 0;i<TilesHit.Count;i++){
            foreach (TroopScript p in  GameManager.instance.players) {
                if (p.gridPosition == TilesHit[i].gridPosition && p.Faction != Caster.Faction) {

                    NewFightScript.MeleeFightingScript(Caster,p,Skill.FromListOfSkills(thisSkill));
                        //animations and shit go here}
                    GameManager.instance.removeTileHighlights();
                    Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
                    if (Skill.FromListOfSkills(thisSkill).DepleteEnergy == true)
                        Caster.SetEnergy(0);
                    SwitchThis = muhSkills.NoSkill;
                    Caster.SkillRecoveryTime = Skill.FromListOfSkills(thisSkill).SkillRecoveryTime;
                    Caster.actionPoints--;
                    }}}
        }
    }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:24,代码来源:SkillMethods.cs

示例12: MagicGuardAroundActivate

 public void MagicGuardAroundActivate()
 {
     if (GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex].GetEnergy()>= Skill.FromListOfSkills(muhSkills.MagicGuard).EnergyCost)
         SwitchThis = muhSkills.MagicGuard;
     else Debug.Log("NOT ENOUGHTTTTTT ENERGY");
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:6,代码来源:SkillMethods.cs

示例13: Meditate2

 public void Meditate2()
 {
     muhSkills thisSkill = muhSkills.Meditate2;
     TroopScript Caster = GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex];
     Caster.SetEnergy(Caster.GetEnergy()+2);
     if (Caster.GetEnergy()>Caster.GetMaxEnergy())
         Caster.SetEnergy(Caster.GetMaxEnergy());
     Caster.SkillRecoveryTime = Skill.FromListOfSkills(thisSkill).SkillRecoveryTime;
     Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
     if (Skill.FromListOfSkills(thisSkill).DepleteEnergy == true)
         Caster.SetEnergy(0);
     SwitchThis = muhSkills.NoSkill;
     Caster.actionPoints--;
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:14,代码来源:SkillMethods.cs

示例14: HealingMist

    public void HealingMist()
    {
        TroopScript Caster = GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex];
        muhSkills thisSkill = muhSkills.HealingMist;

                foreach (TroopScript p in  GameManager.instance.players) {
                    if ( p.Faction == Caster.Faction) {

                NewFightScript.HealingTarget(Caster,p,Skill.FromListOfSkills(muhSkills.HealingMist).HealScaling);
                        //animations and shit go here
            }
                        Caster.SetEnergy(Caster.GetEnergy()-Skill.FromListOfSkills(thisSkill).EnergyCost);
                        if (Skill.FromListOfSkills(muhSkills.HalveEnergy).DepleteEnergy == true)
                            Caster.SetEnergy(0);
                        SwitchThis = muhSkills.NoSkill;
            Caster.SkillRecoveryTime = Skill.FromListOfSkills(thisSkill).SkillRecoveryTime;
            Caster.actionPoints--;
            }
    }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:19,代码来源:SkillMethods.cs

示例15: HalveEnergyActivate

 public void HalveEnergyActivate()
 {
     if (GameManager.instance.playerTurns[GameManager.instance.PlayerTurnIndex].GetEnergy()>= Skill.FromListOfSkills(muhSkills.HalveEnergy).EnergyCost)
         SwitchThis = muhSkills.GuardCancel;
     else Debug.Log("NOT ENOUGHTTTTTT ENERGY");
 }
开发者ID:LudoRathowm,项目名称:trashyzong,代码行数:6,代码来源:SkillMethods.cs


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