mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-26 17:43:48 +01:00
Set BitNode-10 description and BitNode multipliers
This commit is contained in:
parent
10231b6c66
commit
aac262b736
45
Quotes.txt
Normal file
45
Quotes.txt
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
Collection of Quotes
|
||||||
|
|
||||||
|
The past is relevant only as data
|
||||||
|
|
||||||
|
Pull on the new flesh like borrowed gloves and burn your fingers once again.
|
||||||
|
|
||||||
|
A weapon is a tool. A tool for killing and destroying. And there will be times
|
||||||
|
when you must kill and destroy. Then you will choose and equip yourself with the tools
|
||||||
|
that you need. But remember the weakness of weapons. They are an extension --
|
||||||
|
You are the killer and destroyer. You are whole, with or without them.
|
||||||
|
|
||||||
|
For all that we have done, as a civilization, as individuals, the universe is
|
||||||
|
not stable, and nor is any single thing within it. Stars consume themselves,
|
||||||
|
the universe itself rushes apart, and we ourselves are composed of matter in
|
||||||
|
constant flux. Colonies of cells in temporary alliance, replicating and
|
||||||
|
decaying and housed within, an incandescent cloud of electrical impulse and
|
||||||
|
precariously stacked carbon code memory. This is reality, this is self knowledge,
|
||||||
|
and the perception of it will, of course, make you dizzy.
|
||||||
|
|
||||||
|
You are still young and stupid. Human life has no value. Haven't you learned
|
||||||
|
that yet, Takeshi, with all you've seen? It has no value, intrinsic to itself.
|
||||||
|
Machines cost money to build. Raw materials cost money to extract. But people?"
|
||||||
|
She made a tiny spitting sound. "You can always get some more people. they
|
||||||
|
reproduce like cancer cells, whether you want them or not. They are abundant,
|
||||||
|
Takeshi. Why should they be valuable? Do you know that it costs us less to
|
||||||
|
recruit and use up a real snuff whore than it does to set up and run the virtual
|
||||||
|
equivalent format. Real human flesh is cheaper than a machine. It's the axiomatic
|
||||||
|
truth of our times.
|
||||||
|
|
||||||
|
Peace is an illusion, no matter how tranquil the world seems, peace doesn't last long.
|
||||||
|
Peace is a struggle against our very nature. A skin we sketch over the bone, muscle,
|
||||||
|
and sinew of our own innate savagery.
|
||||||
|
|
||||||
|
The human eye is a wonderful device. With a little effort, it can fail to see even
|
||||||
|
the most glaring injustice.
|
||||||
|
|
||||||
|
Humanity has spread to the stars. We set out like ancient seafarers to explore
|
||||||
|
the limitless ocean of space. But no matter how far we venture into the unknown,
|
||||||
|
the worst monsters are those we bring with us.
|
||||||
|
|
||||||
|
What we believe shapes who we are. Belief can bring us salvation or destruction.
|
||||||
|
But when you believe a lie for too long, the truth doesn't set you free. It tears
|
||||||
|
you apart.
|
||||||
|
|
||||||
|
We aren't meant to live forever. It corrupts even the best of us.
|
@ -157,7 +157,20 @@ function initBitNodes() {
|
|||||||
"This Source-File also increases your hacking growth multipliers by: " +
|
"This Source-File also increases your hacking growth multipliers by: " +
|
||||||
"<br>Level 1: 12%<br>Level 2: 18%<br>Level 3: 21%");
|
"<br>Level 1: 12%<br>Level 2: 18%<br>Level 3: 21%");
|
||||||
BitNodes["BitNode9"] = new BitNode(9, "Do Androids Dream?", "COMING SOON");
|
BitNodes["BitNode9"] = new BitNode(9, "Do Androids Dream?", "COMING SOON");
|
||||||
BitNodes["BitNode10"] = new BitNode(10, "MegaCorp", "COMING SOON"); //Not sure yet
|
BitNodes["BitNode10"] = new BitNode(10, "Digital Carbon", "Your body is not who you are",
|
||||||
|
"In 2084, VitaLife unveiled to the world the Persona Core, an Augmentation that allowed people " +
|
||||||
|
"to digitize their consciousness. Their consciousness could then be transferred into Synthoids " +
|
||||||
|
"or other bodies by trasmitting the digitized data. Human bodies became nothing more than 'sleeves' for the " +
|
||||||
|
"human consciousness. Mankind had finally achieved immortality - at least for those that could afford it.<br><br>" +
|
||||||
|
"This BitNode unlocks Sleeve technology. Sleeve technology allows you to:<br><br>" +
|
||||||
|
"1. Re-sleeve: Purchase and transfer your consciousness into a new body<br>" +
|
||||||
|
"2. Duplicate Sleeves: Duplicate your consciousness into Synthoids, allowing you to perform different tasks synchronously<br><br>" +
|
||||||
|
"In this BitNode:<br><br>" +
|
||||||
|
"Your stats are significantly decreased.<br>" +
|
||||||
|
"All methods of gaining money are half as profitable (except Stock Market)<br>" +
|
||||||
|
"Augmentations are 5x as expensive and require twice as much reputation<br><br>" +
|
||||||
|
"Destroying this BitNode will give you Source-File 10, or if you already have this Source-File it will " +
|
||||||
|
"upgrade its level up to a maximum of 3. Each level of this Source-File grants you a Duplicate Sleeve.");
|
||||||
BitNodes["BitNode11"] = new BitNode(11, "The Big Crash", "Okay. Sell it all.",
|
BitNodes["BitNode11"] = new BitNode(11, "The Big Crash", "Okay. Sell it all.",
|
||||||
"The 2050s was defined by the massive amounts of violent civil unrest and anarchic rebellion that rose all around the world. It was this period " +
|
"The 2050s was defined by the massive amounts of violent civil unrest and anarchic rebellion that rose all around the world. It was this period " +
|
||||||
"of disorder that eventually lead to the governmental reformation of many global superpowers, most notably " +
|
"of disorder that eventually lead to the governmental reformation of many global superpowers, most notably " +
|
||||||
@ -306,6 +319,23 @@ function initBitNodeMultipliers() {
|
|||||||
BitNodeMultipliers.CorporationValuation = 0;
|
BitNodeMultipliers.CorporationValuation = 0;
|
||||||
BitNodeMultipliers.CodingContractMoney = 0;
|
BitNodeMultipliers.CodingContractMoney = 0;
|
||||||
break;
|
break;
|
||||||
|
case 10: // Digital Carbon
|
||||||
|
BitNodeMultipliers.HackingLevelMultiplier = 0.2;
|
||||||
|
BitNodeMultipliers.StrengthLevelMultiplier = 0.4;
|
||||||
|
BitNodeMultipliers.DefenseLevelMultiplier = 0.4;
|
||||||
|
BitNodeMultipliers.DexterityLevelMultiplier = 0.4;
|
||||||
|
BitNodeMultipliers.AgilityLevelMultiplier = 0.4;
|
||||||
|
BitNodeMultipliers.CharismaLevelMultiplier = 0.4;
|
||||||
|
BitNodeMultipliers.CompanyWorkMoney = 0.5;
|
||||||
|
BitNodeMultipliers.CrimeMoney = 0.5;
|
||||||
|
BitNodeMultipliers.HacknetNodeMoney = 0.5;
|
||||||
|
BitNodeMultipliers.ManualHackMoney = 0.5;
|
||||||
|
BitNodeMultipliers.ScriptHackMoney = 0.5;
|
||||||
|
BitNodeMultipliers.CodingContractMoney = 0.5;
|
||||||
|
BitNodeMultipliers.InfiltrationMoney = 0.5;
|
||||||
|
BitNodeMultipliers.CorporationValuation = 0.5;
|
||||||
|
BitNodeMultipliers.AugmentationMoneyCost = 5;
|
||||||
|
BitNodeMultipliers.AugmentationRepCost = 2;
|
||||||
case 11: //The Big Crash
|
case 11: //The Big Crash
|
||||||
BitNodeMultipliers.ServerMaxMoney = 0.1;
|
BitNodeMultipliers.ServerMaxMoney = 0.1;
|
||||||
BitNodeMultipliers.ServerStartingMoney = 0.1;
|
BitNodeMultipliers.ServerStartingMoney = 0.1;
|
||||||
|
@ -4,6 +4,11 @@
|
|||||||
* player toward the intended strategy. Unless they really want to play the long, slow game of waiting...
|
* player toward the intended strategy. Unless they really want to play the long, slow game of waiting...
|
||||||
*/
|
*/
|
||||||
interface IBitNodeMultipliers {
|
interface IBitNodeMultipliers {
|
||||||
|
/**
|
||||||
|
* Influences how quickly the player's agility level (not exp) scales
|
||||||
|
*/
|
||||||
|
AgilityLevelMultiplier: number;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Influences the base cost to purchase an augmentation.
|
* Influences the base cost to purchase an augmentation.
|
||||||
*/
|
*/
|
||||||
@ -24,6 +29,11 @@ interface IBitNodeMultipliers {
|
|||||||
*/
|
*/
|
||||||
BladeburnerSkillCost: number;
|
BladeburnerSkillCost: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Influences how quickly the player's charisma level (not exp) scales
|
||||||
|
*/
|
||||||
|
CharismaLevelMultiplier: number;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Influences the experience gained for each ability when a player completes a class.
|
* Influences the experience gained for each ability when a player completes a class.
|
||||||
*/
|
*/
|
||||||
@ -59,6 +69,16 @@ interface IBitNodeMultipliers {
|
|||||||
*/
|
*/
|
||||||
CrimeMoney: number;
|
CrimeMoney: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Influences how quickly the player's defense level (not exp) scales
|
||||||
|
*/
|
||||||
|
DefenseLevelMultiplier: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Influences how quickly the player's dexterity level (not exp) scales
|
||||||
|
*/
|
||||||
|
DexterityLevelMultiplier: number;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Influences how much rep the player gains in each faction simply by being a member.
|
* Influences how much rep the player gains in each faction simply by being a member.
|
||||||
*/
|
*/
|
||||||
@ -139,6 +159,11 @@ interface IBitNodeMultipliers {
|
|||||||
* Influences the weaken amount per invocation against a server.
|
* Influences the weaken amount per invocation against a server.
|
||||||
*/
|
*/
|
||||||
ServerWeakenRate: number;
|
ServerWeakenRate: number;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Influences how quickly the player's strength level (not exp) scales
|
||||||
|
*/
|
||||||
|
StrengthLevelMultiplier: number;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -147,6 +172,11 @@ interface IBitNodeMultipliers {
|
|||||||
// tslint:disable-next-line:variable-name
|
// tslint:disable-next-line:variable-name
|
||||||
export const BitNodeMultipliers: IBitNodeMultipliers = {
|
export const BitNodeMultipliers: IBitNodeMultipliers = {
|
||||||
HackingLevelMultiplier: 1,
|
HackingLevelMultiplier: 1,
|
||||||
|
StrengthLevelMultiplier: 1,
|
||||||
|
DefenseLevelMultiplier: 1,
|
||||||
|
DexterityLevelMultiplier: 1,
|
||||||
|
AgilityLevelMultiplier: 1,
|
||||||
|
CharismaLevelMultiplier: 1,
|
||||||
|
|
||||||
ServerGrowthRate: 1,
|
ServerGrowthRate: 1,
|
||||||
ServerMaxMoney: 1,
|
ServerMaxMoney: 1,
|
||||||
|
@ -276,6 +276,9 @@ export let CONSTANTS: IMap<any> = {
|
|||||||
CodingContractBaseCompanyRepGain: 4000,
|
CodingContractBaseCompanyRepGain: 4000,
|
||||||
CodingContractBaseMoneyGain: 50e6,
|
CodingContractBaseMoneyGain: 50e6,
|
||||||
|
|
||||||
|
// BitNode/Source-File related stuff
|
||||||
|
TotalNumBitNodes: 24,
|
||||||
|
|
||||||
/* Tutorial related things */
|
/* Tutorial related things */
|
||||||
TutorialNetworkingText: "Servers are a central part of the game. You start with a single personal server (your home computer) " +
|
TutorialNetworkingText: "Servers are a central part of the game. You start with a single personal server (your home computer) " +
|
||||||
"and you can purchase additional servers as you progress through the game. Connecting to other servers " +
|
"and you can purchase additional servers as you progress through the game. Connecting to other servers " +
|
||||||
|
@ -9,6 +9,7 @@ import { Sleeve } from "./Sleeve/Sleeve";
|
|||||||
import { IMap } from "../types";
|
import { IMap } from "../types";
|
||||||
|
|
||||||
import { IPlayerOwnedAugmentation } from "../Augmentation/PlayerOwnedAugmentation";
|
import { IPlayerOwnedAugmentation } from "../Augmentation/PlayerOwnedAugmentation";
|
||||||
|
import { IPlayerOwnedSourceFile } from "../SourceFile/PlayerOwnedSourceFile";
|
||||||
|
|
||||||
export interface IPlayer {
|
export interface IPlayer {
|
||||||
augmentations: IPlayerOwnedAugmentation[];
|
augmentations: IPlayerOwnedAugmentation[];
|
||||||
@ -19,6 +20,7 @@ export interface IPlayer {
|
|||||||
queuedAugmentations: IPlayerOwnedAugmentation[];
|
queuedAugmentations: IPlayerOwnedAugmentation[];
|
||||||
resleeves: Resleeve[];
|
resleeves: Resleeve[];
|
||||||
sleeves: Sleeve[];
|
sleeves: Sleeve[];
|
||||||
|
sourceFiles: IPlayerOwnedSourceFile[];
|
||||||
|
|
||||||
hacking_skill: number;
|
hacking_skill: number;
|
||||||
strength: number;
|
strength: number;
|
||||||
|
@ -194,5 +194,5 @@ function updateAugDescription(elems: IResleeveUIElems) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
elems.augDescription.innerHTML = aug!.info;
|
elems.augDescription!.innerHTML = aug!.info;
|
||||||
}
|
}
|
||||||
|
@ -76,7 +76,7 @@ export function createSleevesPage(p: IPlayer) {
|
|||||||
|
|
||||||
UIElems.info = createElement("p", {
|
UIElems.info = createElement("p", {
|
||||||
display: "inline-block",
|
display: "inline-block",
|
||||||
innerText: "Sleeves are MK-V Synthoids (synthetic androids) into which your " +
|
innerText: "Duplicate Sleeves are MK-V Synthoids (synthetic androids) into which your " +
|
||||||
"consciousness has copied. In other words, these Synthoids contain " +
|
"consciousness has copied. In other words, these Synthoids contain " +
|
||||||
"a perfect duplicate of your mind.<br><br>" +
|
"a perfect duplicate of your mind.<br><br>" +
|
||||||
"Sleeves can be used to perform different tasks synchronously.",
|
"Sleeves can be used to perform different tasks synchronously.",
|
||||||
|
@ -22,10 +22,12 @@ import { displayFactionContent } from "./Faction/FactionHelpers";
|
|||||||
import {Gang, resetGangs} from "./Gang";
|
import {Gang, resetGangs} from "./Gang";
|
||||||
import {Locations} from "./Locations";
|
import {Locations} from "./Locations";
|
||||||
import {hasBn11SF, hasWallStreetSF,hasAISF} from "./NetscriptFunctions";
|
import {hasBn11SF, hasWallStreetSF,hasAISF} from "./NetscriptFunctions";
|
||||||
|
import { Sleeve } from "./PersonObjects/Sleeve/Sleeve";
|
||||||
import {AllServers, Server, AddToAllServers} from "./Server";
|
import {AllServers, Server, AddToAllServers} from "./Server";
|
||||||
import {Settings} from "./Settings";
|
import {Settings} from "./Settings";
|
||||||
import {SpecialServerIps, SpecialServerNames} from "./SpecialServerIps";
|
import {SpecialServerIps, SpecialServerNames} from "./SpecialServerIps";
|
||||||
import {SourceFiles, applySourceFile} from "./SourceFile";
|
import {SourceFiles, applySourceFile} from "./SourceFile";
|
||||||
|
import { SourceFileFlags } from "./SourceFile/SourceFileFlags";
|
||||||
import Decimal from "decimal.js";
|
import Decimal from "decimal.js";
|
||||||
import {numeralWrapper} from "./ui/numeralFormat";
|
import {numeralWrapper} from "./ui/numeralFormat";
|
||||||
import {dialogBoxCreate} from "../utils/DialogBox";
|
import {dialogBoxCreate} from "../utils/DialogBox";
|
||||||
@ -274,6 +276,8 @@ PlayerObject.prototype.prestigeAugmentation = function() {
|
|||||||
|
|
||||||
this.queuedAugmentations = [];
|
this.queuedAugmentations = [];
|
||||||
|
|
||||||
|
this.resleeves = [];
|
||||||
|
|
||||||
this.isWorking = false;
|
this.isWorking = false;
|
||||||
this.currentWorkFactionName = "";
|
this.currentWorkFactionName = "";
|
||||||
this.currentWorkFactionDescription = "";
|
this.currentWorkFactionDescription = "";
|
||||||
@ -355,6 +359,16 @@ PlayerObject.prototype.prestigeSourceFile = function() {
|
|||||||
this.queuedAugmentations = [];
|
this.queuedAugmentations = [];
|
||||||
this.augmentations = [];
|
this.augmentations = [];
|
||||||
|
|
||||||
|
this.resleeves = [];
|
||||||
|
|
||||||
|
// Duplicate sleeves are reset to level 1 every Bit Node (but the number of sleeves you have persists)
|
||||||
|
if (this.sleeves.length < SourceFileFlags[10]) {
|
||||||
|
this.sleeves.length = SourceFileFlags[10];
|
||||||
|
}
|
||||||
|
for (let i = 0; i < this.sleeves.length; ++i) {
|
||||||
|
this.sleeves[i] = new Sleeve();
|
||||||
|
}
|
||||||
|
|
||||||
this.isWorking = false;
|
this.isWorking = false;
|
||||||
this.currentWorkFactionName = "";
|
this.currentWorkFactionName = "";
|
||||||
this.currentWorkFactionDescription = "";
|
this.currentWorkFactionDescription = "";
|
||||||
@ -443,11 +457,11 @@ PlayerObject.prototype.calculateSkill = function(exp, mult=1) {
|
|||||||
|
|
||||||
PlayerObject.prototype.updateSkillLevels = function() {
|
PlayerObject.prototype.updateSkillLevels = function() {
|
||||||
this.hacking_skill = Math.max(1, Math.floor(this.calculateSkill(this.hacking_exp, this.hacking_mult * BitNodeMultipliers.HackingLevelMultiplier)));
|
this.hacking_skill = Math.max(1, Math.floor(this.calculateSkill(this.hacking_exp, this.hacking_mult * BitNodeMultipliers.HackingLevelMultiplier)));
|
||||||
this.strength = this.calculateSkill(this.strength_exp, this.strength_mult);
|
this.strength = Math.max(1, Math.floor(this.calculateSkill(this.strength_exp, this.strength_mult * BitNodeMultipliers.StrengthLevelMultiplier)));
|
||||||
this.defense = this.calculateSkill(this.defense_exp, this.defense_mult);
|
this.defense = Math.max(1, Math.floor(this.calculateSkill(this.defense_exp, this.defense_mult * BitNodeMultipliers.DefenseLevelMultiplier)));
|
||||||
this.dexterity = this.calculateSkill(this.dexterity_exp, this.dexterity_mult);
|
this.dexterity = Math.max(1, Math.floor(this.calculateSkill(this.dexterity_exp, this.dexterity_mult * BitNodeMultipliers.DexterityLevelMultiplier)));
|
||||||
this.agility = this.calculateSkill(this.agility_exp, this.agility_mult);
|
this.agility = Math.max(1, Math.floor(this.calculateSkill(this.agility_exp, this.agility_mult * BitNodeMultipliers.AgilityLevelMultiplier)));
|
||||||
this.charisma = this.calculateSkill(this.charisma_exp, this.charisma_mult);
|
this.charisma = Math.max(1, Math.floor(this.calculateSkill(this.charisma_exp, this.charisma_mult * BitNodeMultipliers.CharismaLevelMultiplier)));
|
||||||
|
|
||||||
if (this.intelligence > 0) {
|
if (this.intelligence > 0) {
|
||||||
this.intelligence = Math.floor(this.calculateSkill(this.intelligence_exp));
|
this.intelligence = Math.floor(this.calculateSkill(this.intelligence_exp));
|
||||||
|
@ -26,6 +26,7 @@ import {AllServers, AddToAllServers,
|
|||||||
initForeignServers, Server,
|
initForeignServers, Server,
|
||||||
prestigeAllServers,
|
prestigeAllServers,
|
||||||
prestigeHomeComputer} from "./Server";
|
prestigeHomeComputer} from "./Server";
|
||||||
|
import { updateSourceFileFlags } from "./SourceFile/SourceFileFlags";
|
||||||
import {SpecialServerIps, SpecialServerIpsMap,
|
import {SpecialServerIps, SpecialServerIpsMap,
|
||||||
prestigeSpecialServerIps,
|
prestigeSpecialServerIps,
|
||||||
SpecialServerNames} from "./SpecialServerIps";
|
SpecialServerNames} from "./SpecialServerIps";
|
||||||
@ -171,6 +172,7 @@ function prestigeAugmentation() {
|
|||||||
//Prestige by destroying Bit Node and gaining a Source File
|
//Prestige by destroying Bit Node and gaining a Source File
|
||||||
function prestigeSourceFile() {
|
function prestigeSourceFile() {
|
||||||
initBitNodeMultipliers();
|
initBitNodeMultipliers();
|
||||||
|
updateSourceFileFlags(Player);
|
||||||
|
|
||||||
Player.prestigeSourceFile();
|
Player.prestigeSourceFile();
|
||||||
prestigeWorkerScripts(); //Delete all Worker Scripts objects
|
prestigeWorkerScripts(); //Delete all Worker Scripts objects
|
||||||
|
@ -3,8 +3,8 @@ import { Engine } from "./engine";
|
|||||||
import { Player } from "./Player";
|
import { Player } from "./Player";
|
||||||
import { prestigeSourceFile } from "./Prestige";
|
import { prestigeSourceFile } from "./Prestige";
|
||||||
import { SourceFiles,
|
import { SourceFiles,
|
||||||
SourceFile,
|
SourceFile } from "./SourceFile";
|
||||||
PlayerOwnedSourceFile } from "./SourceFile";
|
import { PlayerOwnedSourceFile } from "./SourceFile/PlayerOwnedSourceFile";
|
||||||
import { Terminal } from "./Terminal";
|
import { Terminal } from "./Terminal";
|
||||||
|
|
||||||
import {clearEventListeners} from "../utils/uiHelpers/clearEventListeners";
|
import {clearEventListeners} from "../utils/uiHelpers/clearEventListeners";
|
||||||
|
@ -74,11 +74,6 @@ function initSourceFiles() {
|
|||||||
"In other words, level N of this Source-File will result in a multiplier of 1.01^N (or 0.99^N for multipliers that decrease)");
|
"In other words, level N of this Source-File will result in a multiplier of 1.01^N (or 0.99^N for multipliers that decrease)");
|
||||||
}
|
}
|
||||||
|
|
||||||
function PlayerOwnedSourceFile(number, level) {
|
|
||||||
this.n = number;
|
|
||||||
this.lvl = level;
|
|
||||||
}
|
|
||||||
|
|
||||||
//Takes in a PlayerOwnedSourceFile as the "srcFile" argument
|
//Takes in a PlayerOwnedSourceFile as the "srcFile" argument
|
||||||
function applySourceFile(srcFile) {
|
function applySourceFile(srcFile) {
|
||||||
var srcFileKey = "SourceFile" + srcFile.n;
|
var srcFileKey = "SourceFile" + srcFile.n;
|
||||||
@ -246,4 +241,4 @@ function applySourceFile(srcFile) {
|
|||||||
sourceFileObject.owned = true;
|
sourceFileObject.owned = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
export {SourceFiles, PlayerOwnedSourceFile, applySourceFile, initSourceFiles};
|
export {SourceFiles, applySourceFile, initSourceFiles};
|
||||||
|
17
src/SourceFile/PlayerOwnedSourceFile.ts
Normal file
17
src/SourceFile/PlayerOwnedSourceFile.ts
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
export class PlayerOwnedSourceFile {
|
||||||
|
// Source-File level
|
||||||
|
lvl: number = 1;
|
||||||
|
|
||||||
|
// Source-File number
|
||||||
|
n: number = 1;
|
||||||
|
|
||||||
|
constructor(n: number, level: number) {
|
||||||
|
this.n = n;
|
||||||
|
this.lvl = level;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface IPlayerOwnedSourceFile {
|
||||||
|
lvl: number;
|
||||||
|
n: number;
|
||||||
|
}
|
18
src/SourceFile/SourceFileFlags.ts
Normal file
18
src/SourceFile/SourceFileFlags.ts
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
// Contains an array containing information about the player's source files
|
||||||
|
// Array[n] returns what level the player has of Source-File N.
|
||||||
|
|
||||||
|
import { CONSTANTS } from "../Constants";
|
||||||
|
import { IPlayer } from "../PersonObjects/IPlayer";
|
||||||
|
|
||||||
|
export const SourceFileFlags: number[] = Array(CONSTANTS.TotalNumBitNodes + 1); // Skip 0
|
||||||
|
|
||||||
|
export function updateSourceFileFlags(p: IPlayer) {
|
||||||
|
for (let i = 0; i < SourceFileFlags.length; ++i) {
|
||||||
|
SourceFileFlags[i] = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
for (let i = 0; i < p.sourceFiles.length; ++i) {
|
||||||
|
const sf = p.sourceFiles[i];
|
||||||
|
SourceFileFlags[sf.n] = sf.lvl;
|
||||||
|
}
|
||||||
|
}
|
@ -69,8 +69,9 @@ import {loadAllRunningScripts, scriptEditorInit,
|
|||||||
import {AllServers, Server, initForeignServers} from "./Server";
|
import {AllServers, Server, initForeignServers} from "./Server";
|
||||||
import {Settings} from "./Settings";
|
import {Settings} from "./Settings";
|
||||||
import {setSettingsLabels} from "./ui/setSettingsLabels";
|
import {setSettingsLabels} from "./ui/setSettingsLabels";
|
||||||
import {initSourceFiles, SourceFiles,
|
import { initSourceFiles, SourceFiles } from "./SourceFile";
|
||||||
PlayerOwnedSourceFile} from "./SourceFile";
|
import { updateSourceFileFlags } from "./SourceFile/SourceFileFlags";
|
||||||
|
|
||||||
import {SpecialServerIps, initSpecialServerIps} from "./SpecialServerIps";
|
import {SpecialServerIps, initSpecialServerIps} from "./SpecialServerIps";
|
||||||
import {StockMarket, StockSymbols,
|
import {StockMarket, StockSymbols,
|
||||||
SymbolToStockMap, initStockSymbols,
|
SymbolToStockMap, initStockSymbols,
|
||||||
@ -1239,8 +1240,7 @@ const Engine = {
|
|||||||
}
|
}
|
||||||
initLiterature();
|
initLiterature();
|
||||||
initSingularitySFFlags();
|
initSingularitySFFlags();
|
||||||
|
updateSourceFileFlags(Player);
|
||||||
console.log(Player.intelligence_exp);
|
|
||||||
|
|
||||||
//Calculate the number of cycles have elapsed while offline
|
//Calculate the number of cycles have elapsed while offline
|
||||||
Engine._lastUpdate = new Date().getTime();
|
Engine._lastUpdate = new Date().getTime();
|
||||||
|
Loading…
Reference in New Issue
Block a user