massive branch sync

This commit is contained in:
mark 2010-04-25 06:09:43 +00:00
parent 489bbabe93
commit b3e8ec0a08
192 changed files with 1249 additions and 1124 deletions

View file

@ -25,7 +25,7 @@ namespace Server.Mobiles
{
private const int MaxSell = 500;
protected abstract ArrayList SBInfos { get; }
protected abstract List<SBInfo> SBInfos { get; }
private ArrayList m_ArmorBuyInfo = new ArrayList();
private ArrayList m_ArmorSellInfo = new ArrayList();
@ -547,11 +547,11 @@ namespace Server.Mobiles
UpdateBuyInfo();
int count = 0;
ArrayList list;
List<BuyItemState> list;
IBuyItemInfo[] buyInfo = this.GetBuyInfo();
IShopSellInfo[] sellInfo = this.GetSellInfo();
list = new ArrayList( buyInfo.Length );
list = new List<BuyItemState>( buyInfo.Length );
Container cont = this.BuyPack;
List<ObjectPropertyList> opls = null;
@ -798,7 +798,7 @@ namespace Server.Mobiles
return null;
}
private void ProcessSinglePurchase( BuyItemResponse buy, IBuyItemInfo bii, ArrayList validBuy, ref int controlSlots, ref bool fullPurchase, ref int totalCost )
private void ProcessSinglePurchase( BuyItemResponse buy, IBuyItemInfo bii, List<BuyItemResponse> validBuy, ref int controlSlots, ref bool fullPurchase, ref int totalCost )
{
int amount = buy.Amount;
@ -895,7 +895,7 @@ namespace Server.Mobiles
}
}
public virtual bool OnBuyItems( Mobile buyer, ArrayList list )
public virtual bool OnBuyItems( Mobile buyer, List<BuyItemResponse> list )
{
if ( !IsActiveSeller )
return false;
@ -914,7 +914,7 @@ namespace Server.Mobiles
IBuyItemInfo[] buyInfo = this.GetBuyInfo();
IShopSellInfo[] info = GetSellInfo();
int totalCost = 0;
ArrayList validBuy = new ArrayList( list.Count );
List<BuyItemResponse> validBuy = new List<BuyItemResponse>( list.Count );
Container cont;
bool bought = false;
bool fromBank = false;
@ -1125,7 +1125,7 @@ namespace Server.Mobiles
return true;
}
public virtual bool OnSellItems( Mobile seller, ArrayList list )
public virtual bool OnSellItems( Mobile seller, List<SellItemResponse> list )
{
if ( !IsActiveBuyer )
return false;
@ -1146,8 +1146,6 @@ namespace Server.Mobiles
int GiveGold = 0;
int Sold = 0;
Container cont;
ArrayList delete = new ArrayList();
ArrayList drop = new ArrayList();
foreach ( SellItemResponse resp in list )
{
@ -1277,12 +1275,12 @@ namespace Server.Mobiles
writer.Write( (int)1 ); // version
ArrayList sbInfos = this.SBInfos;
List<SBInfo> sbInfos = this.SBInfos;
for ( int i = 0; sbInfos != null && i < sbInfos.Count; ++i )
{
SBInfo sbInfo = (SBInfo)sbInfos[i];
ArrayList buyInfo = sbInfo.BuyInfo;
SBInfo sbInfo = sbInfos[i];
List<GenericBuyInfo> buyInfo = sbInfo.BuyInfo;
for ( int j = 0; buyInfo != null && j < buyInfo.Count; ++j )
{
@ -1320,7 +1318,7 @@ namespace Server.Mobiles
LoadSBInfo();
ArrayList sbInfos = this.SBInfos;
List<SBInfo> sbInfos = this.SBInfos;
switch ( version )
{
@ -1340,8 +1338,8 @@ namespace Server.Mobiles
if ( sbInfoIndex >= 0 && sbInfoIndex < sbInfos.Count )
{
SBInfo sbInfo = (SBInfo)sbInfos[sbInfoIndex];
ArrayList buyInfo = sbInfo.BuyInfo;
SBInfo sbInfo = sbInfos[sbInfoIndex];
List<GenericBuyInfo> buyInfo = sbInfo.BuyInfo;
if ( buyInfo != null && buyInfoIndex >= 0 && buyInfoIndex < buyInfo.Count )
{