What are bak and json extensions used for in level folders?

Need help with any SMBX game-related issues? Ask your questions here.

Moderator: Userbase Moderators

Mal8rk
Snifit
Snifit
Posts: 217
Joined: Mon Oct 25, 2021 11:04 pm
Flair: English Speaking Spanish Speaker
Pronouns: He/Him
Contact:

What are bak and json extensions used for in level folders?

Postby Mal8rk » Mon Feb 21, 2022 8:47 pm

I was always wondering, what are bak and json extensions used for in level folders

And does something bad happen if you erase them from your level folder?

deice
Rocky Wrench
Rocky Wrench
Posts: 639
Joined: Fri Jul 23, 2021 7:35 am

Re: What are bak and json extensions used for in level folders?

Postby deice » Tue Feb 22, 2022 5:21 am

.bak isn't it's own filetype, it's just the conventional extension used for backups of other files. the pge editor backs your level up sometimes while you're editing it, and the uses could range from convenience to reverting certain operations or even as a failsafe in case of a crash, though you'd have to ask wohlstand if you wanted to know the exact details of what the level backups are for. from experience these are safe to delete.

JSON is short for javascript object notation, and they're essentially just a simple way to organize data in a plain text format. when you refer to a json file in your level folder, i assume you mean "progress.json". if i recall correctly, this file is used for achievement functionality within smbx2. read more on that here. erasing it from an episode's folder will most likely just delete your achievement progress for that episode, though i haven't tested it myself.

Wohlstand
Chargin' Chuck
Chargin' Chuck
Posts: 2008
Joined: Tue Feb 11, 2014 4:44 pm
Flair: [ˈvoːlˌʃtant], 狐エンジニア
Pronouns: he/him
Contact:

Re: What are bak and json extensions used for in level folders?

Postby Wohlstand » Fri Mar 11, 2022 5:06 pm

These .bak files resulted because of the "safe-saving" mechanism and normally these files should be removed very fast, but they stay exist because you close Editor very fast. The purpose of this mechanism is to avoid file damage once your computer gets a power surge or BSoD that randomly kills the file (attempting to open it again may result in a blank file or a file filled with junk data). I think I'll tweak the thing to get these files been deleted faster and avoid them trashing your episode directory when you close an editor.

Wohlstand
Chargin' Chuck
Chargin' Chuck
Posts: 2008
Joined: Tue Feb 11, 2014 4:44 pm
Flair: [ˈvoːlˌʃtant], 狐エンジニア
Pronouns: he/him
Contact:

Re: What are bak and json extensions used for in level folders?

Postby Wohlstand » Sun Apr 03, 2022 2:28 pm

P.S. Just now I made the tweak that makes these files being removed when you close the Editor:

https://github.com/WohlSoft/Moondust-Pr ... caa9de5637


Return to “Help and Support”

Who is online

Users browsing this forum: No registered users and 1 guest

SMWCentralTalkhausMario Fan Games GalaxyKafukaMarioWikiSMBXEquipoEstelari