Example #1
0
        public static void GiveArtifactTo( Mobile m )
        {
            double random = Utility.RandomDouble();

            Item item;

            if ( MempoChance > random )
                item = new LeurociansMempoOfFortune();
            else if ( PigmentsChance > random )
                item = new PigmentsOfTokunoMajor( MinorPigmentsType[Utility.Random( MinorPigmentsType.Length )], 1 );
            else
                item = (Item) Activator.CreateInstance( MinorArtifacts[Utility.Random( MinorArtifacts.Length )] );

            bool message = true;

            if ( !m.AddToBackpack( item ) )
            {
                Container bank = m.BankBox;

                if ( !( bank != null && bank.TryDropItem( m, item, false ) ) )
                {
                    m.SendLocalizedMessage( 1072523, "", 64 ); // You find an artifact, but your backpack and bank are too full to hold it.

                    message = false;

                    item.MoveToWorld( m.Location, m.Map );
                }
            }

            if ( message )
                m.SendLocalizedMessage( 1062317, "", 64 ); // For your valor in combating the fallen beast, a special artifact has been bestowed on you.

            Effects.SendLocationParticles( EffectItem.Create( m.Location, m.Map, EffectItem.DefaultDuration ), 0, 0, 0, 0, 0, 5060, 0 );
            Effects.PlaySound( m.Location, m.Map, 0x243 );

            Effects.SendMovingParticles( new DummyEntity( Serial.Zero, new Point3D( m.X - 6, m.Y - 6, m.Z + 15 ), m.Map ), m, 0x36D4, 7, 0, false, true, 0x497, 0, 9502, 1, 0, (EffectLayer) 255, 0x100 );
            Effects.SendMovingParticles( new DummyEntity( Serial.Zero, new Point3D( m.X - 4, m.Y - 6, m.Z + 15 ), m.Map ), m, 0x36D4, 7, 0, false, true, 0x497, 0, 9502, 1, 0, (EffectLayer) 255, 0x100 );
            Effects.SendMovingParticles( new DummyEntity( Serial.Zero, new Point3D( m.X - 6, m.Y - 4, m.Z + 15 ), m.Map ), m, 0x36D4, 7, 0, false, true, 0x497, 0, 9502, 1, 0, (EffectLayer) 255, 0x100 );

            Effects.SendTargetParticles( m, 0x375A, 35, 90, 0x00, 0x00, 9502, (EffectLayer) 255, 0x100 );

            PlayerMobile pm = m as PlayerMobile;

            pm.ToTTotalMonsterFame = 0;
        }
Example #2
0
 public DyeTarget(PigmentsOfTokunoMajor m_dye)
     : base(8, false, TargetFlags.None)
 {
     dye = m_dye;
 }
Example #3
0
        public override void OnResponse( GameClient sender, RelayInfo info )
        {
            Item reward = null;

            switch ( info.ButtonID )
            {
                case 100:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.ParagonGold, 50 );
                    break;
                case 101:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.VioletCouragePurple, 50 );
                    break;
                case 102:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.InvulnerabilityBlue, 50 );
                    break;
                case 103:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.LunaWhite, 50 );
                    break;
                case 104:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.DryadGreen, 50 );
                    break;
                case 105:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.ShadowDancerBlack, 50 );
                    break;
                case 106:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.BerserkerRed, 50 );
                    break;
                case 107:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.NoxGreen, 50 );
                    break;
                case 108:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.RumRed, 50 );
                    break;
                case 109:
                    reward = new PigmentsOfTokunoMajor( PigmentsType.FireOrange, 50 );
                    break;
            }

            if ( reward != null )
            {
                minister.Say( 1070984, String.Format( "#{0}", reward.LabelNumber ) ); // You have earned the gratitude of the Empire. I have placed the ~1_OBJTYPE~ in your backpack.

                from.AddToBackpack( reward );

                ( (PlayerMobile) from ).ToTItemsTurnedIn = 0;
            }
            else
            {
                minister.Say( 1070982 ); // When you wish to choose your reward, you have but to approach me again.
            }
        }
 public DyeTarget( PigmentsOfTokunoMajor m_dye )
     : base(8, false, TargetFlags.None)
 {
     dye = m_dye;
 }