mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2025-03-30 15:02:29 +02:00
sleevesQuitToo
This commit is contained in:
@ -23,6 +23,7 @@ import { Locations } from "../../Locations/Locations";
|
||||
import { CityName } from "../../Locations/data/CityNames";
|
||||
import { LocationName } from "../../Locations/data/LocationNames";
|
||||
import { Sleeve } from "../Sleeve/Sleeve";
|
||||
import { SleeveCompanyWork } from "../Sleeve/Work/SleeveCompanyWork";
|
||||
import {
|
||||
calculateSkill as calculateSkillF,
|
||||
calculateSkillProgress as calculateSkillProgressF,
|
||||
@ -593,6 +594,11 @@ export function quitJob(this: IPlayer, company: string): void {
|
||||
if (isCompanyWork(this.currentWork) && this.currentWork.companyName === company) {
|
||||
this.finishWork(true);
|
||||
}
|
||||
for (const sleeve of this.sleeves) {
|
||||
if (sleeve.currentWork instanceof SleeveCompanyWork && sleeve.currentWork.companyName === company){
|
||||
sleeve.currentWork.finish(this);
|
||||
}
|
||||
}
|
||||
delete this.jobs[company];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user