• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# PlantType类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: Cypress

 static Cypress()
 {
     _id = ItemID.Cypress;
     _name = "檜木";
     _description = "";
     _type = PlantType.Wood;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:Cypress.cs


示例2: RawRubber

 static RawRubber()
 {
     _id = ItemID.Rubber;
     _name = "生橡膠";
     _description = "";
     _type = PlantType.Product;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:RawRubber.cs


示例3: Oak

 static Oak()
 {
     _id = ItemID.Oak;
     _name = "橡木";
     _description = "";
     _type = PlantType.Wood;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:Oak.cs


示例4: Hemp

 static Hemp()
 {
     _id = ItemID.Hemp;
     _name = "麻草";
     _description = "";
     _type = PlantType.Herb;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:Hemp.cs


示例5: Bamboo

 static Bamboo()
 {
     _id = ItemID.Bamboo;
     _name = "竹子";
     _description = "";
     _type = PlantType.Wood;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:Bamboo.cs


示例6: Coconut

 static Coconut()
 {
     _id = ItemID.Coconut;
     _name = "椰子";
     _description = "";
     _type = PlantType.Product;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:Coconut.cs


示例7: Log

 static Log()
 {
     _id = ItemID.Log;
     _name = "木頭";
     _description = "";
     _type = PlantType.Wood;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:Log.cs


示例8: Cotton

 static Cotton()
 {
     _id = ItemID.Cotton;
     _name = "棉花";
     _description = "";
     _type = PlantType.Product;
 }
开发者ID:DSobscure,项目名称:Resource-Emperor,代码行数:7,代码来源:Cotton.cs


示例9: Plant

        public Plant(PlantType type, decimal age, decimal size)
        {
            Type = type;
            Size = size;
            Age = age;

            Construct ();
        }
开发者ID:CompulsiveCoder,项目名称:TileSim,代码行数:8,代码来源:Plant.cs


示例10: GetInfo

		public static PlantTypeInfo GetInfo( PlantType plantType )
		{
			int index = (int)plantType;

			if ( index >= 0 && index < m_Table.Length )
				return m_Table[index];
			else
				return m_Table[0];
		}
开发者ID:Godkong,项目名称:RunUO,代码行数:9,代码来源:PlantType.cs


示例11: Seed

		public Seed( PlantType plantType, PlantHue plantHue, bool showType ) : base( 0xDCF )
		{
			Weight = 1.0;

			m_PlantType = plantType;
			m_PlantHue = plantHue;
			m_ShowType = showType;

			Hue = PlantHueInfo.GetInfo( plantHue ).Hue;
		}
开发者ID:jsrn,项目名称:MidnightWatchServer,代码行数:10,代码来源:Seed.cs


示例12: PlantTypeInfo

 private PlantTypeInfo( int itemID, int offsetX, int offsetY, PlantType plantType, bool containsPlant, bool flowery, bool crossable )
 {
     m_ItemID = itemID;
     m_OffsetX = offsetX;
     m_OffsetY = offsetY;
     m_PlantType = plantType;
     m_ContainsPlant = containsPlant;
     m_Flowery = flowery;
     m_Crossable = crossable;
 }
开发者ID:justdanofficial,项目名称:khaeros,代码行数:10,代码来源:PlantType.cs


示例13: GetInfo

		public static PlantResourceInfo GetInfo( PlantType plantType, PlantHue plantHue )
		{
			foreach ( PlantResourceInfo info in m_ResourceList )
			{
				if ( info.PlantType == plantType && info.PlantHue == plantHue )
					return info;
			}

			return null;
		}
开发者ID:greeduomacro,项目名称:last-wish,代码行数:10,代码来源:PlantResources.cs


示例14: Seed

        public Seed(PlantType plantType, PlantHue plantHue, bool showType)
            : base(0xDCF)
        {
            this.Weight = 1.0;
            this.Stackable = Core.SA;

            this.m_PlantType = plantType;
            this.m_PlantHue = plantHue;
            this.m_ShowType = showType;

            this.Hue = PlantHueInfo.GetInfo(plantHue).Hue;
        }
开发者ID:Ziden,项目名称:ServUO-EC-Test-Fork,代码行数:12,代码来源:Seed.cs


示例15: Deserialize

        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();

            switch ( version )
            {
                case 1:
                    {
                        this.m_Level = (SecureLevel)reader.ReadInt();
                        goto case 0;
                    }
                case 0:
                    {
                        if (version < 1)
                            this.m_Level = SecureLevel.CoOwners;

                        this.m_PlantStatus = (PlantStatus)reader.ReadInt();
                        this.m_PlantType = (PlantType)reader.ReadInt();
                        this.m_PlantHue = (PlantHue)reader.ReadInt();
                        this.m_ShowType = reader.ReadBool();

                        if (this.m_PlantStatus < PlantStatus.DecorativePlant)
                            this.m_PlantSystem = new PlantSystem(this, reader);

                        break;
                    }
            }

            m_Instances.Add(this);
        }
开发者ID:Ziden,项目名称:ServUO-EC-Test-Fork,代码行数:32,代码来源:PlantItem.cs


示例16: GetBonsaiTitle

		public static int GetBonsaiTitle( PlantType plantType )
		{
			switch ( plantType )
			{
				case PlantType.Cactus:
				case PlantType.FlaxFlowers:
				case PlantType.FoxgloveFlowers:
				case PlantType.HopsEast:
				case PlantType.OrfluerFlowers:
				case PlantType.CypressTwisted:
				case PlantType.HedgeShort:
				case PlantType.JuniperBush:
				case PlantType.SnowdropPatch:
				case PlantType.Cattails:
				case PlantType.PoppyPatch:
				case PlantType.SpiderTree:
				case PlantType.WaterLily:
				case PlantType.CypressStraight:
				case PlantType.HedgeTall:
				case PlantType.HopsSouth:
				case PlantType.SugarCanes:
					return 1080528; // peculiar

				case PlantType.CommonGreenBonsai:
				case PlantType.CommonPinkBonsai:
					return 1063335; // common

				case PlantType.UncommonGreenBonsai:
				case PlantType.UncommonPinkBonsai:
					return 1063336; // uncommon

				case PlantType.RareGreenBonsai:
				case PlantType.RarePinkBonsai:
					return 1063337; // rare

				case PlantType.ExceptionalBonsai:
					return 1063341; // exceptional

				case PlantType.ExoticBonsai:
					return 1063342; // exotic

				default:
					return 0;
			}
		}
开发者ID:greeduomacro,项目名称:UO-Forever,代码行数:45,代码来源:PlantType.cs


示例17: IsCrossable

		public static bool IsCrossable( PlantType plantType )
		{
			return GetInfo( plantType ).Crossable;
		}
开发者ID:greeduomacro,项目名称:UO-Forever,代码行数:4,代码来源:PlantType.cs


示例18: Cross

		public static PlantType Cross( PlantType first, PlantType second )
		{
			if ( !IsCrossable( first ) || !IsCrossable( second ) )
				return PlantType.CampionFlowers;

			int firstIndex = (int)first;
			int secondIndex = (int)second;

			if ( firstIndex + 1 == secondIndex || firstIndex == secondIndex + 1 )
				return Utility.RandomBool() ? first : second;
			else
				return (PlantType)( (firstIndex + secondIndex) / 2 );
		}
开发者ID:greeduomacro,项目名称:UO-Forever,代码行数:13,代码来源:PlantType.cs


示例19: switch

 protected override object this[string index]
 {
     get
     {
         #region
         switch (index)
         {
             case "UserID": return UserID;
             case "GeneralID": return GeneralID;
             case "PlantType": return PlantType;
             case "PlantQuality": return PlantQuality;
             case "RefreshNum": return RefreshNum;
             case "RefreshDate": return RefreshDate;
             default: throw new ArgumentException(string.Format("UserPlantQuality index[{0}] isn't exist.", index));
         }
         #endregion
     }
     set
     {
         #region
         switch (index)
         {
             case "UserID":
                 _UserID = value.ToNotNullString();
                 break;
             case "GeneralID":
                 _GeneralID = value.ToInt();
                 break;
             case "PlantType":
                 _PlantType = value.ToEnum<PlantType>();
                 break;
             case "PlantQuality":
                 _PlantQuality = value.ToEnum<PlantQualityType>();
                 break;
             case "RefreshNum":
                 _RefreshNum = value.ToInt();
                 break;
             case "RefreshDate":
                 _RefreshDate = value.ToDateTime();
                 break;
             default: throw new ArgumentException(string.Format("UserPlantQuality index[{0}] isn't exist.", index));
         }
         #endregion
     }
 }
开发者ID:rongxiong,项目名称:Scut,代码行数:45,代码来源:UserPlantQuality.cs


示例20: AppendPlantQuality

 private void AppendPlantQuality(PlantType pType, PlantQualityType plantQualityType)
 {
     UserPlantQuality plant = new UserPlantQuality()
                                  {
                                      UserID = ContextUser.UserID,
                                      GeneralID = generalID,
                                      PlantType = pType,
                                      PlantQuality = plantQualityType,
                                      RefreshNum = 1,
                                      RefreshDate = DateTime.Now
                                  };
     new GameDataCacheSet<UserPlantQuality>().Add(plant, GameEnvironment.CacheUserPeriod);
 }
开发者ID:rongxiong,项目名称:Scut,代码行数:13,代码来源:Action10005.cs



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Plasma类代码示例发布时间:2022-05-24
下一篇:
C# PlantHue类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap