EDIT:
There is version 4.0 thread:
What is new in version 4.0? website view with NPCs and monsters search configurable town names and positions - big names visible on map possibility to link NPCs and monsters ex. mymap.com/#npc,Xodet , mymap.com/#monster,Dragon+Lord scripts to run 'zoom levels' and 'compression' on 16 cores on...
otland.net
on GitHub is available version 5.1:
add LUA function to generate big images
github.com
What is new in version 2.0?
- much faster generation
- - - you can run PHP scripts on all CPU cores
- - - much calculations moved to C++, it increased speed for around 400%
- easier to use
- split map to parts and load it one after another - you can run map generation with ~1GB ram, even if map uses few GB when you start server (works on 32bit systems!)
What is this?
It's automatic map image generator [for website view 'like GoogleMaps'].
It generates OTS map .png images (each 8x8 tiles).
-- BINARY (.EXE) ATTACHHED! YOU DO NOT HAVE TO COMPILE! --
To run binary you may need to install VS2015 Redist first (choose x86 version):
Download Microsoft Visual C++ 2015 Redistributable Update 3 from Official Microsoft Download Center
It contains configured JavaScript and HTML to view map on website like this:
How to use?
1. Download otclient_mapgen from GitHub:
GitHub - gesior/otclient_mapgen: Open Tibia map images generator [good for Leaflets]. Loads .otbm file and generate .png images 256x256 px
and compile it like normal OTClient:
Compiling on Windows · edubart/otclient Wiki · GitHub
Compiling on Linux · edubart/otclient Wiki · GitHub
Compiling on Mac OS X · edubart/otclient Wiki · GitHub
Compiling for Android · edubart/otclient Wiki · GitHub
OR DOWNLOAD BINARY (.EXE) ATTACHED
2. Copy your server
client .spr and .dat files to OTClient folder:
data/things/HERE_PROTOCOL_VERSION/
3. Copy your server
data/items/items.otb file to OTClient folder:
data/things/HERE_PROTOCOL_VERSION/
4. Copy your server
data/world/MAP_NAME.otbm file to OTClient folder:
data/map.otbm
5. Run
otclient.exe
6. Type in client terminal command like:
prepareClient(1076, '/things/1076/items.otb', '/map.otbm', 8, 5)
- with you client protocol version,
- valid paths to items.otb and map.otbm,
- number of threads to run (in example it's 8),
- number of map parts (OTC will split map to parts to reduce maximum RAM usage)
[Paths are relational, so start path with '/' to start in folder 'data', access to other folders in computer is blocked]
7. OTClient will show in 10-50 seconds (it will freez client, do not close it, just wait) something like:
8. Type in client terminal command:
generateMap('all', 30)
OTClient will report progress in terminal.
9. Your map images will appear in your system 'user' directory
%HOMEPATH%/otclient - Windows, open it in folder explorer
$({HOME}/.otclient - Linux, 'cd' to it, this folder is invisible, but you can navigate to it
10. Copy folder
map from folder metioned in previous step to folder
website_and_php_files of otclient_mapgen.
--- NEXT STEPS REQUIRE PHP INSTALLED IN SYSTEM ---
--- LINUX: FOR GENERATION TIME, SET FOLDER website_and_php_files RIGHTS TO 777 ---
11. Execute (in system terminal):
Code:
php 1_pre_tile_generator.php
12. Execute (command parameter is map 'floor'):
- You can execute these commands in any order.
- You can open few terminals and run few commands at once to generate it faster (use all CPU cores).
Code:
php 2_tile_generator.php 0
php 2_tile_generator.php 1
php 2_tile_generator.php 2
php 2_tile_generator.php 3
php 2_tile_generator.php 4
php 2_tile_generator.php 5
php 2_tile_generator.php 6
php 2_tile_generator.php 7
php 2_tile_generator.php 8
php 2_tile_generator.php 9
php 2_tile_generator.php 10
php 2_tile_generator.php 11
php 2_tile_generator.php 12
php 2_tile_generator.php 13
php 2_tile_generator.php 14
php 2_tile_generator.php 15
php 2_tile_generator.php 16
13. Execute:
14. Execute (command parameter is map 'floor'):
- You can set compression quality in file 4_compress.php (line: $quality = 80
- You can execute these commands in any order.
- You can open few terminals and run few commands at once to generate it faster (use all CPU cores).
Code:
php 4_compress.php 0
php 4_compress.php 1
php 4_compress.php 2
php 4_compress.php 3
php 4_compress.php 4
php 4_compress.php 5
php 4_compress.php 6
php 4_compress.php 7
php 4_compress.php 8
php 4_compress.php 9
php 4_compress.php 10
php 4_compress.php 11
php 4_compress.php 12
php 4_compress.php 13
php 4_compress.php 14
php 4_compress.php 15
php 4_compress.php 16
15. Move folder
website_and_php_files/map_viewer to your webserver - it contains all images and website scripts to view them (Leaflet Map).
16. Configure
map_viewer. Config is at start of
map.js file:
- You can keep images on other webserver. Set imagesUrl to URL of this server like: '
http://myserver.com/map_images/'
Code:
imagesUrl: 'map/', // URL to folder with 'zoom levels' (folders with names 0-16)
imagesExtension: '.jpg',
mapName: 'RL MAP?',
startPosition: {x: 1000, y: 1000, z: 7},
startZoom: 14,
minZoom: 4,
maxZoom: 18, // maximum zoom with full quality is 16
Added item/outfit generator to sources (you can use binary file v3 to unpack outfits/items):
Feature - Unpack items/outfits from any client to PNG with OTClient!
and merged newest edubart/otclient (just to keep it up to date, there is no new features):
GitHub - gesior/otclient_mapgen: Open Tibia map images generator [good for Leaflets]. Loads .otbm file and generate .png images 256x256 px