public SilverDonationBoxAoS() { Weight = 1.0; Hue = 2401; Item item = null; Name = "Defiance Gold Member Box of Holding"; CharacterCreation.PlaceItemIn(this, 16, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 28, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 40, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 16, 81, (item = new HoodedShroudOfShadows())); item.Hue = 2401; item.Name = "Silver Shroud of Shadows"; item.LootType = LootType.Blessed; BaseContainer cont; CharacterCreation.PlaceItemIn(this, 58, 57, (cont = new Backpack())); cont.Hue = 2401; cont.Name = "a silver bag"; CharacterCreation.PlaceItemIn(cont, 29, 39, new SulfurousAsh(5000)); CharacterCreation.PlaceItemIn(cont, 29, 64, new Nightshade(5000)); CharacterCreation.PlaceItemIn(cont, 29, 89, new SpidersSilk(5000)); CharacterCreation.PlaceItemIn(cont, 60, 64, new Garlic(5000)); CharacterCreation.PlaceItemIn(cont, 60, 89, new Ginseng(5000)); CharacterCreation.PlaceItemIn(cont, 88, 39, new Bloodmoss(5000)); CharacterCreation.PlaceItemIn(cont, 88, 64, new BlackPearl(5000)); CharacterCreation.PlaceItemIn(cont, 88, 89, new MandrakeRoot(5000)); CharacterCreation.PlaceItemIn(this, 103, 58, (item = new Sandals())); item.Hue = Utility.RandomList(5, 70, 90, 110); item.LootType = LootType.Blessed; CharacterCreation.PlaceItemIn(this, 122, 53, new SpecialDonateDye()); CharacterCreation.PlaceItemIn(this, 156, 55, (item = new EtherealHorse())); item.Hue = 2401; item.Name = "No Aged Ethereal"; ((EtherealMount)item).IsDonationItem = true; CharacterCreation.PlaceItemIn(this, 43, 83, (item = new ClothingBlessDeed())); item.Hue = 2401; CharacterCreation.PlaceItemIn(this, 63, 83, (item = new KillResetDeedAOS())); //by Blady item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 83, 83, (item = new SmallBrickHouseDeed())); item.Hue = 2401; CharacterCreation.PlaceItemIn(this, 103, 83, (item = new NameChangeDeed())); item.Hue = 2401; CharacterCreation.PlaceItemIn(this, 123, 83, (item = new AntiBlessDeed())); item.Hue = 2401; CharacterCreation.PlaceItemIn(this, 143, 83, (item = new MembershipTicket())); item.Hue = 2213; ((MembershipTicket)item).MemberShipTime = TimeSpan.MaxValue; }
public static Item CreateRandomSkillScroll() { Item skillscroll = null; int roll = Utility.Random(49); if (roll == 0) { skillscroll = new ClothingBlessDeed(); } else { skillscroll = new SkillScroll(); } return(skillscroll); }
public ClothingBlessTarget(ClothingBlessDeed deed) : base(1, false, TargetFlags.None) { m_Deed = deed; }
public NoxGreenDonationBoxAos() { Weight = 1.0; Hue = 1420; Item item = null; Name = "Defiance Nox Green Member Box of Holding"; CharacterCreation.PlaceItemIn(this, 16, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 28, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 40, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 16, 81, (item = new HoodedShroudOfShadows())); item.Hue = 1420; item.Name = "Nox Shroud of Shadows"; item.LootType = LootType.Blessed; BaseContainer cont; CharacterCreation.PlaceItemIn(this, 58, 57, (cont = new Backpack())); cont.Hue = 1420; cont.Name = "a donation backpack"; CharacterCreation.PlaceItemIn(cont, 44, 65, new SulfurousAsh(10000)); CharacterCreation.PlaceItemIn(cont, 77, 65, new Nightshade(10000)); CharacterCreation.PlaceItemIn(cont, 110, 65, new SpidersSilk(10000)); CharacterCreation.PlaceItemIn(cont, 143, 65, new Garlic(10000)); CharacterCreation.PlaceItemIn(cont, 44, 128, new Ginseng(10000)); CharacterCreation.PlaceItemIn(cont, 77, 128, new Bloodmoss(10000)); CharacterCreation.PlaceItemIn(cont, 110, 128, new BlackPearl(10000)); CharacterCreation.PlaceItemIn(cont, 143, 128, new MandrakeRoot(10000)); //CharacterCreation.PlaceItemIn(this, 74, 64, new DonationBandana()); //Replaced the bandana with a deed - Edit by Blady CharacterCreation.PlaceItemIn(this, 74, 64, (item = new DonationDeed())); item.Hue = 1420; CharacterCreation.PlaceItemIn(this, 103, 58, (item = new Sandals())); item.Hue = 1420; //Utility.RandomList(1420, 1281, 1161, 1420, 1420, 1420, 1266, 1420, 1420, 1645); item.LootType = LootType.Blessed; CharacterCreation.PlaceItemIn( this, 122, 53, new SpecialDonateDye() ); CharacterCreation.PlaceItemIn(this, 11420, 53, (item = new PigmentsOfTokuno( 5 ))); ((PigmentsOfTokuno)item).Type = PigmentType.NoxGreen; CharacterCreation.PlaceItemIn(this, 156, 55, (item = new EtherealHorse())); item.Hue = 1420; item.Name = "No Age Ethereal"; ((EtherealMount)item).IsDonationItem = true; CharacterCreation.PlaceItemIn(this, 34, 83, (item = new HolyDeedofBlessing())); item.Hue = 1420; CharacterCreation.PlaceItemIn(this, 43, 83, (item = new ClothingBlessDeed())); item.Hue = 1420; CharacterCreation.PlaceItemIn(this, 58, 83, (item = new TreasureMap(6, Map.Felucca))); item.Hue = 1420; CharacterCreation.PlaceItemIn(this, 73, 83, (item = new SmallBrickHouseDeed())); item.Hue = 1420; CharacterCreation.PlaceItemIn(this, 88, 83, (item = new NameChangeDeed())); item.Hue = 1420; CharacterCreation.PlaceItemIn(this, 103, 83, (item = new MiniHouseDeed())); item.Hue = 1420; //CharacterCreation.PlaceItemIn(this, 118, 83, (item = new BankCheck(100000))); //item.Hue = 1420; CharacterCreation.PlaceItemIn(this, 130, 83, (item = new MembershipTicket())); item.Hue = 1420; ((MembershipTicket)item).MemberShipTime = TimeSpan.MaxValue; }
public ClothingBlessTarget( ClothingBlessDeed deed ) : base( 1, false, TargetFlags.None ) { m_Deed = deed; }
public void GiveClothingBlessDeed() { if ( Map != Map.Felucca ) return; ArrayList toGive = new ArrayList(); ArrayList rights = BaseCreature.GetLootingRights( this.DamageEntries, this.HitsMax ); for ( int i = rights.Count - 1; i >= 0; --i ) { DamageStore ds = (DamageStore)rights[i]; if ( ds.m_HasRight ) toGive.Add( ds.m_Mobile ); } if ( toGive.Count == 0 ) return; // Randomize for ( int i = 0; i < toGive.Count; ++i ) { int rand = Utility.Random( toGive.Count ); object hold = toGive[i]; toGive[i] = toGive[rand]; toGive[rand] = hold; } for ( int i = 0; i < 6; ++i ) { Mobile m = (Mobile)toGive[i % toGive.Count]; ClothingBlessDeed cbd = new ClothingBlessDeed(); m.SendMessage( "You have received a Clothing Bless Deed!" ); // You have received a Clothing Bless Deed! m.AddToBackpack( cbd ); if ( m is PlayerMobile ) { PlayerMobile pm = (PlayerMobile)m; for ( int j = 0; j < pm.JusticeProtectors.Count; ++j ) { Mobile prot = (Mobile)pm.JusticeProtectors[j]; if ( prot.Map != m.Map || prot.Kills >= 5 || prot.Criminal || !JusticeVirtue.CheckMapRegion( m, prot ) ) continue; int chance = 0; switch ( VirtueHelper.GetLevel( prot, VirtueName.Justice ) ) { case VirtueLevel.Seeker: chance = 60; break; case VirtueLevel.Follower: chance = 80; break; case VirtueLevel.Knight: chance = 100; break; } if ( chance > Utility.Random( 100 ) ) { prot.SendLocalizedMessage( 1049368 ); // You have been rewarded for your dedication to Justice! prot.AddToBackpack( new ClothingBlessDeed() ); } } } } }
public void AddMonster( Type type, bool champ, int count ) { for( int i = 0; i < count; ++i ) { object monster = Activator.CreateInstance( type ); if( monster != null && monster is Mobile ) { Point3D location = FindSpawnLocation(); BaseCreature from = (BaseCreature)monster; from.MoveToWorld( location, this.Map ); from.Home = location; from.Tamable = false; if( m_Waypoint != null ) from.CurrentWayPoint = m_Waypoint; m_Spawned.Add( from ); if( m_RewardsEnabled ) { if( champ && m_ArtifactChance > Utility.Random( 100 ) ) { Item item = (Item)Activator.CreateInstance( Artifacts[Utility.Random( Artifacts.Length )] ); from.AddItem( item ); } if( champ && m_BlessDeedChance > Utility.Random( 100 ) ) { ClothingBlessDeed cbd = new ClothingBlessDeed(); cbd.LootType = LootType.Cursed; cbd.Name = "a cursed clothing bless deed"; cbd.Hue = 1157; from.AddItem( cbd ); } } } } }
public static Item CreateRandomSkillScroll() { Item skillscroll = null; int roll = Utility.Random(49); if (roll == 0) { skillscroll = new ClothingBlessDeed(); } else skillscroll = new SkillScroll(); return skillscroll; }
public override void OnDeath( Container c ) { base.OnDeath( c ); if ( 0.75 > Utility.RandomDouble() ) { int r = Utility.Random( 100 ); Item drop = null; if ( r < 1 ) drop = new LayerSashDeed(); else if ( r < 4 ) drop = new SpecialQuestSandals(); else if ( r < 6 ) drop = new RareCreamCarpet( PieceType.Centre ); else if ( r < 8 ) drop = new RareBlueCarpet( PieceType.Centre ); else if ( r < 10 ) drop = new RareBloodCarpet( PieceType.Centre ); else if ( r < 12 ) drop = new BasicBlueCarpet( PieceType.Centre ); else if ( r < 14 ) drop = new BasicPinkCarpet( PieceType.Centre ); else if ( r < 29 ) drop = new BloodPentagramPart( Utility.Random( 5 ) ); else if ( r < 30 ) drop = new ClothingBlessDeed(); else if ( r < 35 ) drop = new MysteriousCloth(); else if ( r < 40 ) drop = new SpecialHairDye(); else if ( r < 45 ) drop = new SpecialBeardDye(); else if ( r < 50 ) drop = new NameChangeDeed(); else if ( r < 65 ) drop = new SkillTunic(); else if ( r < 80 ) drop = new TamersCrook(); else if ( r < 85 ) drop = new HeroShield(); else if ( r < 88 ) drop = new EvilShield(); else if ( r < 91 ) drop = new MondainHat(); else if ( r < 94 ) drop = new PlatinGloves(); else if ( r < 96 ) drop = new AncientSamuraiHelm(); else if ( r < 98 ) drop = Utility.RandomBool() ? (Item)(new MirrorEast()) : (Item)(new MirrorNorth()); else drop = Utility.RandomBool() ? (Item)(new BoneBenchEastPart()) : (Item)(new BoneBenchWestPart()); c.DropItem( drop ); } }
public GoldenDonationBoxAoS() { Weight = 1.0; Hue = 2213; Item item = null; Name = "Defiance Gold Member Box of Holding"; CharacterCreation.PlaceItemIn(this, 16, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 28, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 40, 60, (item = new DonationSkillBall( 25, false ))); CharacterCreation.PlaceItemIn(this, 16, 81, (item = new HoodedShroudOfShadows())); item.Hue = 2213; item.Name = "Golden Shroud of Shadows"; item.LootType = LootType.Blessed; BaseContainer cont; CharacterCreation.PlaceItemIn(this, 58, 57, (cont = new Backpack())); cont.Hue = 2213; cont.Name = "a golden backpack"; CharacterCreation.PlaceItemIn(cont, 44, 65, new SulfurousAsh(10000)); CharacterCreation.PlaceItemIn(cont, 77, 65, new Nightshade(10000)); CharacterCreation.PlaceItemIn(cont, 110, 65, new SpidersSilk(10000)); CharacterCreation.PlaceItemIn(cont, 143, 65, new Garlic(10000)); CharacterCreation.PlaceItemIn(cont, 44, 128, new Ginseng(10000)); CharacterCreation.PlaceItemIn(cont, 77, 128, new Bloodmoss(10000)); CharacterCreation.PlaceItemIn(cont, 110, 128, new BlackPearl(10000)); CharacterCreation.PlaceItemIn(cont, 143, 128, new MandrakeRoot(10000)); //CharacterCreation.PlaceItemIn(this, 16, 81, new DonationBandana()); //Replaced the bandana with a deed - Edit by Blady CharacterCreation.PlaceItemIn(this, 74, 64, (item = new DonationDeed())); item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 103, 58, (item = new Sandals())); item.Hue = Utility.RandomList(5, 70, 90, 110); item.LootType = LootType.Blessed; CharacterCreation.PlaceItemIn(this, 122, 53, new SpecialDonateDye()); CharacterCreation.PlaceItemIn(this, 133, 53, (item = new KillBook())); item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 156, 55, (item = new EtherealHorse())); item.Hue = 2213; item.Name = "No Aged Ethereal"; ((EtherealMount)item).IsDonationItem = true; CharacterCreation.PlaceItemIn(this, 34, 83, (item = new HolyDeedofBlessing())); item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 43, 83, (item = new ClothingBlessDeed())); item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 58, 83, (item = new KillResetDeedAOS())); //by Blady item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 73, 83, (item = new SmallBrickHouseDeed())); item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 88, 83, (item = new NameChangeDeed())); item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 103, 83, (item = new AntiBlessDeed())); item.Hue = 2213; //CharacterCreation.PlaceItemIn(this, 118, 83, (item = new BankCheck(100000))); //item.Hue = 2213; CharacterCreation.PlaceItemIn(this, 130, 83, (item = new MembershipTicket())); item.Hue = 2213; ((MembershipTicket)item).MemberShipTime = TimeSpan.MaxValue; }
public void CreateLoot() { int chance = Utility.Random( 100 ); Item m_Reward = null; if ( chance < 3 ) m_Reward = new NameChangeDeed(); else if ( chance < 33 ) m_Reward = new PowerScroll( PowerScroll.Skills[Utility.Random(PowerScroll.Skills.Count)], (100+(Utility.Random(3)+2)*5) ); else if ( chance < 50 ) m_Reward = new StatCapScroll( (225+(Utility.Random(2)+1)*5) ); else if ( chance < 55 ) m_Reward = new MagicSewingKit(); else if ( chance < 60 ) m_Reward = new ClothingBlessDeed(); else if ( chance < 70 ) m_Reward = new RunicSewingKit(CraftResource.BarbedLeather, ( Utility.Random( 2 ) + 3 ) ); else { int amount = Utility.RandomMinMax( 5, 10 )*10000; m_Reward = new BankCheck(amount); } PackItem( new CopperBar(Utility.Random( 2 ) + 2) ); if (m_Reward != null) { PackItem( m_Reward ); Timer m_TimerCursed = new CursedArtifactSystem.CursedTimer( m_Reward, 6 ); m_TimerCursed.Start(); } }
public void DistributeLoot() { if ( Map != Map.Felucca ) return; ArrayList PlayersToGiveTo = new ArrayList(); ArrayList list = Aggressors; for ( int i = 0; i < list.Count; ++i ) { AggressorInfo info = (AggressorInfo)list[i]; if ( info.Attacker.Player && info.Attacker.Alive && (DateTime.Now - info.LastCombatTime) < TimeSpan.FromSeconds( 60.0 ) && !PlayersToGiveTo.Contains( info.Attacker ) ) PlayersToGiveTo.Add( info.Attacker ); } list = Aggressed; for ( int i = 0; i < list.Count; ++i ) { AggressorInfo info = (AggressorInfo)list[i]; if ( info.Defender.Player && info.Defender.Alive && (DateTime.Now - info.LastCombatTime) < TimeSpan.FromSeconds( 60.0 ) && !PlayersToGiveTo.Contains( info.Defender ) ) PlayersToGiveTo.Add( info.Defender ); } if ( PlayersToGiveTo.Count <= 0 ) return; if ( Backpack == null ) return; //ArrayList ItemsToGive = new ArrayList(); Item item = null; int rand = Utility.Random( 200 ); if ( rand == 0 ) item = new LayerSashDeed(); else if ( rand <= 8 ) item = new HolyDeedofBlessing(); else if ( rand <= 30 ) item = new CursedClothingBlessDeed(); else if ( rand <= 80 ) item = new ClothingBlessDeed(); if ( item != null ) { if ( item.Movable == false || item.LootType == LootType.Blessed || item.LootType == LootType.Newbied ) return; PlayerMobile player = PlayersToGiveTo[Utility.Random( PlayersToGiveTo.Count )] as PlayerMobile; if ( player != null && player.Backpack != null ) { player.SendMessage( "You have been given a special item." ); player.Backpack.DropItem( item ); } } }