Fix AHBot to calculate the deposit for auctions so it can be used to check the code for figuring deposit amount on a wide range of items. Fix ahbotoptions command so it works from the server console again. change commented out lines in GetAuctionDeposit so they display in debug loglevel. Min/Max Time settings replaced with a function that selects 12 24 and 48 randomly as the auction times.

--HG--
branch : trunk
This commit is contained in:
Chaz Brown
2009-06-05 20:51:45 -04:00
parent 16d3c8378f
commit ab712b78ba
5 changed files with 56 additions and 49 deletions
-23
View File
@@ -40,8 +40,6 @@ class AHBConfig
uint32 AHFID;
uint32 minItems;
uint32 maxItems;
uint32 minTime;
uint32 maxTime;
uint32 percentGreyTradeGoods;
uint32 percentWhiteTradeGoods;
uint32 percentGreenTradeGoods;
@@ -169,27 +167,6 @@ class AHBConfig
{
return maxItems;
}
void SetMinTime(uint32 value)
{
minTime = value;
}
uint32 GetMinTime()
{
if (minTime < 1)
return 1;
else if ((maxTime) && (minTime > maxTime))
return maxTime;
else
return minTime;
}
void SetMaxTime(uint32 value)
{
maxTime = value;
}
uint32 GetMaxTime()
{
return maxTime;
}
void SetPercentages(uint32 greytg, uint32 whitetg, uint32 greentg, uint32 bluetg, uint32 purpletg, uint32 orangetg, uint32 yellowtg, uint32 greyi, uint32 whitei, uint32 greeni, uint32 bluei, uint32 purplei, uint32 orangei, uint32 yellowi)
{
uint32 totalPercent = greytg + whitetg + greentg + bluetg + purpletg + orangetg + yellowtg + greyi + whitei + greeni + bluei + purplei + orangei + yellowi;