mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-18 07:18:38 +02:00
Merge pull request #3170 from nickofolas/feature/grafting
[Feature] Grafting
This commit is contained in:
45
src/ScriptEditor/NetscriptDefinitions.d.ts
vendored
45
src/ScriptEditor/NetscriptDefinitions.d.ts
vendored
@@ -95,6 +95,7 @@ interface Player {
|
||||
tor: boolean;
|
||||
hasCorporation: boolean;
|
||||
inBladeburner: boolean;
|
||||
entropyStacks: number;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -3719,6 +3720,43 @@ export interface Sleeve {
|
||||
purchaseSleeveAug(sleeveNumber: number, augName: string): boolean;
|
||||
}
|
||||
|
||||
export interface Grafting {
|
||||
/**
|
||||
* Retrieve the crafting cost of an aug.
|
||||
* @remarks
|
||||
* RAM cost: 3.75 GB
|
||||
*
|
||||
* @param augName - Name of the aug to check the price of. Must be an exact match.
|
||||
* @returns The cost required to craft the named augmentation.
|
||||
* @throws Will error if an invalid Augmentation name is provided.
|
||||
*/
|
||||
getAugmentationCraftPrice(augName: string): number;
|
||||
|
||||
/**
|
||||
* Retrieves the time required to craft an aug.
|
||||
* @remarks
|
||||
* RAM cost: 3.75 GB
|
||||
*
|
||||
* @param augName - Name of the aug to check the crafting time of. Must be an exact match.
|
||||
* @returns The time required, in millis, to craft the named augmentation.
|
||||
* @throws Will error if an invalid Augmentation name is provided.
|
||||
*/
|
||||
getAugmentationCraftTime(augName: string): number;
|
||||
|
||||
/**
|
||||
* Begins crafting the named aug. You must be in New Tokyo to use this.
|
||||
* @remarks
|
||||
* RAM cost: 7.5 GB
|
||||
*
|
||||
* @param augName - The name of the aug to begin crafting. Must be an exact match.
|
||||
* @param focus - Acquire player focus on this Augmentation crafting. Optional. Defaults to true.
|
||||
* @returns True if the aug successfully began crafting, false otherwise (e.g. not enough money, or
|
||||
* invalid Augmentation name provided).
|
||||
* @throws Will error if called while you are not in New Tokyo.
|
||||
*/
|
||||
craftAugmentation(augName: string, focus?: boolean): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* Skills formulas
|
||||
* @public
|
||||
@@ -4280,6 +4318,13 @@ export interface NS extends Singularity {
|
||||
*/
|
||||
readonly ui: UserInterface;
|
||||
|
||||
/**
|
||||
* Namespace for grafting functions.
|
||||
* @remarks
|
||||
* RAM cost: 0 GB
|
||||
*/
|
||||
readonly grafting: Grafting;
|
||||
|
||||
/**
|
||||
* Arguments passed into the script.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user