Remove redundant registerProduction()
function
This commit is contained in:
parent
a66b6644a1
commit
4bb5e3de43
@ -587,7 +587,7 @@ export class HideoutController
|
|||||||
): IItemEventRouterResponse
|
): IItemEventRouterResponse
|
||||||
{
|
{
|
||||||
// Start production
|
// Start production
|
||||||
this.registerProduction(pmcData, body, sessionID);
|
this.hideoutHelper.registerProduction(pmcData, body, sessionID);
|
||||||
|
|
||||||
// Find the recipe of the production
|
// Find the recipe of the production
|
||||||
const recipe = this.databaseServer.getTables().hideout.production.find((p) => p._id === body.recipeId);
|
const recipe = this.databaseServer.getTables().hideout.production.find((p) => p._id === body.recipeId);
|
||||||
@ -739,7 +739,7 @@ export class HideoutController
|
|||||||
sessionID: string,
|
sessionID: string,
|
||||||
): IItemEventRouterResponse
|
): IItemEventRouterResponse
|
||||||
{
|
{
|
||||||
this.registerProduction(pmcData, request, sessionID);
|
this.hideoutHelper.registerProduction(pmcData, request, sessionID);
|
||||||
|
|
||||||
return this.eventOutputHolder.getOutput(sessionID);
|
return this.eventOutputHolder.getOutput(sessionID);
|
||||||
}
|
}
|
||||||
@ -999,7 +999,7 @@ export class HideoutController
|
|||||||
|
|
||||||
// - increment skill point for crafting
|
// - increment skill point for crafting
|
||||||
// - delete the production in profile Hideout.Production
|
// - delete the production in profile Hideout.Production
|
||||||
// Manager Hideout skill
|
// Hideout Management skill
|
||||||
// ? use a configuration variable for the value?
|
// ? use a configuration variable for the value?
|
||||||
const globals = this.databaseServer.getTables().globals;
|
const globals = this.databaseServer.getTables().globals;
|
||||||
this.profileHelper.addSkillPointsToPlayer(
|
this.profileHelper.addSkillPointsToPlayer(
|
||||||
@ -1009,7 +1009,7 @@ export class HideoutController
|
|||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
|
|
||||||
// Manager Crafting skill
|
// Add Crafting skill to player profile
|
||||||
if (craftingExpAmount > 0)
|
if (craftingExpAmount > 0)
|
||||||
{
|
{
|
||||||
this.profileHelper.addSkillPointsToPlayer(pmcData, SkillTypes.CRAFTING, craftingExpAmount);
|
this.profileHelper.addSkillPointsToPlayer(pmcData, SkillTypes.CRAFTING, craftingExpAmount);
|
||||||
@ -1127,22 +1127,6 @@ export class HideoutController
|
|||||||
pmcData.Hideout.Production[prodId].inProgress = false;
|
pmcData.Hideout.Production[prodId].inProgress = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Start area production for item by adding production to profiles' Hideout.Production array
|
|
||||||
* @param pmcData Player profile
|
|
||||||
* @param request Start production request
|
|
||||||
* @param sessionID Session id
|
|
||||||
* @returns IItemEventRouterResponse
|
|
||||||
*/
|
|
||||||
public registerProduction(
|
|
||||||
pmcData: IPmcData,
|
|
||||||
request: IHideoutSingleProductionStartRequestData | IHideoutContinuousProductionStartRequestData,
|
|
||||||
sessionID: string,
|
|
||||||
): IItemEventRouterResponse
|
|
||||||
{
|
|
||||||
return this.hideoutHelper.registerProduction(pmcData, request, sessionID);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get quick time event list for hideout
|
* Get quick time event list for hideout
|
||||||
* // TODO - implement this
|
* // TODO - implement this
|
||||||
|
Loading…
Reference in New Issue
Block a user