Renamed function to clarify what it does

This commit is contained in:
Dev 2024-05-22 12:51:04 +01:00
parent 2b3ee4f15c
commit 961210f73c
2 changed files with 5 additions and 5 deletions

View File

@ -680,7 +680,7 @@ export class RagfairController
return { _tpl: item._tpl, count: item.count, onlyFunctional: item.onlyFunctional };
});
return this.ragfairOfferGenerator.createFleaOffer(
return this.ragfairOfferGenerator.createAndAddFleaOffer(
sessionId,
this.timeUtil.getTimestamp(),
formattedItems,

View File

@ -73,9 +73,9 @@ export class RagfairOfferGenerator
* @param barterScheme Cost of item (currency or barter)
* @param loyalLevel Loyalty level needed to buy item
* @param sellInOnePiece Flags sellInOnePiece to be true
* @returns IRagfairOffer
* @returns Created flea offer
*/
public createFleaOffer(
public createAndAddFleaOffer(
userID: string,
time: number,
items: Item[],
@ -515,7 +515,7 @@ export class RagfairOfferGenerator
barterScheme = this.createCurrencyBarterScheme(itemWithChildren, isPackOffer);
}
const offer = this.createFleaOffer(
const offer = this.createAndAddFleaOffer(
randomUserId,
this.timeUtil.getTimestamp(),
itemWithChildren,
@ -598,7 +598,7 @@ export class RagfairOfferGenerator
const barterSchemeItems = assorts.barter_scheme[item._id][0];
const loyalLevel = assorts.loyal_level_items[item._id];
const offer = this.createFleaOffer(traderID, time, items, barterSchemeItems, loyalLevel, false);
const offer = this.createAndAddFleaOffer(traderID, time, items, barterSchemeItems, loyalLevel, false);
// Refresh complete, reset flag to false
trader.base.refreshTraderRagfairOffers = false;