Add donationToFavor() to docs (#1960)

This commit is contained in:
LJ
2025-02-13 22:35:55 -07:00
committed by GitHub
parent 30075f3c07
commit 905d37ef93
2 changed files with 26 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) &gt; [bitburner](./bitburner.md) &gt; [ReputationFormulas](./bitburner.reputationformulas.md) &gt; [donationForRep](./bitburner.reputationformulas.donationforrep.md)
## ReputationFormulas.donationForRep() method
Calculate the donation needed to gain an amount of reputation.
**Signature:**
```typescript
donationForRep(reputation: number, player: Person): number;
```
## Parameters
| Parameter | Type | Description |
| --- | --- | --- |
| reputation | number | Amount of reputation |
| player | [Person](./bitburner.person.md) | Player info, typically from [getPlayer](./bitburner.ns.getplayer.md) |
**Returns:**
number

View File

@@ -18,5 +18,6 @@ interface ReputationFormulas
| --- | --- |
| [calculateFavorToRep(favor)](./bitburner.reputationformulas.calculatefavortorep.md) | Calculate the total required amount of faction reputation to reach a target favor. |
| [calculateRepToFavor(rep)](./bitburner.reputationformulas.calculatereptofavor.md) | Calculate the resulting faction favor of a total amount of reputation. (Faction favor is gained whenever you install an Augmentation.) |
| [donationForRep(reputation, player)](./bitburner.reputationformulas.donationforrep.md) | Calculate the donation needed to gain an amount of reputation. |
| [repFromDonation(amount, player)](./bitburner.reputationformulas.repfromdonation.md) | Calculate how much rep would be gained. |