diff --git a/li/cil/oc/Settings.scala b/li/cil/oc/Settings.scala index e4f4d5d6a..0403bbb4a 100644 --- a/li/cil/oc/Settings.scala +++ b/li/cil/oc/Settings.scala @@ -106,7 +106,7 @@ class Settings(config: Config) { OpenComputers.log.warning("Bad number of HDD sizes, ignoring.") Array(2048, 4096, 8192) } - + val floppySize = config.getInt("filesystem.floppySize") max 0 val maxHandles = config.getInt("filesystem.maxHandles") max 0 val maxReadBuffer = config.getInt("filesystem.maxReadBuffer") max 0 diff --git a/li/cil/oc/server/driver/item/FileSystem.scala b/li/cil/oc/server/driver/item/FileSystem.scala index 82efb0ec4..50cfc0273 100644 --- a/li/cil/oc/server/driver/item/FileSystem.scala +++ b/li/cil/oc/server/driver/item/FileSystem.scala @@ -31,7 +31,7 @@ object FileSystem extends Item { } } else Items.multi.subItem(stack) match { case Some(hdd: HardDiskDrive) => createEnvironment(stack, hdd.kiloBytes * 1024) - case Some(disk: Disk) => createEnvironment(stack, 512 * 1024) + case Some(disk: Disk) => createEnvironment(stack, Settings.get.floppySize * 1024) case _ => null } diff --git a/reference.conf b/reference.conf index cbb4a127d..e029f3699 100644 --- a/reference.conf +++ b/reference.conf @@ -377,6 +377,9 @@ opencomputers { 8192 ] + # The size of writable floppy disks, in kilobytes. + floppySize: 512 + # The maximum number of file handles any single computer may have open at # a time. Note that this is *per filesystem*. Also note that this is only # enforced by the filesystem node - if an add-on decides to be fancy it