mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2026-05-04 06:37:49 +02:00
MISC: Clarify conditions of activating Gang, Bladeburner, Stanek's Gift (#2053)
This commit is contained in:
@@ -308,15 +308,20 @@ export function NetscriptBladeburner(): InternalAPI<INetscriptBladeburner> {
|
||||
},
|
||||
joinBladeburnerDivision: (ctx) => () => {
|
||||
if (!canAccessBitNodeFeature(7) && !canAccessBitNodeFeature(6)) {
|
||||
return false; //Does not have bitnode 6 or 7
|
||||
} else if (Player.bitNodeOptions.disableBladeburner) {
|
||||
helpers.log(ctx, () => "You do not have Source-File 6 or Source-File 7.");
|
||||
return false;
|
||||
}
|
||||
if (Player.bitNodeOptions.disableBladeburner) {
|
||||
helpers.log(ctx, () => "Bladeburner is disabled by advanced options.");
|
||||
return false;
|
||||
}
|
||||
if (currentNodeMults.BladeburnerRank === 0) {
|
||||
return false; // Disabled in this bitnode
|
||||
helpers.log(ctx, () => "Bladeburner is disabled in this BitNode.");
|
||||
return false;
|
||||
}
|
||||
// Already member
|
||||
if (Player.bladeburner) {
|
||||
return true; // Already member
|
||||
return true;
|
||||
}
|
||||
if (
|
||||
Player.skills.strength < 100 ||
|
||||
@@ -324,11 +329,15 @@ export function NetscriptBladeburner(): InternalAPI<INetscriptBladeburner> {
|
||||
Player.skills.dexterity < 100 ||
|
||||
Player.skills.agility < 100
|
||||
) {
|
||||
helpers.log(ctx, () => "You do not meet the requirements for joining the Bladeburner division");
|
||||
helpers.log(
|
||||
ctx,
|
||||
() =>
|
||||
"You do not meet the requirements for joining the Bladeburner division. All combat stats must be at least level 100.",
|
||||
);
|
||||
return false;
|
||||
}
|
||||
Player.startBladeburner();
|
||||
helpers.log(ctx, () => "You have been accepted into the Bladeburner division");
|
||||
helpers.log(ctx, () => "You have been accepted into the Bladeburner division.");
|
||||
|
||||
return true;
|
||||
},
|
||||
|
||||
@@ -39,9 +39,26 @@ export function NetscriptGang(): InternalAPI<IGang> {
|
||||
return {
|
||||
createGang: (ctx) => (_faction) => {
|
||||
const faction = getEnumHelper("FactionName").nsGetMember(ctx, _faction);
|
||||
if (!Player.canAccessGang() || !GangConstants.Names.includes(faction)) return false;
|
||||
if (Player.gang) return false;
|
||||
if (!Player.factions.includes(faction)) return false;
|
||||
if (Player.gang) {
|
||||
return false;
|
||||
}
|
||||
const checkResult = Player.canAccessGang();
|
||||
if (!checkResult.success) {
|
||||
helpers.log(ctx, () => checkResult.message);
|
||||
return false;
|
||||
}
|
||||
if (!GangConstants.Names.includes(faction)) {
|
||||
helpers.log(
|
||||
ctx,
|
||||
() =>
|
||||
`${faction} does not allow creating a gang. You can only do that with ${GangConstants.Names.join(", ")}.`,
|
||||
);
|
||||
return false;
|
||||
}
|
||||
if (!Player.factions.includes(faction)) {
|
||||
helpers.log(ctx, () => `You are not a member of ${faction}.`);
|
||||
return false;
|
||||
}
|
||||
|
||||
const isHacking = faction === FactionName.NiteSec || faction === FactionName.TheBlackHand;
|
||||
Player.startGang(faction, isHacking);
|
||||
|
||||
@@ -110,15 +110,19 @@ export function NetscriptStanek(): InternalAPI<IStanek> {
|
||||
acceptGift: (ctx) => () => {
|
||||
const cotmgFaction = Factions[FactionName.ChurchOfTheMachineGod];
|
||||
// Check if the player is eligible to join the church
|
||||
if (canAcceptStaneksGift()) {
|
||||
const checkResult = canAcceptStaneksGift();
|
||||
if (checkResult.success) {
|
||||
// Join the CotMG factionn
|
||||
joinFaction(cotmgFaction);
|
||||
// Install the first Stanek aug
|
||||
applyAugmentation({ name: AugmentationName.StaneksGift1, level: 1 });
|
||||
helpers.log(
|
||||
ctx,
|
||||
() => `'${FactionName.ChurchOfTheMachineGod}' joined and '${AugmentationName.StaneksGift1}' installed.`,
|
||||
() =>
|
||||
`You joined '${FactionName.ChurchOfTheMachineGod}' and have '${AugmentationName.StaneksGift1}' installed.`,
|
||||
);
|
||||
} else {
|
||||
helpers.log(ctx, () => checkResult.message);
|
||||
}
|
||||
// Return true if the player is in CotMG and has the first Stanek aug installed
|
||||
return cotmgFaction.isMember && Player.hasAugmentation(AugmentationName.StaneksGift1, true);
|
||||
|
||||
Reference in New Issue
Block a user