Commit Graph

138 Commits

Author SHA1 Message Date
omuretsu 798da75d83 renameServer changes
* Update doc error, regenerate docs
* Update a bad error message in renamePurchasedServer@serverPurchases.ts
* restore true/false return (removed in #450 due to miscommunication)
2023-03-28 16:10:24 -04:00
Snarling a774592e64 fix crash when renaming server while connected to that server (#438) 2023-03-21 21:21:15 -04:00
David Walker 98f7f473b4 NETSCRIPT: Add "temporary" as a RunOption to run/exec/spawn (#432) 2023-03-21 18:54:49 -04:00
David Walker c77b89d4d9 PERFORMANCE: Improve speed of saving when there are lots of scripts (#430) 2023-03-17 23:59:27 -04:00
Snarling 759f86d6e5 NETSCRIPT: Rework script ram updates (#408) 2023-03-05 22:39:42 -05:00
Mughur d55395491c BUGFIX: new servers check reserved names properly 2023-02-18 03:34:09 +02:00
David Walker ed59f4bfe7 NETSCRIPT: Add growThreads to formulas, improve docs for hacking functions (#330) 2023-02-14 17:38:51 -05:00
Tyasuh ac8ea6b5ef split hacknet node from server in name, with SF9 (#327) 2023-01-16 15:59:33 -05:00
Mughur 3281b785ce properly fix leading '/' script bug (#296) 2023-01-05 20:33:30 -05:00
David Walker aa32e235fa MULTS: Make BitNodeMultipliers.ServerMaxMoney more sensible (#280) 2023-01-05 20:31:54 -05:00
Mughur 1baa615def MISC: small fixes (#270)
* infiltration gain bug fix
* fix corp division description
* avoid some issues with Infinity at super high NFG levels
Co-authored-by: Daniel Perez Alvarez <danielpza@protonmail.com>
2023-01-02 13:51:59 -05:00
Snarling fb1f95c26e VARIOUS: Various changes prior to release 2.2 (#271)
See PR #271 description
2022-12-29 20:28:53 -05:00
Mughur b004b7203d GENERAL: Reorganizing and grouping node multipliers (#259) 2022-12-21 17:39:12 -05:00
Snarling 65cd14e33b DOC: Add ns documentation for possible sleeve tasks (#217)
* Add specific types for sleeve tasks
* Moved LocationName enum to overall enums file
* Add LocationName enum to those provided to player
* remove trailing s on CompanyPosNames enum (now CompanyPosName, in line with LocationName)
* Also regenerated all ns documentation. This leads to an expected error when checking for generated files, because PRs should not normally touch markdown files. Also leads to a lint failure in generated file bitburner.d.ts
* also removed some exporting from NetscriptDefinitions.d.ts for anything that wasn't imported somewhere else.
2022-11-20 12:07:22 -05:00
Snarling 8e0e0eaa88 NETSCRIPT: ns.sleeve.getSleeve added. getPlayer and getSleeve can both be used for formulas. (#200)
* BREAKING CHANGE: Removed getSleeveStats and getSleeveInformation because this info is provided by getSleeve in a more usable form.
* BREAKING CHANGE: Removed tor, inBladeburner, and hasCorporation fields from ns.getPlayer. Functionality still exists via added functions ns.hasTorRouter, ns.corporation.hasCorporation, and ns.bladeburner.inBladeburner.
* Separated ns definitions for Person, Sleeve, and Player interfaces with both Player and Sleeve just extending Person.
Added getSleeve, which provides a Sleeve object similar to getPlayer.
* Renamed the sleeve ns layer's interface as sleeve lowercase because of name conflict. todo: May move all the ns layers interface names to lowercase for consistency
* Added ns.formulas.work.crimeSuccessChance and reworked to allow both sleeve and player calculations.
* Removed internal Person.getIntelligenceBonus function which was just a wrapper for calculateIntelligenceBonus. Any use of the former in formulas creates a conflict where ns-provided Person objects throw an error.
* Renamed helpers.player to helpers.person for netscript person validation. Reduced number of fields validated due to Person being a smaller interface.
* Fixed bug in bladeburner where Player multipliers and int were being used no matter which person was performing the task
* Fixed leak of Player.jobs at ns.getPlayer
* Person / Player / Sleeve classes now implement the netscript equivalent interfaces. Netscript helper for person no longer asserts that it's a real Person class member, only that it's a Person interface. Functions that use netscript persons have been changed to expect just a person interface to prevent needing this incorrect type assertion.
2022-11-09 07:26:26 -05:00
Snarling 239834dba6 Connect to owned servers from anywhere (#159)
* purchasedByPlayer allows connect-from-anywhere as if the server was backdoored.
* Also added optional backdoorInstalled variable to type for BaseServer. This has no runtime effect, but it allows accessing that variable without TS needing us to verify whether it's instanceof Server first.
2022-10-25 17:48:46 -04:00
Olivier Gagnon cbb7f58231 Make the main player object an alias, makes it easier to import 2022-10-09 18:42:14 -04:00
Olivier Gagnon 5d4b72e1d1 Added some purchased server functions 2022-10-09 02:32:13 -04:00
Olivier Gagnon f6f023eeb4 Fix tons of typos 2022-10-09 01:25:31 -04:00
Snarling aa80cf6451 See description
Reverted ToastVariant back to an enum internally. Still exposed to player as just possible strings.
Changed all 1-line documentation comments to actually be 1-line. Moved some because they were not providing documentation for the thing they were trying to.
2022-10-04 06:40:10 -04:00
Snarling 50f14b4f58 Commit1 2022-10-03 12:12:16 -04:00
Snarling 38063f62a7 build fix, lint, remove some instanceof checks 2022-09-27 16:09:32 -04:00
Snarling c510e47885 Player is now a Person
Use correct class inheritance, use class as type and remove IPlayer
2022-09-27 15:35:41 -04:00
Snarling 21a2d49de7 Finish removing player passing 2022-09-27 15:35:41 -04:00
Snarling 83d357e758 commit1 2022-09-27 15:35:40 -04:00
Snarling 572c68738f Unify error handling 2022-09-27 15:34:47 -04:00
Olivier Gagnon 6390f3618e Added few augs 2022-09-23 12:05:16 -04:00
Olivier Gagnon fb197be206 Fix hostname generation being weird about dash 0 added 2022-09-23 12:04:21 -04:00
Shiiyu e1bff8bcb1 fix: 🐛 fix server minimum difficulty changing when server starting difficulty is capped 2022-09-23 02:39:58 -04:00
Shiiyu cf11612abc style: 🎨 fix - forgot to run format first 2022-09-23 02:07:32 -04:00
Shiiyu ecaa906682 fix: 🐛 fix server starting security going above 100 2022-09-23 00:42:47 -04:00
hydroflame 9946a2a667 Merge pull request #3841 from crimsonhawk47/fix-ip-exists-function
BUGFIX: Fix #3803 Servers can no longer have duplicate IPs
2022-07-21 01:33:35 -04:00
Olivier Gagnon 810f3a87b9 rm more anys 2022-07-19 21:53:43 -04:00
Olivier Gagnon 55c5190986 fix any in BaseServer 2022-07-18 03:20:11 -04:00
Olivier Gagnon 7195c1b540 fix any in AllServers 2022-07-18 03:06:17 -04:00
Olivier Gagnon 88d9a76b04 yet another any 2022-07-18 02:43:59 -04:00
Olivier Gagnon 6b630753f0 nuke some use of any 2022-07-14 19:00:10 -04:00
Olivier Gagnon 5629c16def extract multipliers in its own type 2022-07-14 18:43:33 -04:00
Olivier Gagnon 606f1bf6c4 create program and grafting done 2022-07-10 01:37:36 -04:00
Olivier Gagnon 647392626e convert taking class ot new work system 2022-07-07 17:28:23 -04:00
Gabriel Hawk 60c6536f8e npm format 2022-06-13 01:13:36 -05:00
Gabriel Hawk 1e2e42af75 ipExists acceses server list correctly 2022-06-13 01:07:21 -05:00
Olivier Gagnon 9af553f63c Fix 2022-05-19 02:09:00 -04:00
Olivier Gagnon f1a3fb7d3e fix buying programs and writing them at the same time. 2022-04-13 00:21:51 -04:00
Olivier Gagnon 48f80f25d6 fmt and lint 2022-04-06 19:30:08 -04:00
Olivier Gagnon 4d9a8e7bba unknown-ify coding contract API. 2022-03-29 20:29:05 -04:00
hydroflame 290f36b600 Merge pull request #2881 from dwRchyngqxs/reverse_grow_newton
growthAnalyze (choice 2 / documented math) - only merge one of these
2022-03-20 21:40:02 -04:00
hydroflame 15fae213ab Merge pull request #2872 from SagePtr/getserver-hasownproperty
Add hasOwnProperty check to GetServer
2022-03-20 21:16:04 -04:00
phyzical 44ea479043 update constants
* added OperationNames
* added faction names
* used citynames where appropriate
2022-03-19 16:09:59 +08:00
hydroflame 561219a0ab Merge branch 'dev' into bugfix/2877-2 2022-03-17 12:05:38 -04:00