mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-12-18 04:05:46 +01:00
DOCUMENTATION: Clarify isBusy and stopAction Singularity APIs (#1822)
This commit is contained in:
parent
f07c442a92
commit
4137a0e522
@ -15,11 +15,29 @@ isBusy(): boolean;
|
||||
|
||||
boolean
|
||||
|
||||
True if the player is currently performing an ‘action’, false otherwise.
|
||||
True if the player is currently performing an action, false otherwise.
|
||||
|
||||
## Remarks
|
||||
|
||||
RAM cost: 0.5 GB \* 16/4/1
|
||||
|
||||
Returns a boolean indicating whether or not the player is currently performing an ‘action’. These actions include working for a company/faction, studying at a university, working out at a gym, creating a program, committing a crime, etc.
|
||||
Returns a boolean indicating if the player is currently performing an action. These actions include:
|
||||
|
||||
- Studying at a university
|
||||
|
||||
- Working out at a gym
|
||||
|
||||
- Working for a company/faction
|
||||
|
||||
- Creating a program
|
||||
|
||||
- Committing a crime
|
||||
|
||||
- Grafting an augmentation
|
||||
|
||||
Note:
|
||||
|
||||
- This function returns true when the UI is showing the infiltration UI or the BitVerse.
|
||||
|
||||
- This function does not take Bladeburner actions into account. You can use [getCurrentAction](./bitburner.bladeburner.getcurrentaction.md) to check if you are performing a Bladeburner action.
|
||||
|
||||
|
@ -15,17 +15,27 @@ stopAction(): boolean;
|
||||
|
||||
boolean
|
||||
|
||||
True if the player’s action was ended, false if the player was not performing an action.
|
||||
True if the player’s action is stopped, false if the player is not performing an action.
|
||||
|
||||
## Remarks
|
||||
|
||||
RAM cost: 1 GB \* 16/4/1
|
||||
|
||||
This function is used to end whatever ‘action’ the player is currently performing. The player will receive whatever money/experience/etc. he has earned from that action.
|
||||
This function stops the action the player is currently performing. The player will receive rewards (money, experience, etc.) they have earned from that action.
|
||||
|
||||
The actions that can be stopped with this function are:
|
||||
|
||||
\* Studying at a university \* Working out at a gym \* Working for a company/faction \* Creating a program \* Committing a crime
|
||||
- Studying at a university
|
||||
|
||||
This function will return true if the player’s action was ended. It will return false if the player was not performing an action when this function was called.
|
||||
- Working out at a gym
|
||||
|
||||
- Working for a company/faction
|
||||
|
||||
- Creating a program
|
||||
|
||||
- Committing a crime
|
||||
|
||||
- Grafting an augmentation
|
||||
|
||||
This function will return true if the player's action is stopped. It will return false if the player is not performing an action when this function is called.
|
||||
|
||||
|
53
src/ScriptEditor/NetscriptDefinitions.d.ts
vendored
53
src/ScriptEditor/NetscriptDefinitions.d.ts
vendored
@ -1924,39 +1924,62 @@ export interface Singularity {
|
||||
|
||||
/**
|
||||
* Check if the player is busy.
|
||||
*
|
||||
* @remarks
|
||||
* RAM cost: 0.5 GB * 16/4/1
|
||||
*
|
||||
* Returns a boolean indicating if the player is currently performing an action. These actions include:
|
||||
*
|
||||
* Returns a boolean indicating whether or not the player is currently performing an
|
||||
* ‘action’. These actions include working for a company/faction, studying at a university,
|
||||
* working out at a gym, creating a program, committing a crime, etc.
|
||||
* - Studying at a university
|
||||
*
|
||||
* @returns True if the player is currently performing an ‘action’, false otherwise.
|
||||
* - Working out at a gym
|
||||
*
|
||||
* - Working for a company/faction
|
||||
*
|
||||
* - Creating a program
|
||||
*
|
||||
* - Committing a crime
|
||||
*
|
||||
* - Grafting an augmentation
|
||||
*
|
||||
* Note:
|
||||
*
|
||||
* - This function returns true when the UI is showing the infiltration UI or the BitVerse.
|
||||
*
|
||||
* - This function does not take Bladeburner actions into account. You can use {@link Bladeburner.getCurrentAction | getCurrentAction}
|
||||
* to check if you are performing a Bladeburner action.
|
||||
*
|
||||
* @returns True if the player is currently performing an action, false otherwise.
|
||||
*/
|
||||
isBusy(): boolean;
|
||||
|
||||
/**
|
||||
* Stop the current action.
|
||||
*
|
||||
* @remarks
|
||||
* RAM cost: 1 GB * 16/4/1
|
||||
*
|
||||
*
|
||||
* This function is used to end whatever ‘action’ the player is currently performing.
|
||||
* The player will receive whatever money/experience/etc. he has earned from that action.
|
||||
* This function stops the action the player is currently performing. The player will receive rewards (money,
|
||||
* experience, etc.) they have earned from that action.
|
||||
*
|
||||
* The actions that can be stopped with this function are:
|
||||
*
|
||||
* * Studying at a university
|
||||
* * Working out at a gym
|
||||
* * Working for a company/faction
|
||||
* * Creating a program
|
||||
* * Committing a crime
|
||||
* - Studying at a university
|
||||
*
|
||||
* This function will return true if the player’s action was ended.
|
||||
* It will return false if the player was not performing an action when this function was called.
|
||||
* - Working out at a gym
|
||||
*
|
||||
* @returns True if the player’s action was ended, false if the player was not performing an action.
|
||||
* - Working for a company/faction
|
||||
*
|
||||
* - Creating a program
|
||||
*
|
||||
* - Committing a crime
|
||||
*
|
||||
* - Grafting an augmentation
|
||||
*
|
||||
* This function will return true if the player's action is stopped. It will return false if the player is not
|
||||
* performing an action when this function is called.
|
||||
*
|
||||
* @returns True if the player’s action is stopped, false if the player is not performing an action.
|
||||
*/
|
||||
stopAction(): boolean;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user