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


C# Critter.IncreaseLocalEventSurvival方法代码示例

本文整理汇总了C#中Critter.IncreaseLocalEventSurvival方法的典型用法代码示例。如果您正苦于以下问题:C# Critter.IncreaseLocalEventSurvival方法的具体用法?C# Critter.IncreaseLocalEventSurvival怎么用?C# Critter.IncreaseLocalEventSurvival使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Critter的用法示例。


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

示例1: RefundStats


//.........这里部分代码省略.........
        {
            if (item == StatEffect.Offense) { critter.IncreaseOffense(); }
            if (item == StatEffect.Defense) { critter.IncreaseDefense(); }
            if (item == StatEffect.Speed) { critter.IncreaseSpeed(); }
            if (item == StatEffect.Sense) { critter.IncreaseSense(); }
            if (item == StatEffect.Sneak) { critter.IncreaseSneak(); }
            if (item == StatEffect.Size) { critter.IncreaseSize(); }
            if (item == StatEffect.BreedRate) { critter.IncreaseBreedRate(); }
            if (item == StatEffect.Metabolism) { critter.IncreaseMetabolism(); }
            if (item == StatEffect.Slot) {  }
            if (item == StatEffect.EVO) { critter.IncreaseEvoMod(); }
            if (item == StatEffect.MIGRATE) { critter.IncreaseMigrateMod(); }
            if (item == StatEffect.EFFICIENCY) { critter.IncreaseEfficiency(); }
        }

        foreach (BiomeAdaptition item in BiomeBoons)
        {
            if (item == BiomeAdaptition.ARCTIC) { critter.DecreaseBiomePref(BiomeAdaptition.ARCTIC); }
            if (item == BiomeAdaptition.ARID) { critter.DecreaseBiomePref(BiomeAdaptition.ARID); }
            if (item == BiomeAdaptition.FRESHWATER) { critter.DecreaseBiomePref(BiomeAdaptition.FRESHWATER); }
            if (item == BiomeAdaptition.PLAINS) { critter.DecreaseBiomePref(BiomeAdaptition.PLAINS); }
            if (item == BiomeAdaptition.SALTWATER) { critter.DecreaseBiomePref(BiomeAdaptition.SALTWATER); }
            if (item == BiomeAdaptition.WOODLAND) { critter.DecreaseBiomePref(BiomeAdaptition.WOODLAND); }
        }

        foreach (BiomeAdaptition item in BiomeBanes)
        {
            if (item == BiomeAdaptition.ARCTIC) { critter.IncreaseBiomePref(BiomeAdaptition.ARCTIC); }
            if (item == BiomeAdaptition.ARID) { critter.IncreaseBiomePref(BiomeAdaptition.ARID); }
            if (item == BiomeAdaptition.FRESHWATER) { critter.IncreaseBiomePref(BiomeAdaptition.FRESHWATER); }
            if (item == BiomeAdaptition.PLAINS) { critter.IncreaseBiomePref(BiomeAdaptition.PLAINS); }
            if (item == BiomeAdaptition.SALTWATER) { critter.IncreaseBiomePref(BiomeAdaptition.SALTWATER); }
            if (item == BiomeAdaptition.WOODLAND) { critter.IncreaseBiomePref(BiomeAdaptition.WOODLAND); }
        }

        foreach (statSliderChange item in ClimateBoons)
        {
            if (item == statSliderChange.FOCUS) { critter.DecreaseClimateFocus(); }
            if (item == statSliderChange.RANGE) { critter.DecreaseClimateRange(); }
            if (item == statSliderChange.PREF) { critter.DecreaseClimatePref(); }
        }

        foreach (statSliderChange item in ClimateBanes)
        {
            if (item == statSliderChange.FOCUS) { critter.IncreaseClimateFocus(); }
            if (item == statSliderChange.RANGE) { critter.IncreaseClimateRange(); }
            if (item == statSliderChange.PREF) { critter.IncreaseClimatePref(); }
        }

        foreach (GeoAdaptation item in GeoBoons)
        {
            if(item == GeoAdaptation.SaltWater) { critter.DecreaseGeoPref(GeoAdaptation.SaltWater); }
            if(item == GeoAdaptation.Islands) { critter.DecreaseGeoPref(GeoAdaptation.Islands); }
            if(item == GeoAdaptation.Flat) { critter.DecreaseGeoPref(GeoAdaptation.Flat); }
            if(item == GeoAdaptation.Hills) { critter.DecreaseGeoPref(GeoAdaptation.Hills); }
            if(item == GeoAdaptation.Mountains) { critter.DecreaseGeoPref(GeoAdaptation.Mountains); }
        }

        foreach(GeoAdaptation item in GeoBanes)
        {
            if(item == GeoAdaptation.SaltWater) { critter.IncreaseGeoPref(GeoAdaptation.SaltWater); }
            if(item == GeoAdaptation.Islands) { critter.IncreaseGeoPref(GeoAdaptation.Islands); }
            if(item == GeoAdaptation.Flat) { critter.IncreaseGeoPref(GeoAdaptation.Flat); }
            if(item == GeoAdaptation.Hills) { critter.IncreaseGeoPref(GeoAdaptation.Hills); }
            if(item == GeoAdaptation.Mountains) { critter.IncreaseGeoPref(GeoAdaptation.Mountains); }
        }

        foreach (statSliderChange item in TempBoons)
        {
            if (item == statSliderChange.FOCUS) { critter.DecreaseTempFocus(); }
            if (item == statSliderChange.RANGE) { critter.DecreaseTempRange(); }
            if (item == statSliderChange.PREF) { critter.DecreaseTempPref(); }
        }

        foreach (statSliderChange item in TempBanes)
        {
            if (item == statSliderChange.FOCUS) { critter.IncreaseTempFocus(); }
            if (item == statSliderChange.RANGE) { critter.IncreaseTempRange(); }
            if (item == statSliderChange.PREF) { critter.IncreaseTempPref(); }
        }

        foreach (Multiplier item in multipliers)
        {
            critter.RemoveMultiplier(item);
        }

        foreach (LocalEventController.localEvent item in LocalEventBoons)
        {
            critter.DecreaseLocalEventSurvival((int)item);
        }

        foreach (LocalEventController.localEvent item in LocalEventBanes)
        {
            critter.IncreaseLocalEventSurvival((int)item);
        }

        foreach (restriction item in restrictions){
            critter.RemoveRestriction(item);
        }
    }
开发者ID:Paulgherve1,项目名称:Critters,代码行数:101,代码来源:Adaptation.cs


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