TerrariaWorldParser

0.2.5

Terraria .WLD File Parser written in Swift
Xenoxiluna/Terraria-World-Parser

What's New

v0.2.5

2020-10-04T18:44:03Z

Updated SwiftyBytes Dependency

Terraria World Parser

Terraria 1.4.0.5 world parser in the Swift programing language

NOTE: Only Terraria 1.3.5.3 -1.4.0.5 is supported!

NOTE 2: Saving the edited world is not yet supported but will be soon.

Usage

This is a swift package. Add as a dependency in your project to use it. There is an experimental windows version available in the windows branch. An example can be found in example.swift

import TerrariaWorldParser

You can then open a world file by the following:

let path: String = "/Users/Xenoxiluna1/Desktop/test2.wld"
let nsData = try Data(contentsOf: URL(fileURLWithPath: path))
var world: WorldFile = WorldFile(data: nsData)
try world.parseWorldFile()

The world version is expected to be 194 or higher. Please be aware that this parser will fail if the world does not meet that condition.

Dependencies

References

License

Terraria World Parser is licensed under the MIT License

Description

  • Swift Tools 5.0.0
View More Packages from this Author

Dependencies

Last updated: Mon Oct 21 2024 14:11:28 GMT-0900 (Hawaii-Aleutian Daylight Time)