1. Are you planning to upload your awesome tool to Hive? Please review the rules here.
    July 9, 2018: The rules for the Tool Section have been revised. Please be sure to read the revisions.
    Dismiss Notice
  2. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  3. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still haven't received your rank award? Then please contact the administration.
    Dismiss Notice
  4. Lead your forces to battle in the 15th Techtree Contest. The call is yours, commander!
    Dismiss Notice
  5. The reforging of the races is complete. Come see the 14th Techtree Contest Results.
    Dismiss Notice
  6. It's time to choose your horse in the race - the 32nd Modeling Contest Poll is up!
    Dismiss Notice
  7. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

W3x2Lni v2.7.1

Submitted by actboy168
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.1 (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. [ATTACH] I am...
  1. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    I have tested again, simply copying ability that have not been modified is totally ineffective in WC3, even as an item ability.
    If you found this is wrong, plz show me the demo map, thank you!
     
  2. sonphamthe11H

    sonphamthe11H

    Joined:
    Mar 6, 2017
    Messages:
    127
    Resources:
    0
    Resources:
    0
    I have an idea for the map optimization
    Why wont you remove the stardard units which arent edited by the map maker?
    The map will lighter and load faster
    Just keep custom units and modified standard ones
     
  3. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    It's very hard for map maker. For example, the ability "AOhx" needs to refer to a large number of small animals.
     
  4. sonphamthe11H

    sonphamthe11H

    Joined:
    Mar 6, 2017
    Messages:
    127
    Resources:
    0
    Resources:
    0
    “which is not modified”
    I mean you only export changed objects and custom ones
     
  5. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    You customize a ability based on 'AOhk', which transforms the unit into 'npig'. And 'npig' is an unchanged default object, and I have to keep it.

    On the other hand, many maps that have been updated over a long time contain many obsolete custom objects that should be removed or they may refer to more unused objects.
     
  6. sonphamthe11H

    sonphamthe11H

    Joined:
    Mar 6, 2017
    Messages:
    127
    Resources:
    0
    Resources:
    0
    warcraft keep it in their base slks,so,'npig' will still work without being stored in map slks
     
  7. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    No, the SLK in the map overrides the built-in SLK with the same name, so the object 'npig' does not exist.
     
  8. BLOKKADE

    BLOKKADE

    Joined:
    May 18, 2018
    Messages:
    20
    Resources:
    0
    Resources:
    0
    Thanks, It's a ton of abilities so I'll try to use that plugin!

    Ah okay, My map has over 400 abilities with 9 levels, will it have any other effect while playing or is it just a report?

    Almost all of them have modifications. Some of them are just used for effects or are dummy abilities used by triggers, though.

    A08S, based on Arel:
    upload_2019-3-20_8-40-33.png
    A09H, based on Ald0
    upload_2019-3-20_8-41-39.png
    A055, based on Ali1:
    upload_2019-3-20_8-42-10.png

    A065, based on Alxm:
    upload_2019-3-20_8-42-44.png

    If you need the map I'll try and post it later today.
     
  9. sonphamthe11H

    sonphamthe11H

    Joined:
    Mar 6, 2017
    Messages:
    127
    Resources:
    0
    Resources:
    0
    ah,I see the point
     
  10. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    Please give me the map, I want to check why W3x2lni thinks they have not been modified.
     
  11. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    I've checked the map and found out why W3x2lni dose not think these objects have been modified.

    W3x2lni parses binary files following the rules of this document: W3M and W3X Files Format

    The rule says 'int: end of modification structure (this is either 0, or equal to the original object ID or equal to the new object ID of the current object, when reading files you can use this to check if the format is correct, when writing a file you should use the new object ID of the current object here)'

    So I followed this rule, checking the last 4 bytes of each data, and discarding the data if the check failed. This check is really necessary. I have encountered some maps that contain garbage data. WC3 and the WE will ignore the garbage data, and W3x2lni will also ignore the garbage data by this check.

    But in his map, the last 4 bytes of all data in 'A08S' (original ID is 'Arel' ) is 'AI01', so W3x2lni discarded all of these data. However, WE thinks that all these data are correct.

    So is anyone knows the exact rules?
     
  12. BLOKKADE

    BLOKKADE

    Joined:
    May 18, 2018
    Messages:
    20
    Resources:
    0
    Resources:
    0
    Is it possible that my map is just corrupt or something?

    EDIT: When I copy A08S into a new ability 'A0EM' it still happens, however if I create a copy of the original Arel ability and edit that it doesn't happen.

    Don't know if that helps or not, I have no idea what's happening. But I guess I can "fix" my map by recreating 60 abilities again.

    EDIT2: Copying data from other abilities based on the same original abilities into the not working ability in Lni format also fixes it. It seems to remove editor suffix data, race data and names (and maybe other stuff too) when converted to Lni though, even for abilities that aren't mentioned in the log.
     
    Last edited: Mar 21, 2019
  13. sonphamthe11H

    sonphamthe11H

    Joined:
    Mar 6, 2017
    Messages:
    127
    Resources:
    0
    Resources:
    0
    Could u solve this problem?
    When I convert my map to slk format,then convert them back to object ( to remove unused object ),then all the “use in editor” of all units turn to false?
    Pls fix
     
  14. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    Slk is a format for play. Converting to SLK is a lossy conversion, so please don't convert map to SLK and back again.
     
  15. sonphamthe11H

    sonphamthe11H

    Joined:
    Mar 6, 2017
    Messages:
    127
    Resources:
    0
    Resources:
    0
    Because slk is easier and faster to edit things,but I need the object to code
     
  16. Raspberrys

    Raspberrys

    Joined:
    Feb 12, 2019
    Messages:
    10
    Resources:
    0
    Resources:
    0
    Well this new version completely broke my map lol, it replaced my spells with other spells for some reason, caused workers to no longer be able to harvest wood, and thats what i've caught so far.

    anyway to download the previous version please?
     
  17. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    Please give me the map to check what happened.
     
  18. Raspberrys

    Raspberrys

    Joined:
    Feb 12, 2019
    Messages:
    10
    Resources:
    0
    Resources:
    0
    You want the map before the SLK change or after?
     
  19. sumneko

    sumneko

    Joined:
    May 31, 2018
    Messages:
    83
    Resources:
    0
    Resources:
    0
    Both
     
  20. Raspberrys

    Raspberrys

    Joined:
    Feb 12, 2019
    Messages:
    10
    Resources:
    0
    Resources:
    0
    I wanted to see if it was my map specifically so i made a blank map and i still was able to produce the same results, it will give me different abilities... you'll see it. When you play the _slk version some of those abilities from the original get switched out for things like spawn a unit or berserk?

    Test both in single-player. i named the original nonslk so when you look at game list you dont see 2 of the same names :p

    using W3x2Lni v2.5.0

    [x]Remove WE-only files
    [x]Optimize doodads and destrucables
    ...thats it
     

    Attached Files: