DARKNET: Add improved challenge achievement for BN15 (#2479)

* DARKNET: Add improved challenge achievement for BN15

* DARKNET: Adjust heartbleed check location for achievement

* Fix wrong achievement data and update svg

* DARKNET: Fix styling of documentation link

* lint

---------

Co-authored-by: CatLover <152669316+catloversg@users.noreply.github.com>
This commit is contained in:
Michael Ficocelli
2026-02-07 21:28:55 -05:00
committed by GitHub
parent 95d08d7722
commit e649adfef4
8 changed files with 155 additions and 5 deletions

View File

@@ -0,0 +1,63 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="256"
height="256"
viewBox="0 0 67.733325 67.733325"
version="1.1"
id="svg5"
inkscape:version="1.4 (86a8ad7, 2024-10-11)"
sodipodi:docname="darknet-depths.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview7"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:document-units="mm"
showgrid="true"
units="px"
inkscape:current-layer="layer1"
inkscape:showpageshadow="2"
inkscape:deskcolor="#d1d1d1">
<inkscape:grid
type="xygrid"
id="grid1"
originx="0"
originy="0"
spacingy="1"
spacingx="1"
units="px" />
</sodipodi:namedview>
<defs
id="defs2" />
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="background">
<rect
style="fill:#000000;stroke:none;stroke-width:7.02745"
id="rect1"
width="67.73333"
height="67.73333"
x="0"
y="0" />
</g>
<g
inkscape:label="main"
inkscape:groupmode="layer"
id="layer1">
<path
style="font-weight:bold;font-size:17.6389px;line-height:1.25;font-family:Arial;-inkscape-font-specification:'Arial Bold';text-align:center;text-anchor:middle;fill:#00ff00;stroke-width:0.264583"
d="m 43.771318,28.190869 -5.055681,5.055681 h 2.57521 v 1.240235 q 0,0.809598 -0.18948,1.584745 -0.180868,0.775147 -0.542603,1.498617 l 1.248848,1.248848 q 0.404799,0 0.757922,0.15503 0.361735,0.155029 0.62873,0.422024 0.266995,0.266995 0.422024,0.620118 0.15503,0.353122 0.15503,0.766534 0,0.396186 -0.15503,0.749309 -0.146416,0.361735 -0.422024,0.637343 l -1.024917,1.024917 q -0.275607,0.275607 -0.637343,0.422024 -0.353122,0.155029 -0.749309,0.155029 -0.404799,0 -0.766534,-0.155029 Q 39.663039,43.461265 39.396044,43.19427 39.129049,42.927274 38.974019,42.565539 38.81899,42.212417 38.81899,41.807618 L 37.570142,40.55877 q -0.551216,0.275608 -1.042142,0.422024 -0.490927,0.15503 -0.981853,0.223932 -0.490927,0.0689 -0.999079,0.07751 -0.508151,0.01723 -1.093818,0.01723 h -0.206706 q -0.809598,0 -1.584745,-0.189481 -0.775147,-0.18948 -1.498618,-0.551215 l -1.248847,1.248848 q 0,0.413411 -0.15503,0.766534 -0.155029,0.353122 -0.422024,0.611505 -0.258383,0.266995 -0.620118,0.413412 -0.353122,0.155029 -0.766534,0.155029 -0.387574,0 -0.749309,-0.146417 -0.361735,-0.137804 -0.637343,-0.413411 -0.258382,-0.24977 -0.516765,-0.508152 -0.249769,-0.258383 -0.508152,-0.516765 -0.275607,-0.275608 -0.430637,-0.637343 -0.146417,-0.353123 -0.146417,-0.749309 0,-0.404799 0.15503,-0.757921 0.155029,-0.361736 0.422024,-0.628731 0.266995,-0.266995 0.620118,-0.422024 0.361735,-0.15503 0.766534,-0.15503 l 1.248848,-1.248848 q -0.275608,-0.551215 -0.430637,-1.042142 -0.146417,-0.490926 -0.215319,-0.981853 -0.0689,-0.490926 -0.08613,-0.999078 -0.0086,-0.508152 -0.0086,-1.093819 V 33.24655 h 2.583823 l -5.055681,-5.055681 v -4.228858 h 4.228858 l 5.675799,5.675799 5.675798,-5.675799 h 4.228858 z m -1.240235,-2.988623 h -2.471858 q -2.463245,2.463245 -4.935103,4.917877 -2.471857,2.454633 -4.917877,4.935103 0.08613,0.465088 0.310059,0.8785 0.223931,0.413412 0.542603,0.740696 0.327284,0.318671 0.740696,0.542603 0.413412,0.223931 0.8785,0.310059 2.471858,-2.454633 4.92649,-4.917877 2.463245,-2.471858 4.92649,-4.935103 z m -11.575529,8.225171 2.471858,-2.471857 -5.753314,-5.753314 h -2.471857 v 2.471858 z m 9.103671,1.059368 h -1.860353 q 0,0.766534 -0.292833,1.446941 -0.284221,0.671794 -0.792373,1.179946 -0.499539,0.499539 -1.179946,0.792372 -0.671794,0.292834 -1.446941,0.292834 v 1.860353 q 1.154108,0 2.170412,-0.430638 1.016304,-0.43925 1.765612,-1.197171 0.757922,-0.757922 1.197172,-1.774226 0.43925,-1.016303 0.43925,-2.170411 z m -12.385127,0 q 0,0.766534 0.198093,1.481392 0.198094,0.714858 0.559829,1.334975 0.370348,0.611505 0.8785,1.119657 0.508152,0.508152 1.119657,0.8785 0.620117,0.361735 1.334975,0.559828 0.714858,0.198094 1.481392,0.198094 v -1.860353 q -0.766534,0 -1.446941,-0.292834 -0.671794,-0.292833 -1.179946,-0.792372 -0.499539,-0.508152 -0.792373,-1.179946 -0.292833,-0.680407 -0.292833,-1.446941 z m 9.103671,-0.180868 -2.471857,2.471858 0.749308,0.749309 q 0.465089,-0.08613 0.8785,-0.310059 0.413412,-0.223932 0.732084,-0.542603 0.327284,-0.327284 0.551215,-0.740696 0.223932,-0.413412 0.310059,-0.8785 z m 3.281456,7.501701 q 0,0.301446 0.206706,0.508152 0.206706,0.215318 0.508152,0.215318 0.310059,0 0.516764,-0.206706 0.258383,-0.249769 0.516765,-0.508152 0.266995,-0.258382 0.516765,-0.516764 0.206706,-0.223932 0.206706,-0.516765 0,-0.310059 -0.215319,-0.516765 -0.206706,-0.206705 -0.508152,-0.206705 -0.103353,0 -0.206706,0.02584 -0.103353,0.02584 -0.18948,0.08613 -0.03445,0.02584 -0.137804,0.111966 -0.09474,0.09474 -0.232544,0.223931 -0.129191,0.129191 -0.275608,0.275608 -0.146417,0.146417 -0.275608,0.275608 -0.120578,0.129191 -0.215318,0.223931 -0.08613,0.103353 -0.103353,0.129191 -0.06029,0.08613 -0.08613,0.189481 -0.02584,0.103353 -0.02584,0.206706 z M 25.934324,40.059231 q -0.301446,0 -0.516765,0.206705 -0.215318,0.215319 -0.215318,0.516765 0,0.120578 0.04306,0.24977 0.04306,0.137804 0.137804,0.232544 l 1.050755,1.059367 q 0.206706,0.206706 0.516765,0.206706 0.146416,0 0.275608,-0.06029 0.137804,-0.05168 0.232544,-0.146417 0.103353,-0.09474 0.155029,-0.223931 0.06029,-0.129191 0.06029,-0.284221 0,-0.28422 -0.198093,-0.499539 -0.08613,-0.09474 -0.241157,-0.258382 -0.155029,-0.163642 -0.327284,-0.34451 -0.172255,-0.172255 -0.335897,-0.327284 -0.155029,-0.146417 -0.24977,-0.215319 -0.07751,-0.06029 -0.18948,-0.08613 -0.103353,-0.02584 -0.198093,-0.02584 z m 13.504783,-1.860353 q -0.53399,0.714857 -1.240235,1.240235 l 1.533069,1.533068 q 0.05168,-0.07751 0.223931,-0.258382 0.172255,-0.180868 0.370348,-0.378961 0.206706,-0.198093 0.387574,-0.370348 0.180867,-0.180867 0.258382,-0.232544 z m -9.904656,1.240235 q -0.714858,-0.525378 -1.240235,-1.240235 l -1.533069,1.533068 q 0.07752,0.05168 0.258383,0.232544 0.180867,0.172255 0.378961,0.370348 0.198093,0.198093 0.370348,0.378961 0.180867,0.180868 0.232544,0.258382 z"
id="text1"
aria-label="⚔️" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 6.4 KiB

View File

@@ -0,0 +1,63 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="256"
height="256"
viewBox="0 0 67.733325 67.733325"
version="1.1"
id="svg5"
inkscape:version="1.4 (86a8ad7, 2024-10-11)"
sodipodi:docname="darknet-depths.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview7"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:document-units="mm"
showgrid="true"
units="px"
inkscape:current-layer="layer1"
inkscape:showpageshadow="2"
inkscape:deskcolor="#d1d1d1">
<inkscape:grid
type="xygrid"
id="grid1"
originx="0"
originy="0"
spacingy="1"
spacingx="1"
units="px" />
</sodipodi:namedview>
<defs
id="defs2" />
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="background">
<rect
style="fill-opacity: 0%;stroke:none;stroke-width:7.02745"
id="rect1"
width="67.73333"
height="67.73333"
x="0"
y="0" />
</g>
<g
inkscape:label="main"
inkscape:groupmode="layer"
id="layer1">
<path
style="font-weight:bold;font-size:17.6389px;line-height:1.25;font-family:Arial;-inkscape-font-specification:'Arial Bold';text-align:center;text-anchor:middle;fill:#000000;stroke-width:0.264583"
d="m 43.771318,28.190869 -5.055681,5.055681 h 2.57521 v 1.240235 q 0,0.809598 -0.18948,1.584745 -0.180868,0.775147 -0.542603,1.498617 l 1.248848,1.248848 q 0.404799,0 0.757922,0.15503 0.361735,0.155029 0.62873,0.422024 0.266995,0.266995 0.422024,0.620118 0.15503,0.353122 0.15503,0.766534 0,0.396186 -0.15503,0.749309 -0.146416,0.361735 -0.422024,0.637343 l -1.024917,1.024917 q -0.275607,0.275607 -0.637343,0.422024 -0.353122,0.155029 -0.749309,0.155029 -0.404799,0 -0.766534,-0.155029 Q 39.663039,43.461265 39.396044,43.19427 39.129049,42.927274 38.974019,42.565539 38.81899,42.212417 38.81899,41.807618 L 37.570142,40.55877 q -0.551216,0.275608 -1.042142,0.422024 -0.490927,0.15503 -0.981853,0.223932 -0.490927,0.0689 -0.999079,0.07751 -0.508151,0.01723 -1.093818,0.01723 h -0.206706 q -0.809598,0 -1.584745,-0.189481 -0.775147,-0.18948 -1.498618,-0.551215 l -1.248847,1.248848 q 0,0.413411 -0.15503,0.766534 -0.155029,0.353122 -0.422024,0.611505 -0.258383,0.266995 -0.620118,0.413412 -0.353122,0.155029 -0.766534,0.155029 -0.387574,0 -0.749309,-0.146417 -0.361735,-0.137804 -0.637343,-0.413411 -0.258382,-0.24977 -0.516765,-0.508152 -0.249769,-0.258383 -0.508152,-0.516765 -0.275607,-0.275608 -0.430637,-0.637343 -0.146417,-0.353123 -0.146417,-0.749309 0,-0.404799 0.15503,-0.757921 0.155029,-0.361736 0.422024,-0.628731 0.266995,-0.266995 0.620118,-0.422024 0.361735,-0.15503 0.766534,-0.15503 l 1.248848,-1.248848 q -0.275608,-0.551215 -0.430637,-1.042142 -0.146417,-0.490926 -0.215319,-0.981853 -0.0689,-0.490926 -0.08613,-0.999078 -0.0086,-0.508152 -0.0086,-1.093819 V 33.24655 h 2.583823 l -5.055681,-5.055681 v -4.228858 h 4.228858 l 5.675799,5.675799 5.675798,-5.675799 h 4.228858 z m -1.240235,-2.988623 h -2.471858 q -2.463245,2.463245 -4.935103,4.917877 -2.471857,2.454633 -4.917877,4.935103 0.08613,0.465088 0.310059,0.8785 0.223931,0.413412 0.542603,0.740696 0.327284,0.318671 0.740696,0.542603 0.413412,0.223931 0.8785,0.310059 2.471858,-2.454633 4.92649,-4.917877 2.463245,-2.471858 4.92649,-4.935103 z m -11.575529,8.225171 2.471858,-2.471857 -5.753314,-5.753314 h -2.471857 v 2.471858 z m 9.103671,1.059368 h -1.860353 q 0,0.766534 -0.292833,1.446941 -0.284221,0.671794 -0.792373,1.179946 -0.499539,0.499539 -1.179946,0.792372 -0.671794,0.292834 -1.446941,0.292834 v 1.860353 q 1.154108,0 2.170412,-0.430638 1.016304,-0.43925 1.765612,-1.197171 0.757922,-0.757922 1.197172,-1.774226 0.43925,-1.016303 0.43925,-2.170411 z m -12.385127,0 q 0,0.766534 0.198093,1.481392 0.198094,0.714858 0.559829,1.334975 0.370348,0.611505 0.8785,1.119657 0.508152,0.508152 1.119657,0.8785 0.620117,0.361735 1.334975,0.559828 0.714858,0.198094 1.481392,0.198094 v -1.860353 q -0.766534,0 -1.446941,-0.292834 -0.671794,-0.292833 -1.179946,-0.792372 -0.499539,-0.508152 -0.792373,-1.179946 -0.292833,-0.680407 -0.292833,-1.446941 z m 9.103671,-0.180868 -2.471857,2.471858 0.749308,0.749309 q 0.465089,-0.08613 0.8785,-0.310059 0.413412,-0.223932 0.732084,-0.542603 0.327284,-0.327284 0.551215,-0.740696 0.223932,-0.413412 0.310059,-0.8785 z m 3.281456,7.501701 q 0,0.301446 0.206706,0.508152 0.206706,0.215318 0.508152,0.215318 0.310059,0 0.516764,-0.206706 0.258383,-0.249769 0.516765,-0.508152 0.266995,-0.258382 0.516765,-0.516764 0.206706,-0.223932 0.206706,-0.516765 0,-0.310059 -0.215319,-0.516765 -0.206706,-0.206705 -0.508152,-0.206705 -0.103353,0 -0.206706,0.02584 -0.103353,0.02584 -0.18948,0.08613 -0.03445,0.02584 -0.137804,0.111966 -0.09474,0.09474 -0.232544,0.223931 -0.129191,0.129191 -0.275608,0.275608 -0.146417,0.146417 -0.275608,0.275608 -0.120578,0.129191 -0.215318,0.223931 -0.08613,0.103353 -0.103353,0.129191 -0.06029,0.08613 -0.08613,0.189481 -0.02584,0.103353 -0.02584,0.206706 z M 25.934324,40.059231 q -0.301446,0 -0.516765,0.206705 -0.215318,0.215319 -0.215318,0.516765 0,0.120578 0.04306,0.24977 0.04306,0.137804 0.137804,0.232544 l 1.050755,1.059367 q 0.206706,0.206706 0.516765,0.206706 0.146416,0 0.275608,-0.06029 0.137804,-0.05168 0.232544,-0.146417 0.103353,-0.09474 0.155029,-0.223931 0.06029,-0.129191 0.06029,-0.284221 0,-0.28422 -0.198093,-0.499539 -0.08613,-0.09474 -0.241157,-0.258382 -0.155029,-0.163642 -0.327284,-0.34451 -0.172255,-0.172255 -0.335897,-0.327284 -0.155029,-0.146417 -0.24977,-0.215319 -0.07751,-0.06029 -0.18948,-0.08613 -0.103353,-0.02584 -0.198093,-0.02584 z m 13.504783,-1.860353 q -0.53399,0.714857 -1.240235,1.240235 l 1.533069,1.533068 q 0.05168,-0.07751 0.223931,-0.258382 0.172255,-0.180868 0.370348,-0.378961 0.206706,-0.198093 0.387574,-0.370348 0.180867,-0.180867 0.258382,-0.232544 z m -9.904656,1.240235 q -0.714858,-0.525378 -1.240235,-1.240235 l -1.533069,1.533068 q 0.07752,0.05168 0.258383,0.232544 0.180867,0.172255 0.378961,0.370348 0.198093,0.198093 0.370348,0.378961 0.180867,0.180868 0.232544,0.258382 z"
id="text1"
aria-label="⚔️" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 6.4 KiB

View File

@@ -416,6 +416,11 @@
"Name": "Make your Own Network",
"Description": "Install a backdoor on 50 or more darknet servers at once."
},
"DARKNET_DEPTHS": {
"ID": "DARKNET_DEPTHS",
"Name": "Into the Depths",
"Description": "Install the augment from the deepest server."
},
"CHALLENGE_BN1": {
"ID": "CHALLENGE_BN1",
"Name": "BN1: Challenge",
@@ -474,7 +479,7 @@
"CHALLENGE_BN15": {
"ID": "CHALLENGE_BN15",
"Name": "BN15: Challenge",
"Description": "Open the cache on the final lab in the darknet."
"Description": "Complete BN15 without ever calling dnet.heartbleed."
},
"BYPASS": {
"ID": "BYPASS",

View File

@@ -38,6 +38,7 @@ import { Go } from "../Go/Go";
import { type AchievementId, type SFAchievementId, SFAchievementIds } from "./Types";
import { getAllMovableDarknetServers } from "../DarkNet/utils/darknetNetworkUtils";
import { DarknetState } from "../DarkNet/models/DarknetState";
function assertAchievements(
achievements: typeof data.achievements,
@@ -591,6 +592,13 @@ export const achievements: Record<AchievementId, Achievement> = {
Condition: () => getAllMovableDarknetServers().filter((s) => s.backdoorInstalled).length >= 50,
NotInSteam: true,
},
DARKNET_DEPTHS: {
...achievementData.DARKNET_DEPTHS,
Icon: "darknet-depths",
Visible: knowAboutBitverse,
Condition: () => Player.augmentations.some((a) => a.name === AugmentationName.TheSword),
NotInSteam: true,
},
CHALLENGE_BN1: {
...achievementData.CHALLENGE_BN1,
Icon: "BN1+",
@@ -685,7 +693,7 @@ export const achievements: Record<AchievementId, Achievement> = {
...achievementData.CHALLENGE_BN15,
Icon: "BN15+",
Visible: knowAboutBitverse,
Condition: () => Player.augmentations.some((a) => a.name === AugmentationName.TheSword),
Condition: () => Player.bitNodeN === 15 && isBitNodeFinished() && !DarknetState.hasUsedHeartbleed,
NotInSteam: true,
},
BYPASS: {

View File

@@ -3,11 +3,13 @@ import { assertObject } from "../../utils/TypeAssertion";
export type DarknetSaveFormat = {
storedCycles: number;
hasUsedHeartbleed: boolean;
};
export function getDarkNetSave(): DarknetSaveFormat {
return {
storedCycles: Math.floor(DarknetState.storedCycles),
hasUsedHeartbleed: DarknetState.hasUsedHeartbleed,
};
}
@@ -18,11 +20,12 @@ export function loadDarkNet(saveString: unknown): void {
try {
const parsedData: unknown = JSON.parse(saveString);
assertObject(parsedData);
const { storedCycles } = parsedData;
const { storedCycles, hasUsedHeartbleed } = parsedData;
if (typeof storedCycles !== "number" || !Number.isFinite(storedCycles)) {
throw new Error(`Invalid storedCycles: ${storedCycles}`);
}
DarknetState.storedCycles = storedCycles < 0 ? 0 : storedCycles;
DarknetState.hasUsedHeartbleed = Boolean(hasUsedHeartbleed);
} catch (error) {
console.error(error);
console.error("Invalid DarkNet data:", saveString);

View File

@@ -28,6 +28,7 @@ export const DarknetState = {
nextMutation: Promise.resolve(),
nextMutationResolver: null as (() => void) | null,
storedCycles: 0,
hasUsedHeartbleed: false,
cyclesSinceLastMutation: 0,
Network: new Array(MAX_NET_DEPTH).fill(null).map(() => new Array<DarknetServer | null>(NET_WIDTH).fill(null)),

View File

@@ -15,7 +15,7 @@ import { useRerender } from "../../ui/React/hooks";
import { DarknetEvents, DarknetState } from "../models/DarknetState";
import { SpecialServers } from "../../Server/data/SpecialServers";
import { drawOnCanvas, getPixelPosition } from "./networkCanvas";
import { dnetStyles } from "./dnetStyles";
import { dnetStyles, DWServerLogStyles } from "./dnetStyles";
import { getLabyrinthDetails, isLabyrinthServer } from "../effects/labyrinth";
import { DarknetServer } from "../../Server/DarknetServer";
import { getAllDarknetServers } from "../utils/darknetNetworkUtils";
@@ -358,7 +358,12 @@ export function NetworkDisplayWrapper(): React.ReactElement {
</Typography>
<DocumentationLink
page="programming/darknet.md"
style={{ fontSize: "22px", padding: "0 20px", backgroundColor: Settings.theme.button }}
style={{
...DWServerLogStyles,
fontSize: "18px",
padding: "2px 20px",
backgroundColor: Settings.theme.button,
}}
>
Darknet Docs
</DocumentationLink>

View File

@@ -247,6 +247,7 @@ export function NetscriptDarknet(): InternalAPI<DarknetAPI> {
logger(ctx)(
`Attempting to extract data from ${server.hostname}... (Est: ${formatNumber(networkDelay / 1000, 1)}s)`,
);
DarknetState.hasUsedHeartbleed = true;
if (Player.skills.charisma < server.requiredCharismaSkill) {
logger(ctx)(
@@ -263,6 +264,7 @@ export function NetscriptDarknet(): InternalAPI<DarknetAPI> {
return helpers.netscriptDelay(ctx, networkDelay).then(() => {
const xpGained = Player.mults.charisma_exp * 50 * ((500 + Player.skills.charisma) / 500);
Player.gainCharismaExp(xpGained);
const onlineConnectionCheck = getFailureResult(ctx, targetHost, { requireDirectConnection: true });
if (!onlineConnectionCheck.success) {
return {