bitburner-src/src/Player.ts
Olivier Gagnon 5b8eea66d4 rm some any
2022-07-15 23:34:27 -04:00

13 lines
417 B
TypeScript

import { PlayerObject } from "./PersonObjects/Player/PlayerObject";
import { sanitizeExploits } from "./Exploits/Exploit";
import { Reviver } from "./utils/JSONReviver";
export let Player = new PlayerObject();
export function loadPlayer(saveString: string): void {
Player = JSON.parse(saveString, Reviver);
Player.money = parseFloat(Player.money + "");
Player.exploits = sanitizeExploits(Player.exploits);
}