mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-26 09:33:49 +01:00
Playtesting- fixed bugs
This commit is contained in:
parent
77f386d14a
commit
650bdf1f3f
@ -67,6 +67,8 @@ TESTING TODO:
|
|||||||
|
|
||||||
Seems to work fine
|
Seems to work fine
|
||||||
Tasks TODO:
|
Tasks TODO:
|
||||||
|
Factions Info page isn't formatted correctly
|
||||||
|
|
||||||
Augmentations that decrease time to make programs
|
Augmentations that decrease time to make programs
|
||||||
|
|
||||||
New server hostname in Purchase Server Pop-up Box needs limits..don't think the ones set in HTML work
|
New server hostname in Purchase Server Pop-up Box needs limits..don't think the ones set in HTML work
|
||||||
|
@ -157,6 +157,11 @@
|
|||||||
width: 90%;
|
width: 90%;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#factions-list li {
|
||||||
|
padding: 6px;
|
||||||
|
margin: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
#faction-hack-button-div, #faction-hack-text-div {
|
#faction-hack-button-div, #faction-hack-text-div {
|
||||||
display:inline-block;
|
display:inline-block;
|
||||||
}
|
}
|
||||||
|
@ -22,6 +22,9 @@ CONSTANTS = {
|
|||||||
MillisecondsPer20Hours: 72000000,
|
MillisecondsPer20Hours: 72000000,
|
||||||
GameCyclesPer20Hours: 72000000 / 200,
|
GameCyclesPer20Hours: 72000000 / 200,
|
||||||
|
|
||||||
|
MillisecondsPer10Hours: 36000000,
|
||||||
|
GameCyclesPer10Hours: 36000000 / 200,
|
||||||
|
|
||||||
MillisecondsPer8Hours: 28800000,
|
MillisecondsPer8Hours: 28800000,
|
||||||
GameCyclesPer8Hours: 28800000 / 200,
|
GameCyclesPer8Hours: 28800000 / 200,
|
||||||
|
|
||||||
|
@ -125,11 +125,10 @@ PlayerObject.prototype.checkForFactionInvitations = function() {
|
|||||||
invitedFactions = []; //Array which will hold all Factions th eplayer should be invited to
|
invitedFactions = []; //Array which will hold all Factions th eplayer should be invited to
|
||||||
|
|
||||||
var company = Companies[this.companyName];
|
var company = Companies[this.companyName];
|
||||||
if (company == null) {
|
var companyRep = 0;
|
||||||
return invitedFactions;
|
if (company != null) {
|
||||||
|
companyRep = company.playerReputation;
|
||||||
}
|
}
|
||||||
var companyRep = company.playerReputation;
|
|
||||||
|
|
||||||
|
|
||||||
//Illuminati
|
//Illuminati
|
||||||
var illuminatiFac = Factions["Illuminati"];
|
var illuminatiFac = Factions["Illuminati"];
|
||||||
@ -352,8 +351,10 @@ PlayerObject.prototype.checkForFactionInvitations = function() {
|
|||||||
|
|
||||||
//CyberSec
|
//CyberSec
|
||||||
var cybersecFac = Factions["CyberSec"];
|
var cybersecFac = Factions["CyberSec"];
|
||||||
|
console.log(this.hacking_skill + " " + cybersecFac.isMember + " " + cybersecFac.isBanned);
|
||||||
if (cybersecFac.isBanned == false && cybersecFac.isMember == false &&
|
if (cybersecFac.isBanned == false && cybersecFac.isMember == false &&
|
||||||
this.hacking_skill >= 50) {
|
this.hacking_skill >= 5) {
|
||||||
|
console.log("Qualified for CyberSec");
|
||||||
invitedFactions.push(cybersecFac);
|
invitedFactions.push(cybersecFac);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -446,7 +447,7 @@ displayFactionContent = function(factionName) {
|
|||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|
||||||
newSecurityWorkButton("click", function() {
|
newSecurityWorkButton.addEventListener("click", function() {
|
||||||
Player.startFactionSecurityWork(faction);
|
Player.startFactionSecurityWork(faction);
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
@ -401,7 +401,7 @@ PlayerObject.prototype.work = function(numCycles) {
|
|||||||
//If timeWorked == 8 hours, then finish. You can only gain 8 hours worth of exp and money
|
//If timeWorked == 8 hours, then finish. You can only gain 8 hours worth of exp and money
|
||||||
if (this.timeWorked >= CONSTANTS.MillisecondsPer8Hours) {
|
if (this.timeWorked >= CONSTANTS.MillisecondsPer8Hours) {
|
||||||
var maxCycles = CONSTANTS.GameCyclesPer8Hours; //Number of cycles in 8 hours
|
var maxCycles = CONSTANTS.GameCyclesPer8Hours; //Number of cycles in 8 hours
|
||||||
this.workHackExpGained = this.workhackExpGainRate * maxCycles;
|
this.workHackExpGained = this.workHackExpGainRate * maxCycles;
|
||||||
this.workStrExpGained = this.workStrExpGainRate * maxCycles;
|
this.workStrExpGained = this.workStrExpGainRate * maxCycles;
|
||||||
this.workDefExpGained = this.workDefExpGainRate * maxCycles;
|
this.workDefExpGained = this.workDefExpGainRate * maxCycles;
|
||||||
this.workDexExpGained = this.workDexExpGainRate * maxCycles;
|
this.workDexExpGained = this.workDexExpGainRate * maxCycles;
|
||||||
@ -434,12 +434,12 @@ PlayerObject.prototype.work = function(numCycles) {
|
|||||||
|
|
||||||
/* Working for Faction */
|
/* Working for Faction */
|
||||||
PlayerObject.prototype.finishFactionWork = function(cancelled, faction) {
|
PlayerObject.prototype.finishFactionWork = function(cancelled, faction) {
|
||||||
this.hacking_exp += (this.workHackExpGained);
|
this.gainHackingExp(this.workHackExpGained);
|
||||||
this.strength_exp += (this.workStrExpGained);
|
this.gainStrengthExp(this.workStrExpGained);
|
||||||
this.defense_exp += (this.workDefExpGained);
|
this.gainDefenseExp(this.workDefExpGained);
|
||||||
this.dexterity_exp += (this.workDexExpGained);
|
this.gainDexterityExp(this.workDexExpGained);
|
||||||
this.agility_exp += (this.workAgiExpGained);
|
this.gainAgilityExp(this.workAgiExpGained);
|
||||||
this.charisma_exp += (this.workChaExpGained);
|
this.gainCharismaExp(this.workChaExpGained);
|
||||||
|
|
||||||
var faction = Factions[this.currentWorkFactionName];
|
var faction = Factions[this.currentWorkFactionName];
|
||||||
faction.playerReputation += (this.workRepGained);
|
faction.playerReputation += (this.workRepGained);
|
||||||
@ -563,7 +563,7 @@ PlayerObject.prototype.workForFaction = function(numCycles) {
|
|||||||
//If timeWorked == 20 hours, then finish. You can only work for the faction for 20 hours
|
//If timeWorked == 20 hours, then finish. You can only work for the faction for 20 hours
|
||||||
if (this.timeWorked >= CONSTANTS.MillisecondsPer20Hours) {
|
if (this.timeWorked >= CONSTANTS.MillisecondsPer20Hours) {
|
||||||
var maxCycles = CONSTANTS.GameCyclesPer20Hours; //Number of cycles in 20 hours
|
var maxCycles = CONSTANTS.GameCyclesPer20Hours; //Number of cycles in 20 hours
|
||||||
this.workHackExpGained = this.workhackExpGainRate * maxCycles;
|
this.workHackExpGained = this.workHackExpGainRate * maxCycles;
|
||||||
this.workStrExpGained = this.workStrExpGainRate * maxCycles;
|
this.workStrExpGained = this.workStrExpGainRate * maxCycles;
|
||||||
this.workDefExpGained = this.workDefExpGainRate * maxCycles;
|
this.workDefExpGained = this.workDefExpGainRate * maxCycles;
|
||||||
this.workDexExpGained = this.workDexExpGainRate * maxCycles;
|
this.workDexExpGained = this.workDexExpGainRate * maxCycles;
|
||||||
|
@ -450,6 +450,12 @@ var Engine = {
|
|||||||
displayFactionsInfo: function() {
|
displayFactionsInfo: function() {
|
||||||
var factionsList = document.getElementById("factions-list");
|
var factionsList = document.getElementById("factions-list");
|
||||||
|
|
||||||
|
//Clear the list
|
||||||
|
while (factionsList.firstChild) {
|
||||||
|
factionsList.removeChild(factionsList.firstChild);
|
||||||
|
}
|
||||||
|
|
||||||
|
//Re-add a link for each faction you are a member of
|
||||||
for (var i = 0; i < Player.factions.length; ++i) {
|
for (var i = 0; i < Player.factions.length; ++i) {
|
||||||
var factionName = Player.factions[i];
|
var factionName = Player.factions[i];
|
||||||
|
|
||||||
@ -585,7 +591,8 @@ var Engine = {
|
|||||||
updateSkillLevelsCounter: 10, //Only update skill levels every 2 seconds. Might improve performance
|
updateSkillLevelsCounter: 10, //Only update skill levels every 2 seconds. Might improve performance
|
||||||
updateDisplays: 5, //Update displays such as Active Scripts display and character display
|
updateDisplays: 5, //Update displays such as Active Scripts display and character display
|
||||||
serverGrowth: 450, //Process server growth every minute and a half
|
serverGrowth: 450, //Process server growth every minute and a half
|
||||||
checkFactionInvitations: 1500, //Check whether you qualify for any faction invitations every 5 minutes
|
//checkFactionInvitations: 1500, //Check whether you qualify for any faction invitations every 5 minutes
|
||||||
|
checkFactionInvitations: 50,
|
||||||
},
|
},
|
||||||
|
|
||||||
decrementAllCounters: function(numCycles = 1) {
|
decrementAllCounters: function(numCycles = 1) {
|
||||||
|
@ -7,7 +7,9 @@
|
|||||||
// off to that `fromJSON` fuunction, passing in the value.
|
// off to that `fromJSON` fuunction, passing in the value.
|
||||||
function Reviver(key, value) {
|
function Reviver(key, value) {
|
||||||
var ctor;
|
var ctor;
|
||||||
//console.log("Reviver called with key: " + key + ", and value: " + value);
|
if (value == null) {
|
||||||
|
console.log("Reviver WRONGLY called with key: " + key + ", and value: " + value);
|
||||||
|
}
|
||||||
if (typeof value === "object" &&
|
if (typeof value === "object" &&
|
||||||
typeof value.ctor === "string" &&
|
typeof value.ctor === "string" &&
|
||||||
typeof value.data !== "undefined") {
|
typeof value.data !== "undefined") {
|
||||||
|
Loading…
Reference in New Issue
Block a user