下载客户端

前期游戏进程指南(无剧透)

2026-02-15 13:00:07
发布在Bitburner
转载

AI智能总结导读

这是《Bitburner》无剧透前期进程指南,核心围绕黑客脚本优化与服务器破解展开。介绍了改用Netscript2提升脚本性能、拆分脚本优化RAM占用、集中控制脚本等黑客脚本优化方法,还提及用扫描脚本批量破解服务器的技巧,助力玩家高效推进游戏。

Finished the tutorial and wondering how to progress? Want to improve your hacking script or maybe you want to start automating other parts of the game? This is a spoiler free guide that points you in the right direction. Hacking scripts: How to improve 1: Follow the tutorial In addition the the ingame tutorial, there's a good guide on how to get a decent hacking script started in the online documentation[bitburner.readthedocs.io]. At this point you have a script that will continuously weaken, grow and hack a given server. You might think it's slow (and you'd be right) and that's because there are several improvements you can make. The first step is to start using netscript2[bitburner.readthedocs.io]. Netscript 1, or .script files which are used in the tutorial, are slow and low on features. Netscript2 is very close to modern javascript, and their speed is only limited by your computer. Note that speed here refers to the execution time, not how fast your weaken() grow() and hack() functions run - that is determined by hacking skill. When writing scripts you might notice that their ram requirements increase as you use more ns functions. Since only weaken() grow() and hack() benefit from using additional threads, separating them from everything else will let you run more threads and thus gain a higher payoff. At this point it's worth having the API documentation[bitburner.readthedocs.io] handy. Separating our hacking scripts to optimize ram usageTo let us run our important functions with as many threads as possible, figure out how to make the simplest possible script that will run only weaken() on a target given by argument and nothing more. Then take your hacking script from the tutorial, and instead of running weaken() directly, find a way to run the weaken script and passing the target to it as an argument, using as many threads as free ram allows. Then, find a way to wait until it finishes. Repeat this process for grow() and hack(). Because we now only use a small fraction of our RAM on control with 1 thread, we can spend the entire rest of our RAM on running the functions that actually care about threads, with as many threads as possible. This can more than double your income. Centralizing controlIf you deploy this hacking script to each server you have root on, you should be progressing quite well. But if we analyze ram usage on our rooted servers, we see that the actual weaken.ns, grow.ns and hack.ns scripts don't use all the available ram because the control script takes up quite a chunk. But if we are just attacking the most profitable target with all of these servers of ours anyway, why not stick to a single control script on one server and let it control the others? The goal here is to write a control script that we run on our home computer, which can spawn weaken.ns grow.ns and hack.ns on other servers - leaving us with all their memory free for doing important jobs. If the control script takes approximately twice the ram of a single thread of weaken.ns, grow.ns or hack.ns, we get 2 additional threads on each of our rooted servers for free by using this technique. In the early game when most of your ram comes from random servers you've rooted, this can count for quite an increase. Simultaneous executionIn general for optimizations, it's important to measure what parts of our algorithms has the longest impact on performance. Let's assume we've gotten to the point where a server is prepped (min security and max money reached) so that our loop is approximately weaken -> grow -> weaken -> hack. Start by printing to log the time spent on each step. In my case, the obvious time sink was the weaken directly after grow, because the grow increased security significantly. What if we could start weakening while the grow is in progress, thus doing the tasks in parallel? We actually can: The time taken by weaken(), grow() and hack() is calculated by the server and player status at the start of the operation. The effect happens at the end. Thus, if we start our weaken before the grow finishes, it will be way faster. Figure out a way to see how long weaken() and grow() will take (hint: the documentation[github.com] has functions for this). Then instead of using all available memory for starting grow, use half. Then start weaken with the other half. If weaken would run faster, you need to sleep your script a bit before you run weaken. Note that the optimal split is likely far from 50/50. You can either experiment with the ratio, or use the analyze functions from the documentation[github.com] to calculate the optimal split so that the weaken has just enough power to counteract the effect of the grow. Further optimizationgrow() grows the server by a certain % of it's current money. Ideally, we want to make sure that a single grow() will bring it back up to full. Find a way to calculate how many threads of hack and grow you need to keep the cycle short. The last and hardest optimization to consider is to batch an entire cycle and launch them simultaneously, so that hack() grow() and weaken() all hit within a short time of eachoter. If you manage this, you can take great advantage of larger servers in the later game, because a single full-threaded hack will remove all money, leaving you a long time to rebuild it's stash. If you instead queue several batches of scripts that all hit after one another and steal a smaller % of the money, you gain a lot more money over time per GB ram than otherwise. This last optimization however is a non trivial problem, and requires extensive planning, analysis and refactoring to get right. Finding and cracking servers: Get more ram for attacking or a juicier target If you'we followed the tutorial, you have a script that will check a few hardcoded servers and crack them. Instead of relying on hardcoded lists, make a script that runs scan()[github.com] and does a breadth-first-search[en.wikipedia.org] to generate a list of every server in the game. Then you can loop continuously (say once every ten seconds) with sleep()[github.com], and loop through the list, running any available port openers and NUKE.exe if you can - there are functions to check if you have enough ports[github.com] and hacking skill[github.com]. Once a server is cracked, you can decide what to do with it: An easy first step is to ns.tprint()[github.com] the name of the server so you are aware. Another is to copy[github.com] and run[github.com] hacking scripts to it so it can immediately start gaining you money. A third is to make a ranking of all possible hacking targets, sort them by some metric and either print the result, or redirect all your servers to hack the new target if it is better than your old one. A simple heuristic is max money[github.com] divided by min security[github.com]. A more precise one is max money divided by time it would take to hack, grow back and weaken down, functions for which can be found in the documentation[github.com]. Other mechanics Coming soon: Guides to hacknet, stock market and more.

评论

共0条评论
face
inputImg
相关阅读
最新更新

Bitburner中文指南

从入门到入不了门,深入浅出教你如何用正确的姿势玩比特币燃烧者(雾) 前言 游戏十分硬核,如果对编程不感兴趣那么游戏将会变得十分无聊。 游戏没有中文,对应文档也没…

2026-02-15 19:000赞 · 0评论

Bitburner→脚本→自动化

==Une série de scripts utiles pour automatiser un peu tout et n'importe quoi== �…

2026-02-15 22:000赞 · 0评论

调整用户界面

想要用户界面提供更多实用功能?自己动手制作吧! 我会展示一个我制作的文件资源管理器窗口示例(你知道的,就是用于处理文件的图形用户界面,类似Windows资源管理…

2026-02-15 19:000赞 · 0评论

《比特燃烧者》新手黑客指南

A short & comprehensive guide including simple working scripts for beginning…

2026-02-15 22:000赞 · 0评论

大D病毒

This details the most dangerous exploit ever discovered by the bitburner communi…

2026-02-15 19:000赞 · 0评论

奇库的从零到中后期游戏进程指南(2026年更新版)

我是Chiku,我喜欢帮助其他人享受这款游戏。 第一次玩《地牢守护者》时,甚至现在看到别人被带飞或者自己尝试推进游戏时,都很难弄清楚自己能做什么、不能做什么,也…

2026-04-03 04:000赞 · 0评论

Bitburner 新手合约指南

A short guide and simple working scripts for solving Bitburner Coding Contracts.…

2026-02-16 04:000赞 · 0评论

为HUD(平视显示器)添加自定义数据

使用内置的隐藏钩子和少量脚本自定义你的状态显示界面。 探索发现 本游戏鼓励你超越用户界面和文档进行探索。你可以检查文档对象模型,甚至查看源代码本身。当你开始跳出…

2026-02-16 01:000赞 · 0评论
暂无更多

最新更新

  • Bitburner 新手合约指南 — A short guide and simple working scripts for solving Bitburner Coding Contracts.…
  • Bitburner 新手脚本指南 — 这是我为《网络黑客》创建/找到的中级脚本集合。它们基于我之前指南中的许多脚本。 查找元数据 元数据基本上是无法通过数据库或数学函数推导的数据。我构建了一个元数据…
  • 为HUD(平视显示器)添加自定义数据 — 使用内置的隐藏钩子和少量脚本自定义你的状态显示界面。 探索发现 本游戏鼓励你超越用户界面和文档进行探索。你可以检查文档对象模型,甚至查看源代码本身。当你开始跳出…
  • 我的《网络骇客》新手笔记、批处理脚本与部署方案 — Useful for beginners, this guide provides: -The Tutorial Commands in order -Cont…
  • 派系与强化 — I asked for this. ㅤ * acquired only from this faction, grafting and certain gang…
  • 基础黑客网络管理器 — 一个用于管理你的黑客网络的基础代码,同时尽量避免花费过多资金 使用方法: 创建一个.js文件或.ns文件,这两种都可以,.script文件使用不同的标准,所以不…
  • 实用脚本【备份】 — I need some place to keep my very useful scripts. Feel free to copy them! Some o…
  • 简易黑客网络管理器 — 一个简单的黑客网络管理器,可高效为你购买所有黑客网络升级。 设置步骤: 1. 创建一个.js文件并粘贴以下代码 2. 输入命令:nano nameOfYourF…
  • 一些实用的别名 — 早期游戏中的一些实用别名 别名 正如游戏内帮助所述,别名功能允许用一个字符串替换另一个单词。游戏还提供了示例:alias "nuke=run NUKE.exe"…
  • 《比特燃烧者》新手黑客指南 — A short & comprehensive guide including simple working scripts for beginning…