Removed dead endpoints

This commit is contained in:
Dev 2024-07-06 13:47:56 +01:00
parent 1f76ce5d10
commit d71bf2c2c0
3 changed files with 1 additions and 30 deletions

View File

@ -1,11 +1,9 @@
import { inject, injectable } from "tsyringe"; import { inject, injectable } from "tsyringe";
import { LocationController } from "@spt/controllers/LocationController"; import { LocationController } from "@spt/controllers/LocationController";
import { IEmptyRequestData } from "@spt/models/eft/common/IEmptyRequestData"; import { IEmptyRequestData } from "@spt/models/eft/common/IEmptyRequestData";
import { ILocationBase } from "@spt/models/eft/common/ILocationBase";
import { ILocationsGenerateAllResponse } from "@spt/models/eft/common/ILocationsSourceDestinationBase"; import { ILocationsGenerateAllResponse } from "@spt/models/eft/common/ILocationsSourceDestinationBase";
import { IGetBodyResponseData } from "@spt/models/eft/httpResponse/IGetBodyResponseData"; import { IGetBodyResponseData } from "@spt/models/eft/httpResponse/IGetBodyResponseData";
import { IGetAirdropLootResponse } from "@spt/models/eft/location/IGetAirdropLootResponse"; import { IGetAirdropLootResponse } from "@spt/models/eft/location/IGetAirdropLootResponse";
import { IGetLocationRequestData } from "@spt/models/eft/location/IGetLocationRequestData";
import { HttpResponseUtil } from "@spt/utils/HttpResponseUtil"; import { HttpResponseUtil } from "@spt/utils/HttpResponseUtil";
@injectable() @injectable()
@ -27,16 +25,6 @@ export class LocationCallbacks
return this.httpResponse.getBody(this.locationController.generateAll(sessionID)); return this.httpResponse.getBody(this.locationController.generateAll(sessionID));
} }
/** Handle client/location/getLocalloot */
public getLocation(
url: string,
info: IGetLocationRequestData,
sessionID: string,
): IGetBodyResponseData<ILocationBase>
{
return this.httpResponse.getBody(this.locationController.get(sessionID, info));
}
/** Handle client/airdrop/loot */ /** Handle client/airdrop/loot */
public getAirdropLoot( public getAirdropLoot(
url: string, url: string,

View File

@ -6,7 +6,6 @@ import { ILocationBase } from "@spt/models/eft/common/ILocationBase";
import { ILocationsGenerateAllResponse } from "@spt/models/eft/common/ILocationsSourceDestinationBase"; import { ILocationsGenerateAllResponse } from "@spt/models/eft/common/ILocationsSourceDestinationBase";
import { ILooseLoot, SpawnpointTemplate } from "@spt/models/eft/common/ILooseLoot"; import { ILooseLoot, SpawnpointTemplate } from "@spt/models/eft/common/ILooseLoot";
import { IGetAirdropLootResponse } from "@spt/models/eft/location/IGetAirdropLootResponse"; import { IGetAirdropLootResponse } from "@spt/models/eft/location/IGetAirdropLootResponse";
import { IGetLocationRequestData } from "@spt/models/eft/location/IGetLocationRequestData";
import { ConfigTypes } from "@spt/models/enums/ConfigTypes"; import { ConfigTypes } from "@spt/models/enums/ConfigTypes";
import { ILocationConfig } from "@spt/models/spt/config/ILocationConfig"; import { ILocationConfig } from "@spt/models/spt/config/ILocationConfig";
import { IRaidChanges } from "@spt/models/spt/location/IRaidChanges"; import { IRaidChanges } from "@spt/models/spt/location/IRaidChanges";
@ -41,22 +40,6 @@ export class LocationController
this.locationConfig = this.configServer.getConfig(ConfigTypes.LOCATION); this.locationConfig = this.configServer.getConfig(ConfigTypes.LOCATION);
} }
/* */
/**
* Handle client/location/getLocalloot
* Get a location (map) with generated loot data
* @param sessionId Player id
* @param request Map request to generate
* @returns ILocationBase
*/
public get(sessionId: string, request: IGetLocationRequestData): ILocationBase
{
this.logger.debug(`Generating data for: ${request.locationId}, variant: ${request.variantId}`);
const name = request.locationId.toLowerCase().replace(" ", "");
return this.generate(name);
}
/** /**
* Generate a maps base location and loot * Generate a maps base location and loot
* @param name Map name * @param name Map name

View File

@ -380,7 +380,7 @@ export class MatchController
serverId: `${request.location}.${request.playerSide}.${this.timeUtil.getTimestamp()}`, // TODO - does this need to be more verbose - investigate client? serverId: `${request.location}.${request.playerSide}.${this.timeUtil.getTimestamp()}`, // TODO - does this need to be more verbose - investigate client?
serverSettings: this.databaseService.getLocationServices(), // TODO - is this per map or global? serverSettings: this.databaseService.getLocationServices(), // TODO - is this per map or global?
profile: { insuredItems: playerProfile.InsuredItems }, profile: { insuredItems: playerProfile.InsuredItems },
locationLoot: this.locationController.generate(request.location), locationLoot: this.locationController.generate(request.location), // Move out of controller
}; };
// Clear bot cache ready for a fresh raid // Clear bot cache ready for a fresh raid