File Manager

Published by Goldorion on
Supported MCreator versions
2024.1
Tags / plugin type
Procedures
Variables
Icon
Downloads:
5679
Upvotes: 192
Plugin forum topic
About the plugin

File Manager is a plugin adding new procedure blocks allowing you to create and read your files! 

File Types

  • JSON
  • TXT (simple file reader/writer)
  • ZIP (5.7+)

Important Information

  • This version supports Forge 1.19.4 and 1.20.1 and Fabric 1.20.1

https://storage.ko-fi.com/cdn/brandasset/kofi_button_blue.png

The 2 following examples require File Manager 5.0 or after.

Create a JSON file

Create a json file

Read a JSON file

Read a JSON file

I made a tutorial covering this here.

Credits/License

Tutorial by NorthWestTrees

Tutorial on sub-JSON objects by NorthWestTrees

Tutorial by Cursed Warrior

Icon by Tobi-Wan#0482

Licensed under the GNU Lesser General Public License, version 2.1  

  • Appropriate credit must be provided to the creators and maintainers of this plugin.
  • Forked versions of this plugin must be distributed under the same license as this with attribution if distributed.
  • Changes must be stated if any modified works are to be distributed.
  • Under no circumstances you can state that the original creator endorses modified works.

Changelog

To see a complete changelog of the plugin, check this file.

5.10

* [#48] Add a new parameter to write lines at the end of TXT files
  * Note: Existing workspaces will get a build error due to the missing parameter. Previous behaviour was FALSE.
* [Bugfix #62] Write Json object caused a build error due to a missing import (again)

5.9.1

* [Bugfix #61] Some procedure blocks could cause build errors due to a missing import
* Added Persian language support

5.9

* Updated to MCreator 2024.1.15713
* Added support for NeoForge 1.20.4
Project members
Lead developer
License
GNU Lesser General Public License version 2.1 (LGPLv2.1)

Plugin downloads
File Manager 5.10 - file-manager_1.zipUploaded on: 04/23/2024 - 16:43   File size: 81.13 KB

Comments

Well yeah, great plugin, but how to actually properly make a new config file at start and not do "A block is broken"
Like it doesnt work with "Mod loaded on server-side" because it bugs out not making a proper file closing, its missing an "}" at the end and also breaks any formatting of the file flattening all tabs (and I suck at Java so I dont wanna attempt using this in code, couldnt properly fix it so far)

Yeah actually even just creating a "file" variable breaks it the same way as doing any more with the procedure, while "Mod loaded on server-side" is being used as the global trigger
Lookin like this:
```
import java.io.File;

public class GenerateConfigProcedure {
@Mod.EventBusSubscriber(bus = Mod.EventBusSubscriber.Bus.MOD, value = {Dist.DEDICATED_SERVER}) public class GenerateConfigProcedure {
@SubscribeEvent public static void init(FMLDedicatedServerSetupEvent event) {
execute();
}
public static void execute(
) {
File file = new File("");com.google.gson.JsonObject mainJsonObject = new com.google.gson.JsonObject();
}
}
HERE SHOULD BE ANOTHER ENDING BRACKET
```

perhaps start by stating which version of the Plugin, what version of MCreator and what generator version you using? I've been using this plugin (v5.7.3) for quite a while now and have no issues with it for Forge 1.20.1, MCreator 2023.3 and 2023.4 as well as older versions.

True, my bad, but its just not too well explained how to properly implement the basic saving; which in my opinion should probably be as soon as the mod is loaded on the server-side (depending on the mod)
In the screenshot its just an empty procedure and in the preview video its on "A block is broken" like just why

I am using 5.7.3 on 2023.3 with the Fabric loader, should have probably tested on Forge

Alright so its not a Fabric specific issue, it does a similar thing on Forge, doesnt flatten the file but it still messes with the formatting missing a } at the end
I uploaded some screenshots to imgur https://imgur.com/a/AAHNjGq

Hi, im trying to save blocks in area of 10 blocks and save them into a .json file is this possible?