public SendTarget( BagOfSending bag ) : base( -1, false, TargetFlags.None ) { m_Bag = bag; }
public SendTarget(BagOfSending bag) : base(-1, false, TargetFlags.None) { this.m_Bag = bag; }
public UseBagEntry( BagOfSending bag, bool enabled ) : base( 6189 ) { m_Bag = bag; if ( !enabled ) Flags |= CMEFlags.Disabled; }
public static void GiveRewardTo( PlayerMobile player, ref bool bagOfSending, ref bool powderOfTranslocation, ref bool gold ) { if ( bagOfSending ) { Item reward = new BagOfSending(); if ( player.PlaceInBackpack( reward ) ) { player.SendLocalizedMessage( 1054074, "", 0x59 ); // You have been given a bag of sending. bagOfSending = false; } else { reward.Delete(); } } if ( powderOfTranslocation ) { Item reward = new PowderOfTranslocation( Utility.RandomMinMax( 10, 12 ) ); if ( player.PlaceInBackpack( reward ) ) { player.SendLocalizedMessage( 1054075, "", 0x59 ); // You have been given some powder of translocation. powderOfTranslocation = false; } else { reward.Delete(); } } if ( gold ) { Item reward = new Gold( Utility.RandomMinMax( 250, 350 ) ); if ( player.PlaceInBackpack( reward ) ) { player.SendLocalizedMessage( 1054076, "", 0x59 ); // You have been given some gold. gold = false; } else { reward.Delete(); } } }