inwc3 / wc3libs

Java library for reading and modifying Warcraft III maps and game files
Apache License 2.0
31 stars 11 forks source link

how can new a map or war3map.w3u without read a file? #63

Closed qq1053831109 closed 3 years ago

qq1053831109 commented 3 years ago

how can new a map or war3map.w3u without read a file? i need: W3u w3u = new W3u() w3u.write(file)

but it dont work! the test code is W3u w3u = new W3u(file) w3u.write(file)

WaterKnight commented 3 years ago

There is no proper support to build a map from scratch yet, i.e. maybe you can construct an empty mpq archive, but then you still need to add a couple of files and set the header to constitute a valid map the game can load.

w3u should work (the type is W3U not W3u). However, I am not currently maintaining this library and especially the changes from newer patches might not be considered.

qq1053831109 commented 3 years ago

okok this lib is good !