What is MapViewer?
MapViewer is a program created by "ThirdOnion" for viewing Tanki maps, with a focus on graphics quality and streamlined use. Think of it as an upgraded Tanks Testing Tool, minus the tanks.
- Graphics comparable to the official game, with dynamic shadows, lighting, and fog.
- Fifteen different skyboxes with different lighting settings - two daytime modes, a winter mode, and four nighttime modes.
- A custom library that enables mapmakers to place lights on their maps.
- Support for 1.x, 3.x, and official maps.
- Streamlined UI that allows for easy map loading, skybox changes, and graphics settings adjustments.
- Includes all of the official Tanki proplibs, with support for custom proplibs.
MapViewer is made in Unity.
Download MapViewer v0.1.1 (~78 MB ZIP, ~147 MB unpacked):
Don't have any of your own maps to view? Download the official Tanki maps here:
https://www.dropbox.com/s/zec3x05brfd71bs/TankiMaps.zip?dl=0 (~15 MB zipped, 235 MB unzipped)
(The advantage of downloading from Github is that you can download maps individually and see which map files have been recently added. To download, navigate to a file, click "Raw" or "Download," then right-click the resulting text and select "Save as.")
In order to load a map file in AlternativaEditor, you'll need to make a slight modification. Open the file, and find the text map. It should be near the very start of the file.
Right after map add, version="1.0.Light". Thus the end result should look like this:
In order to load these maps in the Tanks Testing Tool, you will have to add spawn points. You can also view these maps with this MapViewer without any modifications.
There are over 200 map files in total. Included are the latest maps: Archipelago, Molotov MM, and Cross MM.
Once you've downloaded MapViewer_v0.1.zip, unzip it to wherever you like. This will be the resulting file structure:
To launch the application, open MapViewer.exe. Upon launch, you will be greeted with an empty view of a skybox. To open the main menu panel, press the "Tab" key.
Select the open file button, choose your map file, and if all goes well, your map should load. Close the main panel by pressing "Tab" again to enable movement around the map.
Move the camera with the WASD and QE keys, and look around with the arrow keys. Click (without dragging) to toggle mouselook. Hold shift for faster movement.
To change the skybox, open the main panel, and select the skybox icon. You will be presented with a list of skyboxes to choose from.
Note that different skyboxes have different lighting settings. Here is a map with several different skyboxes:
To close any panel, simply click somewhere in the empty space around the panel.
MapViewer allows mapmakers to create lights within their maps. They can be used to light billboards at night . . .
The lighting workflow is as such:
1. First, find the "PointLight" folder in your MapViewer folder. Load it into AlternativaEditor as you would any library.
2. The PointLight library contains a "light cube." Place light cubes on your map wherever you want a light emitted uniformly in all directions. In MapViewer, these light cubes will be converted into point lights. To change the color of a light, change the texture of a light cube. Blue light cubes will become blue lights, red light cubes red lights, etc.
3. Save your map and load it into MapViewer.
Shadows - set the quality of shadows, or disable them. Note that up close, the difference between high and low-quality shadows is less noticeable than it is from afar. Default: low.
Lights - disable or enable point lights in the map. If you are viewing a map during the day, it is recommended to disable point lights, since they aren't very noticeable in the sun. Default: off.
Render path - Choose between forward and deferred. Default: forward.
What's the difference between forward and deferred rendering, and which one should I use?
Short answer: Use deferred rendering ONLY if your map has point lights and you want accurate shadows, and ONLY if the Lights settings are enabled. Use forward rendering otherwise, as it offers significantly better performance.
Without going into the details of how each path works, forward rendering is faster and supports fog and anti-aliasing, but has a limit on how many lights it can accurately render. Deferred rendering, on the other hand, can render many lights accurately, but has a higher performance overhead, does not support certain features such as fog and anti-aliasing, and is not supported on some hardware.
Maps that do not have point lights have only one light source - a single directional light that represents the light coming from the sun (or moon). In this situation, forward rendering is the optimal choice since only a single light needs to be rendered, and the renderer can handle it. However, once more lights are introduced into the equation, forward rendering becomes sub-optimal since the more lights there are added to a map, the less accurately they will be rendered as the forward renderer cannot do accurate lighting calculations for all of them. Furthermore, forward rendering does not render shadows from point lights - which results in light "bleeding" out from behind walls.
Because of the way deferred rendering works, it can accurately render many lights - at the cost of certain features, and most importantly, performance. It is pointless to use deferred rendering with maps that do not have any point lights - that is, they only have the one-directional light - because the forward renderer is faster and can render a single light without any issues. Thus, deferred rendering should only be used when there are multiple lights on a map and if your machine can handle it.
You can learn more about rendering paths in Unity here.
Fog - toggle fog. Default: on.
Anti-aliasing - toggle anti-aliasing and set its quality. Default: off. More info: https://www.gamespot.com/gallery/pc-graphics-settings-explained-anti-aliasing-v-syn/2900-1100/
Anisotropic filtering - toggle anisotropic filtering. Default: off. See above link.
V-sync - toggle v-sync. Limits your framerate to your monitor refresh rate in order to reduce screen-tearing. Enabling this setting is recommended, but by default it is disabled. See above link.
Show FPS - show or hide the FPS counter in the top right hand corner. Default: off.
Sprites - toggle sprites on the map. Default: on
Camera look speed - affects the speed of both arrow key and mouselook sensitivity when viewing maps. Default: right in the middle.
A new info panel has been added in version 0.1.1. It shows the number of props, sprites, and lights in a map.
MapViewer uses the excellent Simple File Browser by yasirkula: https://forum.unity.com/threads/simple-file-browser-open-source.441908/
Please report any bugs and problems, and leave your feedback, suggestions, etc. MapViewer is an ongoing project here.