def write(self) -> None: self.hideout.write() self.mail.write() self.inventory.write() atomic_write(self.pmc.json(exclude_defaults=True), self.pmc_profile_path) atomic_write(self.scav.json(exclude_defaults=True), self.scav_profile_path)
def write(self) -> None: atomic_write( self.dialogues.json(by_alias=True, exclude_unset=False, exclude_none=True, indent=4), self.path, )
def write(self) -> None: atomic_write(ujson.dumps(self.metadata, indent=4), self.meta_path)
def __write(self) -> None: self.path.parent.mkdir(exist_ok=True, parents=True) accounts = [a.dict() for a in self.accounts] atomic_write(json.dumps(accounts, indent=4, ensure_ascii=False), self.path)