mirror of
https://github.com/MightyPirates/OpenComputers.git
synced 2025-09-14 09:46:53 -04:00
Merge branch 'master-MC1.7.10' into master-MC1.10
This commit is contained in:
commit
56eaafabdc
@ -200,13 +200,6 @@ object SaveHandler {
|
||||
}
|
||||
|
||||
def cleanSaveData(): Unit = {
|
||||
while (!chunkDirs.isEmpty) {
|
||||
val chunkPath = chunkDirs.poll()
|
||||
if (chunkPath.exists && chunkPath.isDirectory && chunkPath.list() != null) {
|
||||
for (file <- chunkPath.listFiles() if System.currentTimeMillis() - file.lastModified() > TimeToHoldOntoOldSaves) file.delete()
|
||||
}
|
||||
}
|
||||
|
||||
// Delete empty folders to keep the state folder clean.
|
||||
val emptyDirs = savePath.listFiles(new FileFilter {
|
||||
override def accept(file: File) = file.isDirectory &&
|
||||
|
@ -389,7 +389,7 @@ object DebugCard {
|
||||
def setGameType(context: Context, args: Arguments): Array[AnyRef] =
|
||||
withPlayer(player => {
|
||||
val gametype = args.checkString(0)
|
||||
player.setGameType(GameType.values.find(_.name == gametype).getOrElse(GameType.SURVIVAL))
|
||||
player.setGameType(GameType.values.find(_.getName == gametype).getOrElse(GameType.SURVIVAL))
|
||||
null
|
||||
})
|
||||
|
||||
|
@ -83,7 +83,8 @@ class UpgradeNavigation(val host: EnvironmentHost with Rotatable) extends prefab
|
||||
Map(
|
||||
"position" -> Array(delta.xCoord, delta.yCoord, delta.zCoord),
|
||||
"redstone" -> waypoint.maxInput,
|
||||
"label" -> waypoint.label
|
||||
"label" -> waypoint.label,
|
||||
"address" -> waypoint.node.address()
|
||||
)
|
||||
}).toArray)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user