![]() Then, find a way to wait until it finishes. 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. To let us run our important functions with as many threads as possible, figure out how to make the simplest possible script that will run weaken() on a target given by argument and nothing more. Separating our hacking scripts to optimize ram usage Since only weaken() grow() and hack() benefit from using additional threads, having each one in a separate script will reduce the ram cost of using additional threads and thus increase our hacking gains a lot.Īt this point it’s worth having the API documentation – handy. When writing scripts you might notice that their ram requirements increase as you use more ns functions. 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. Netscript2 is very close to modern javascript, and their speed is only limited by your computer. ![]() script files which are used in the tutorial, are slow and low on features. The first step is to start using netscript2 – . You might think it’s slow (and you’d be right) and that’s because there are several improvements you can make. In addition the the ingame tutorial, there’s a good guide on how to get a decent hacking script started in the online documentation – .Īt this point you have a script that will continuously weaken, grow and hack a given server. Hacking scripts: How to improve 1: Follow the tutorial This is a spoiler free guide that points you in the right direction. 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?
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |