Commit Graph

91 Commits

Author SHA1 Message Date
Snarling fb1f95c26e VARIOUS: Various changes prior to release 2.2 (#271)
See PR #271 description
2022-12-29 20:28:53 -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
omuretsu 8837c01d21 Tolerate & recover from null player money 2022-10-25 14:56:47 -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 81412db02e format & lint fix 2022-09-27 16:09:32 -04:00
Snarling b364cdf734 Rebase fix, move hasAugmentation to Person 2022-09-27 16:08:52 -04:00
Snarling 6e3a6be106 Remove some redundant typing 2022-09-27 15:35:42 -04:00
Snarling bc7c15ad77 corp: classes are types 2022-09-27 15:35:42 -04:00
Snarling 557bc12562 More classes as types 2022-09-27 15:35:42 -04:00
Snarling 2213d06159 Using bladeburner and action classes as types 2022-09-27 15:35:41 -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 e578bd7681 Remove IPlayer interface
Use PlayerObject instead when referring to the type of "The Player."
2022-09-27 15:35:41 -04:00
Olivier Gagnon f78c0d6a6d Fix intelligence bugf 2022-08-15 09:38:10 -04:00
Olivier Gagnon 326d9fd7ef Move player skills and exp to their struct 2022-07-26 23:54:17 -04:00
Olivier Gagnon 810f3a87b9 rm more anys 2022-07-19 21:53:43 -04:00
Olivier Gagnon bb8af88b77 prep v2 2022-07-19 14:21:12 -04:00
Olivier Gagnon 4bee746576 rm any 2022-07-15 01:51:30 -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 0550bc188c refactor some stuff 2022-07-14 17:43:08 -04:00
Olivier Gagnon fac6633347 remove so many fields and values used by the old system 2022-07-12 23:13:40 -04:00
Olivier Gagnon 2d73f546b0 lint and remove unused var 2022-07-12 01:59:23 -04:00
Olivier Gagnon f7805c4a51 convert faction work to new work system 2022-07-12 01:54:19 -04:00
Olivier Gagnon e86a42716c lint 2022-07-11 15:58:23 -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
Olivier Gagnon 3ee7d593d0 Convert crime to new work model 2022-07-07 02:00:23 -04:00
rderfler 77073836cb Merge remote-tracking branch 'upstream/dev' into dev 2022-05-06 22:44:24 -04:00
nickofolas 7d75093989 Init work types with new None member 2022-05-04 15:03:02 -05:00
nickofolas 59982370cb Implement CrimeType enum 2022-05-04 14:48:49 -05:00
nickofolas f45200b25e Implement ClassType and FactionWorkType enums 2022-05-04 14:18:12 -05:00
nickofolas 4a8e99b170 Refactor WorkType to an enum 2022-05-04 13:42:48 -05:00
hydroflame 5d4241b120 Merge pull request #3568 from nickofolas/fix/grafting-stop-work
GRAFTING: Fix Grafting not being handled in singularity stop work
2022-05-04 12:02:29 -04:00
hydroflame bffa166fc3 Merge pull request #3577 from phyzical/feature/WEB-3567
FEATURE: added logic to allow quitJob to be called from singularity
2022-05-04 11:57:39 -04:00
phyzical 0767043166 added logic to avoid stale object reference on sleeve during augmentation 2022-05-03 19:22:05 +08:00
phyzical 711955c112 added logic to allow quitJob to be called from singularity 2022-04-28 19:05:56 +08:00
nickofolas a87bfb0de6 Handle grafting in singularity stop work 2022-04-26 20:11:41 -05:00
rderfler e381e857a5 Merge remote-tracking branch 'upstream/dev' into dev 2022-04-25 13:32:38 -04:00
borisflagell e05617d9d3 UI FIX #3415
fixes #3415
2022-04-21 00:18:15 +02:00
rderfler 9e6e97d1fb fmt and merge upstream 2022-04-14 15:49:21 -04:00
rderfler 3cd8f8a223 merged from upstream 2022-04-14 15:47:00 -04:00
rderfler 332b803332 Fmt and lint 2022-04-14 15:28:13 -04:00
Olivier Gagnon 7685f52f8e fix import and make rainbow return the answer. 2022-04-14 15:23:49 -04:00
Olivier Gagnon 52e27e317e Added blood donation bonus 2022-04-14 15:17:46 -04:00
rderfler 9d18118208 Format, but git forgot this last time 2022-04-14 12:00:17 -04:00
rderfler 2613948bad Add bladeburner actions to sleeves
This adds bladeburner actions to sleeves. In addition this bulked out the IPerson functionality and updated bladeburner functions to be more sleeve compatible
2022-04-14 11:40:59 -04:00