Help with Map Protection + Map Preview Screen

Level 7
Joined
Mar 16, 2014
Messages
169
Ever since reforged, you have to use MPQ editors to add a map preview image for the lobby screen because of Blizzard's extreme incompetence. You delete war3map.mmp and delete war3mapMap.blp, then insert your new 256x256 blp as a new war3mapMap.blp.

I got that working fine but there are two issues.

Issue 1: The map in the game is also the map preview image, which I don't want.

Issue 2: I cannot protect the map. Without doing this junk to change the map preview image, I always protect the map with Vex's Map Otimizer. However, changing the MPQ to insert the map preview image then using Vex's Map Optimizer causes the map to not show up in the list of maps inside of Warcraft 3. I tried doing it in the opposite order by first protecting the map then looking at the MPQ, but then the filenames are scrambled and it's impossible to find the war3mapMap.blp and war3map.mmp to delete them.

I was able to add a listfile to identify war3mapMap.blp and war3map.mmp, but regardless, in the MPQ editor, I cannot delete any files from the protected version of the map, so it's pointless.
 
Last edited:
For issue 1, Reforged added a new Jass native BlzChangeMinimapTerrainTex. If you don't know what that means, I can simplify it for you: rather than the old days where the game starts up and loads war3mapMap.blp for the minimap background, and then uses that image for your entire play session, now instead while the map is running you can make the image on the minimap change in response to some action. So for example if your map changed seasons from Fall to Winter while playing, you might replace an orange minimap with a white one.

I don't know if they added this to the Trigger Editor or if they only added it to the underlying game, but either way you should be able to make a trigger of this using "Custom Script" action type. Something like this:

  • Events
    • Game - Map Initialization
  • Conditions
  • Actions
    • Custom script: call BlzChangeMinimapTerrainTex("war3mapMapForReal.blp")
Then, import the minimap you want to actually use as war3mapMapForReal.blp in your Import Manager, and the game should swap to that image on startup -- so the preview screen shows the overridden "war3mapMap.blp" and the ingame screen shows the "ForReal" version. In my opinion, Reforged forcing you to do this is terrible for map compatibility and the "war3mapPreview" and "war3mapMap" names were much better, but unfortunately we have to deal with the reality we are presented with.

For your issue 2, you will have to wait until someone else can help with that. (I have stated my opinions elsewhere on Hive regarding map protection, and all things considered my opinions are most likely not useful to you in this case, and they render my technical skills equally non-useful. i.e. I can break any map protection I can create other than maps with the SIGN signature data at the bottom created with asymmetric cryptography, ergo I cannot create map protection.)
 
Top