W3x2Lni v2.7.2

This bundle is marked as approved. It works and satisfies the submission rules.
W3x2Lni is a wc3 map management tool. It helps you to manage your maps when developing or publishing.We defined 3 formats for a wc3 map, and w3x2Lni allows you to convert your maps amongst these 3 formats which are `Lni`, `Obj` and `Slk`.

> Lni
`Lni` is a VCS (like git, svn) friendly format. It looks like a directory. Most binary files in w3x will be converted into plain text files (yes! human-readable) by w3x2Lni which will also organize and categorize these text files.

> Obj
`Obj` is a wc3-readable and WE-readable format. If you want to open your map with WE, convert your map into this format.

> Slk
`Slk` is only readable by wc3 and should be used for final distribution. W3x2Lni enables multiple optimization for this format, including:

* Objects converted to slk
* Removed unreferenced objects
* Removed WE-only files
* Inlined WTS strings
* Compressed mdx
* Removed comments and unncessary white spaces in the script
* obfuscated variable and function name

W3x2Lni comes with war3 1.27.1 English data files. But it may not meet everyone's needs, you can use `w2l mpq <war3_path>` to extract data files.


For more information see the documentation.


W3x2Lni is a open source project.We welcome any pull request, e.g. improving the English text or writing English documents.
Contents

W3x2Lni v2.7.2 (Binary)

Reviews
eejin
The tool works as one would expect. The UI is nice and to the point. Only thing I am missing is a back button wen you have chosen a conversion mode. You also cannot scroll horizontally when viewing the log when converting to Lni. I am looking...
Level 23
Joined
Mar 15, 2012
Messages
2,688
Oh mine. Bless the one @actboy168, who made this optimization. This is even surpass Vexorian's Optimization, Wc3SLKOpt and other optimization too. Very clean UI, easy to use, fast progress and most importantly, it allow to optimize the huge object data all at one without bugs. Not to mention, it supports different versions of WE. Seriously, you deserve more +rep than this.
What does this do better then vex's and wc3slkopt?
 
Level 14
Joined
Jun 15, 2016
Messages
745
What does this do better then vex's and wc3slkopt?
There are few points coming from this new tool, compared to:
1. Wc3slkopt
- Similar to wc3slkopt, compress MDX but not completely remove all vertex, which may causes twisted models. For some unknown reasons, this tool generates much faster and optimizes effect exactly as it claims, resulting in-game boost.
- Does not have more options to optimize each object data like it seems, this tool keeps all tooltips of WE intact, while wc3slkopt wipe out all of them. With this tool, we get also much smaller size map and huge loading boost similar to wc3slkopt
2. Vex's (VXJWTSOPT)
- This tool is very easy to use, and right now keep updating for latest versions. It optimizes trigger scripts faster and support 3 formats!!!, and does thing exactly what it claims. Vex's is problematic, it requires more knowledge to use it and the map can become unplayable and not even appear during map selection screen (if you use different kinds of scripts such as vJass, USWM, cJass, Lua at the same time). Using Vex's optimization actually increase map even bigger and produce more files.

I feel like this tool is a combination of optimization tools, but not mess everything up and straight to the point.

But still there are some flaws of this tools, it need to be updated to avoid:
- Expose Icon position of some hidden-system abilities, (For example, Select Hero options, Sharing Shop), what you get is a missing tooltip icon (basically Select User icon) which over-laps other items while playing).--
- It does something to hotkey system as people said, but i'm not too sure. Need more tests.
 
Last edited:
Level 23
Joined
Mar 15, 2012
Messages
2,688
There are few points coming from this new tools, compared to:
1. Wc3slkopt
- Similar to wc3slkopt, compress MDX but not completely remove all vertex, which may causes twisted models. For some unknown reasons, this tool generate much faster and optimize effect exactly as it claims, resulting in-game boost.
- Do not have more options to optimize each object data like it seems, this tools keep all tooltips of WE intact, while wc3slkopt wipe out all of them. With this tool, we get also much smaller size map and huge loading boost similar to wc3slkopt
2. Vex's (VXJWTSOPT)
- This tool is very easy to use, and right now keep updating for latest versions. It optimizes trigger scripts faster and support 3 formats!!!, and does thing exactly what it claims. Vex's is problematic, it requires more knowledge to use it and the map can become unplayable and not even appear during map selection screen (if you use different kinds of scripts such as vJass, USWM, cJass, Lua at the same time). Using Vex's optimization actually increase map even bigger and produce more files.

I feel like this tool is a combination of optimization tools, but not mess everything up and straight to the point.

But still there are some flaws of this tools, it need to be updated to avoid:
- Expose Icon position of some hidden-system abilities, (For example, Select Hero options, Sharing Shop), what you get is a missing tooltip icon (basically Select User icon) which over-laps other items while playing).--
- It does something to hotkey system as people said, but i'm not too sure. Need more tests.
It also breaks engineering upgrade and other stuff if one uses that option so its better not to use it, I have forgotten if that options useable in wc3slkopt. So I agree its better then wc3slkopt however I am unsure about it being better then vex's, would need a second opinion I suppose.
 
Level 11
Joined
Jun 12, 2010
Messages
414
It also breaks engineering upgrade and other stuff if one uses that option so its better not to use it, I have forgotten if that options useable in wc3slkopt. So I agree its better then wc3slkopt however I am unsure about it being better then vex's, would need a second opinion I suppose.
The most awesome use of this tool by far is the ability to convert map data to a readable and easy to parse format, so you can edit object data programatically using whatever programming language you wish. This is something that Vex's optimizer could never do (and never set out to do).

When it comes to optimizing, it was basically as good as Vex's optimizer before Reforged broke a few things related to SLK files (last time I tested it, anynow... might've been fixed with an update?). It doesn't have constant inlining though, which kinda sucks, and you can't opt out of SLK conversion.

So I think optimization-wise, with both tools at their prime when it comes to wc3 not breaking them, I'd say there wasn't that big a difference. But when it comes to overall usefulness Vex's optimizer can't even compare to w3x2lni... it's closer to the level of vJASS/Jass Helper.
 
Level 3
Joined
May 5, 2018
Messages
31
Extract this file into the "data" folder in your w3x2lni folder. Then open config.ini with a text editor (such as Notepad) and find a line with:

data = enUS-1.27.1

Then change it to:

data = enUS-1.32.8

Okay... I've made and slk optimized again map. Looks far better, weird icons has dissapeared along with bugs. But upgrade hotkeys are still gone beyond 1st level of upgrade.
Also noticed some werid behaviour: on first try - I've set up all 4 basic checks and optimize doodad check - and Selecting button in shops (Select User Button) has lost its icon (became Sammy) and changed position from X3;Y2 to X0;Y0, huh weird. On second try - set up only optimizing doodad option and Select User button remained unaffected
 
Level 4
Joined
May 31, 2018
Messages
92
I'm glad many people like this tool.
However, I am no longer engaged in WC3 related development, so I will not actively fix bugs. (in the past, 80% of bugs were found and fixed in my own use).
But I will continue to maintain this tool. If you find any bugs, you can tell me on this post or GitHub. It's better to attach the specific reproduction process. The demo map is the best.
 
Level 3
Joined
May 5, 2018
Messages
31
I'm glad many people like this tool.
However, I am no longer engaged in WC3 related development, so I will not actively fix bugs. (in the past, 80% of bugs were found and fixed in my own use).
But I will continue to maintain this tool. If you find any bugs, you can tell me on this post or GitHub. It's better to attach the specific reproduction process. The demo map is the best.
What about hotkey loses for upgrades beyond first levels (for example like Iron Forged Swords upgrade)? Will be this fixed?
 
Level 2
Joined
Apr 16, 2017
Messages
13
看看这是不是缺陷
 

Attachments

  • zinc.zip
    20.5 KB · Views: 139
  • QQ截图20200923012415.png
    QQ截图20200923012415.png
    47.7 KB · Views: 178
Level 4
Joined
May 31, 2018
Messages
92
看看这是不是缺陷
如果你用的YDWE,你需要把 `config.ini` 里的 `[global] -> data_ui` 设置为 `${YDWE}` 。
我推荐你去 【SLK优化器】W3x2Lni 发布贴_魔兽地图编辑器吧_百度贴吧 这里下载,从这里下载的 w3x2lni 默认使用 YDWE 相关的配置。
如果你用的是其他修改过UI的编辑器(包括其他以YDWE为基础进行二次修改导致无法识别为YDWE的编辑器),你需要手动将编辑器中的UI文件放置到 `data\zhCN-1.24.4\ui` 目录中。
 
Level 3
Joined
May 5, 2018
Messages
31
This has been fixed.
You could manual update the scripts from Github.
Yeah, I saw changes on github, and tried to copy these changes, but i have messed up with the changes in metadata ini of game datasets and placed in wrong place (wrong line of code) a variable cant_cut = true, and then I thought it was an unsucessfull attempt to fix hotkeys xD.
Thanks for telling, so I've now finally noticed my mistake and changed to the right thing and now can feel the might of hotkeys for upgrades once again in SLK optimization :D.

But I've noticed a minor issue that SLK optimization removes (nullifies) imported UnitSkin.txt, which is kinda supposed to be a way to make a sd/hd compability (at least in the bright future, for now it doesn't work with custom units, only with the original ones :peasant-bowing:). Any ways/plans to deal with such an issue?
 
Last edited:
Level 4
Joined
May 31, 2018
Messages
92
Yeah, I saw changes on github, and tried to copy these changes, but i have messed up with the changes in metadata ini of game datasets and placed in wrong place (wrong line of code) a variable cant_cut = true, and then I thought it was an unsucessfull attempt to fix hotkeys xD.
Thanks for telling, so I've now finally noticed my mistake and changed to the right thing and now can feel the might of hotkeys for upgrades once again in SLK optimization :D.

But I've noticed a minor issue that SLK optimization removes (nullifies) imported UnitSkin.txt, which is kinda supposed to be a way to make a sd/hd compability (at least in the bright future, for now it doesn't work with custom units, only with the original ones :peasant-bowing:). Any ways/plans to deal with such an issue?
Please give me a demon map, thank you.
 
Level 3
Joined
May 5, 2018
Messages
31
Please give me a demon map, thank you.
There. If I remember correctly I've changed the Sorceress model to... Jailor Kassan :ogre_love: model in Reforged via imported UnitSkins.txt

Also I've noticed another issue. Lets say I've some unit which is a flying (which can't move itself) building, which can train units and attack nearby enemies. It doesn't have buttons of Attack or Stop. But if I SLK-optimize map, it will start to have these buttons, which disrupts button orders on this unit (building). How to fix it?

Update 12.10.2020: I've found out another(!) issue. SLK optimization somehow transforms abilities descriptions, and it kinda tricky works, descriptions starts to lose float numbers and only integers remain like lets say I've some ability, its duration on 1st level is like 1.5 seconds, so description (in the Editor) will be "Bla bla bla <A000,Dur1,.> seconds" which will transform in game to "Bla bla bla 1.5 seconds", but SLK Optimization will transform it into "Bla bla bla 1 seconds" which is kinda misleading, and I think its a bug/issue which needs to be fixed

Update #2: I've found out the reason behind this was a checked option in config for SLK optimization "Computed_text = true" which turned abilities description to text and managed to lie about it (like mentioned turning 1.5 seconds to 1 seconds in text). Very confusing that it was a hidden from usual user eyes.
 

Attachments

  • UnisSkins.rar
    594.1 KB · Views: 131
Last edited:
Level 3
Joined
Jun 19, 2018
Messages
25
It's really handy you can use program's log to find errors in tooltips and other bad references.
I would also suggest that log should (optionally) output what object it cleared so that mapmaker could clear this garbage objects from unoptimised map manually.
 
Level 1
Joined
Dec 7, 2020
Messages
1
Hello
Please add the setting for the open folder and the save folder for the map in the configuration file.
 

Dr Super Good

Spell Reviewer
Level 60
Joined
Jan 18, 2005
Messages
26,837
lost my unit's weapon sound if i converted to slk and only use Remove WE-Only files,does anyone met this situation?
I recommend mentioning the version of Warcraft III you are using. I think Reforged changed a lot of the asset paths so maybe old optimization tricks no longer work or need to be made more robust to accommodate this change.
 
Level 6
Joined
Sep 1, 2016
Messages
55
I recommend mentioning the version of Warcraft III you are using. I think Reforged changed a lot of the asset paths so maybe old optimization tricks no longer work or need to be made more robust to accommodate this change.
Its 1.32 version,only use this tool can protect my map,the others tools report "couldnt find the map's script file".
 
Level 9
Joined
Mar 26, 2017
Messages
370
I have some small issues as well when converting to slk (1.32)
-It removes custom command buttons
-The ability 'Attribute Bonus' gains the Devotion Aura tooltip.

Unfortunate, this is the only tool that helps optimize my map. Vexorian even balloons my map size by 50%.
 
Level 4
Joined
May 31, 2018
Messages
92
Hello everyone.
I have been away from the Warcraft-related field for a long time, and I have devoted all my energy to my other projects.
I promised to continue to maintain this project, so I plan to allocate some energy to fix some bugs recently.
Please provide the following information for the bug reported:

  • Concise and clear description of the problem
  • A demo map that can reproduce the problem, with steps to reproduce.

For example: after I use some options to optimize the slk, the specific attribute of a specific unit is wrong, the correct effect should be A, but it becomes B after optimization.

Since I have hardly used 1.32 before, some bugs that only appeared in 1.32 may be difficult to fix, so I can only do my best.

At the same time, anyone is welcome to participate in the maintenance of the project.
 
Level 11
Joined
Jun 2, 2009
Messages
554
Hello. Honestly i don't get it. I was looking for "downgrade my map" and i find myself in here.
I was accidently saved my map with Reforged Editor, so i cannot play it in older versions and i cannot open it with older versions of world editor.
This tool can help me about that?
 
Level 17
Joined
May 14, 2021
Messages
462
Hello. Honestly i don't get it. I was looking for "downgrade my map" and i find myself in here.
I was accidently saved my map with Reforged Editor, so i cannot play it in older versions and i cannot open it with older versions of world editor.
This tool can help me about that?
I think the following solution might be a good choice for you if you encounter this problem rather than using this tool:
How to Downgrade a Map
 
Level 12
Joined
Oct 18, 2013
Messages
634
This is removing tooltip for "Select User" on shops. Do I need to edit the tooltip for it to not delete? Also, I have it in the bottom right of the command board, and after running this it is set to top left. How do I prevent this?
 
Level 1
Joined
Sep 1, 2019
Messages
2
Today, i try to convert map .SLK to OBJ, but it say "Did not find Listfile" . Can anyone know how to fix this! Tks
 
Level 8
Joined
Jul 12, 2018
Messages
409
EDIT: Ignore, this problem was fixed by adding the 1.32.8 files as described by Guhun above.

Looks like converting to slk from w3x deletes some custom models from the map. The example i ran into is Ujimasa Hoso's Fel Minion:

It becomes an unselectable shadow in my map after i SLK-ify it.

I tried with all options unchecked except for "Extra check".
Using latest version of wc3 and editor.
 
Last edited:
Level 8
Joined
May 31, 2019
Messages
106
When I convert a 1.28 map to .slk, the .txt files are all empty (0kb)

Also, the generated UnitBalance.slk is different from what war3 1.28 uses. (I replaced the Units folder in "data\enUS-1.27.1" with 1.28's Units folder).

1.28's has this extra unnamed column after level and before type, that is just a boolean. probably unused, but the game expects it to be there nonetheless, and so every column after it ends up null because the generated slk's don't have this column.

unitbalancecolumnmismatch.jpg


Simply adding this column to the slk generated by W3x2Lni fixes the issue, but it is a little bothersome.
 
Last edited:
Level 13
Joined
Feb 25, 2013
Messages
202
When I convert a 1.28 map to .slk, the .txt files are all empty (0kb)

Also, the generated UnitBalance.slk is different from what war3 1.28 uses. (I replaced the Units folder in "data\enUS-1.27.1" with 1.28's Units folder).

1.28's has this extra unnamed column after level and before type, that is just a boolean. probably unused, but the game expects it to be there nonetheless, and so every column after it ends up null because the generated slk's don't have this column.

View attachment 390838

Simply adding this column to the slk generated by W3x2Lni fixes the issue, but it is a little bothersome.
Ever since the Warcraft 3 demo's time, the column with index 6 may have been unused :D I have zero idea what it is or what it's for, but looking at all the SLK files I had access to (1.26-War3&War3x, 1.28-War3&War3x, 1.29-War3&War3x, Demo, 1.30.1, 1.30.3, 1.31.1, and 1.32.10), it's never been listen in the header

Do note that not all units have it set to FALSE: Phoenix, Phoenix Egg, Water Elementals, Lava Spawn, Arcane Sanctum, Barracks, Cannon Tower, Spirit Wolves, Tree of Life, SlaughterHouse, Quillbeast, Chicken, Murloc Hut, and many many more (378 hits of it being "TRUE" in the 1.32.10 UnitBalance.slk, as opposed to 486 instances it's set to "FALSE")
 
Level 6
Joined
Apr 5, 2020
Messages
34
Recently I tried to work with this program and everything worked. Until I made a lot of different changes and decided to convert the map to lni. 1 warning began to appear, from the description of which I cannot understand the source of the problem. +There is no "trigger" folder in the received lni-folder.

What is the problem and how can I fix it?
1.png
 
Level 1
Joined
Feb 26, 2022
Messages
1
Hi, I'm trying to translate a Russian map into English and I am getting this error. The *.w3a file also increases in size by 20x after converting the mpq to slk.
Capture.PNG
 
Level 3
Joined
Mar 30, 2022
Messages
17
after i add new blp and then convert so slk. i cannot upload the map to epicwar. it say Map is missing 'war3map.w3i'
without add new blp and convert to slk i can upload it without error. how to fix these problem?
 
Top