mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-22 15:43:49 +01:00
Merge pull request #2454 from zeddrak/patch-1
Apply bitnode multiplier before capping at 1 in calculatePercentMoneyHacked in hacking.ts
This commit is contained in:
commit
f52fc9fa7b
@ -49,7 +49,7 @@ export function calculatePercentMoneyHacked(server: Server, player: IPlayer): nu
|
||||
|
||||
const difficultyMult = (100 - server.hackDifficulty) / 100;
|
||||
const skillMult = (player.hacking - (server.requiredHackingSkill - 1)) / player.hacking;
|
||||
const percentMoneyHacked = (difficultyMult * skillMult * player.hacking_money_mult) / balanceFactor;
|
||||
const percentMoneyHacked = (difficultyMult * skillMult * player.hacking_money_mult * BitNodeMultipliers.ScriptHackMoney) / balanceFactor;
|
||||
if (percentMoneyHacked < 0) {
|
||||
return 0;
|
||||
}
|
||||
@ -57,7 +57,7 @@ export function calculatePercentMoneyHacked(server: Server, player: IPlayer): nu
|
||||
return 1;
|
||||
}
|
||||
|
||||
return percentMoneyHacked * BitNodeMultipliers.ScriptHackMoney;
|
||||
return percentMoneyHacked;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user