mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-04-19 07:48:37 +02:00
work to make documentation unified.
This commit is contained in:
@@ -4,14 +4,11 @@ getStamina() Netscript Function
|
||||
.. js:function:: getStamina()
|
||||
|
||||
:RAM cost: 4 GB
|
||||
:returns: Array with two elements [Current stamina, Max stamina]
|
||||
|
||||
Returns an array with two elements:
|
||||
Example:
|
||||
|
||||
[Current stamina, Max stamina]
|
||||
.. code-block:: javascript
|
||||
|
||||
Example usage::
|
||||
|
||||
function getStaminaPercentage() {
|
||||
let res = bladeburner.getStamina();
|
||||
return res[0] / res[1];
|
||||
}
|
||||
res = bladeburner.getStamina();
|
||||
percentage = res[0] / res[1];
|
||||
|
||||
Reference in New Issue
Block a user