Merge pull request #3710 from danielyxie/dev

Fix blade error
This commit is contained in:
hydroflame 2022-05-22 20:49:07 -04:00 committed by GitHub
commit 9a2c743d66
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 16 additions and 14 deletions

4
dist/main.bundle.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -219,7 +219,10 @@ export function PurchasableAugmentation(props: IPurchasableAugProps): React.Reac
textOverflow: "ellipsis", textOverflow: "ellipsis",
whiteSpace: "nowrap", whiteSpace: "nowrap",
overflow: "hidden", overflow: "hidden",
color: props.owned ? Settings.theme.disabled : Settings.theme.primary, color:
props.owned || !props.parent.canPurchase(props.parent.player, aug)
? Settings.theme.disabled
: Settings.theme.primary,
}} }}
> >
{aug.name} {aug.name}

@ -1677,11 +1677,11 @@ export class Bladeburner implements IBladeburner {
this.actionTimeOverflow = 0; this.actionTimeOverflow = 0;
if (this.actionTimeCurrent >= this.actionTimeToComplete) { if (this.actionTimeCurrent >= this.actionTimeToComplete) {
this.actionTimeOverflow = this.actionTimeCurrent - this.actionTimeToComplete; this.actionTimeOverflow = this.actionTimeCurrent - this.actionTimeToComplete;
const action = this.getActionObject(this.action);
const retValue = this.completeAction(player, player, this.action); const retValue = this.completeAction(player, player, this.action);
player.gainMoney(retValue.money, "bladeburner"); player.gainMoney(retValue.money, "bladeburner");
player.gainStats(retValue); player.gainStats(retValue);
// Operation Daedalus // Operation Daedalus
const action = this.getActionObject(this.action);
if (action == null) { if (action == null) {
throw new Error("Failed to get BlackOperation Object for: " + this.action.name); throw new Error("Failed to get BlackOperation Object for: " + this.action.name);
} else if (action.name === BlackOperationNames.OperationDaedalus && this.blackops[action.name]) { } else if (action.name === BlackOperationNames.OperationDaedalus && this.blackops[action.name]) {

@ -105,6 +105,7 @@ const hacknet: IMap<any> = {
numHashes: 0, numHashes: 0,
hashCost: 0, hashCost: 0,
spendHashes: 0, spendHashes: 0,
maxNumNodes: 0,
}; };
// Stock API // Stock API

@ -993,6 +993,7 @@ export function finishFactionWork(this: IPlayer, cancelled: boolean, sing = fals
faction.playerReputation += this.workRepGained; faction.playerReputation += this.workRepGained;
this.updateSkillLevels(); this.updateSkillLevels();
let res = "";
if (!sing) { if (!sing) {
dialogBoxCreate( dialogBoxCreate(
@ -1013,12 +1014,8 @@ export function finishFactionWork(this: IPlayer, cancelled: boolean, sing = fals
<br /> <br />
</>, </>,
); );
} } else {
res =
this.isWorking = false;
this.resetWorkStatus();
if (sing) {
const res =
"You worked for your faction " + "You worked for your faction " +
faction.name + faction.name +
" for a total of " + " for a total of " +
@ -1039,10 +1036,11 @@ export function finishFactionWork(this: IPlayer, cancelled: boolean, sing = fals
" agi exp, and " + " agi exp, and " +
numeralWrapper.formatExp(this.workChaExpGained) + numeralWrapper.formatExp(this.workChaExpGained) +
" cha exp."; " cha exp.";
return res;
} }
return "";
this.isWorking = false;
this.resetWorkStatus();
return res;
} }
//Money gained per game cycle //Money gained per game cycle