예제 #1
0
            protected override void OnTarget(Mobile from, object targeted)
            {
                if (m_Dust.Deleted || m_Dust.UsesRemaining <= 0)
                {
                    return;
                }

                if (!m_Dust.IsChildOf(from.Backpack))
                {
                    from.SendLocalizedMessage(1042664); // You must have the object in your backpack to use it.
                    return;
                }
                else if (targeted is PoppiesDust && m_Dust != targeted)
                {
                    PoppiesDust pd = targeted as PoppiesDust;
                    pd.UsesRemaining += m_Dust.UsesRemaining;
                    m_Dust.Delete();

                    from.SendLocalizedMessage(1158448); // You combine the charges on the items.
                }
                else if (targeted is Seed)
                {
                    Seed m_Seed = (Seed)targeted;

                    if (m_Seed.ShowType)
                    {
                        from.SendLocalizedMessage(1114369, "", 946); // This seed has already been identified.
                        return;
                    }

                    m_Seed.ShowType = true;

                    --m_Dust.UsesRemaining;
                }
            }
예제 #2
0
 public InternalTarget(PoppiesDust dust)
     : base(3, false, TargetFlags.None)
 {
     m_Dust = dust;
 }
예제 #3
0
 public InternalTarget( PoppiesDust dust )
     : base(3, false, TargetFlags.None)
 {
     m_Dust = dust;
 }