Exemplo n.º 1
0
        public static Item Imbue(Item item, Ethic ethic, bool expire, int hue)
        {
            if ((item is IEthicsItem))
            {
                EthicsItem state = Find(item);

                if (state == null)
                {
                    state = new EthicsItem(item, ethic);
                    state.Attach();
                }

                if (expire)
                {
                    state.StartExpiration();
                }

                state.m_OrigHue      = item.Hue;
                state.m_OrigLootType = item.LootType;
                item.Hue             = hue;
                item.LootType        = LootType.Blessed;
            }

            return(item);
        }
Exemplo n.º 2
0
        public static Item Imbue(Item item, Ethic ethic, int hue)
        {
            if ((item is IEthicsItem))
            {
                EthicsItem state = Find(item);

                if (state == null)
                {
                    state = new EthicsItem(item, ethic);
                    state.Attach();
                }

                state.m_OrigHue = item.Hue;
                item.Hue        = hue;
            }

            return(item);
        }
Exemplo n.º 3
0
		public static Item Imbue( Item item, Ethic ethic, int hue )
		{
			if ( (item is IEthicsItem) )
			{
				EthicsItem state = Find( item );

				if ( state == null )
				{
					state = new EthicsItem( item, ethic );
					state.Attach();
				}

				state.m_OrigHue = item.Hue;
				item.Hue = hue;
			}

			return item;
		}