Fix crash when quitting an unfocused job

This commit is contained in:
Olivier Gagnon 2021-08-10 19:36:52 -04:00
parent 547324a813
commit e18aa08eeb
5 changed files with 769 additions and 1153 deletions

@ -3,6 +3,12 @@
Changelog Changelog
========= =========
v0.52.1 - 2021-07-10 bugfixing (hydroflame)
-------------------------------------------
**Misc.**
* Fix game crash/corruption when quitting a job while working for it unfocused.
v0.52.0 - 2021-06-13 Infiltration 2.0 (hydroflame & community) v0.52.0 - 2021-06-13 Infiltration 2.0 (hydroflame & community)
-------------------------------------------------------------- --------------------------------------------------------------

1906
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -33,6 +33,7 @@
"loader-runner": "^2.3.0", "loader-runner": "^2.3.0",
"loader-utils": "^1.1.0", "loader-utils": "^1.1.0",
"memory-fs": "~0.4.1", "memory-fs": "~0.4.1",
"node-sass": "^6.0.1",
"normalize.css": "^8.0.0", "normalize.css": "^8.0.0",
"numeral": "2.0.6", "numeral": "2.0.6",
"react": "^16.8.3", "react": "^16.8.3",
@ -76,7 +77,6 @@
"mkdirp": "^0.5.1", "mkdirp": "^0.5.1",
"mocha": "^6.1.4", "mocha": "^6.1.4",
"mochapack": "^1.1.1", "mochapack": "^1.1.1",
"node-sass": "^5.0.0",
"null-loader": "^1.0.0", "null-loader": "^1.0.0",
"raw-loader": "~0.5.0", "raw-loader": "~0.5.0",
"sass-loader": "^7.0.3", "sass-loader": "^7.0.3",

@ -441,10 +441,3 @@ export const LocationsMetadata: IConstructorParams[] = [
types: [LocationType.StockMarket], types: [LocationType.StockMarket],
}, },
]; ];
(function(){
for(const loc of LocationsMetadata) {
if(!loc || !loc.infiltrationData) continue
console.log(loc.infiltrationData.startingSecurityLevel+2);
}
})();

@ -1785,6 +1785,7 @@ export function getNextCompanyPosition(company, entryPosType) {
} }
export function quitJob(company) { export function quitJob(company) {
this.isWorking = false;
this.companyName = ""; this.companyName = "";
delete this.jobs[company]; delete this.jobs[company];
} }