• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

OpenTibia OTClient that unpack map.otbm to .png files

I'm having an issue:

Can somebody confirm this?

VmqARes.png
 
I hate that I can't edit my posts.

That's how images looks like after running all gesior's php scripts.

Only tables has this thing now.

tURZIju.png


Also, I want to report another thing.

Floor +2 has this black lines
Black tiles size increase by 1 sqm each floor (+2, +3, ..., +7)

9Vzw8P9.png
 
I'm having an issue:

Can somebody confirm this?

VmqARes.png
I think I found problem with tables. There is some 'height' code missing in .png generator (compared to 'render game window' code). I will fix it soon, but next week I start OTS and I don't have time :(

About black lines.. I don't know. What browser do you use? Lines are at same positions no matter what zoom you set?
Do you see same lines on my server map? My server map:
http://map.eloth.net/#zoom,14,position,32341,32216,7
 
I think I found problem with tables. There is some 'height' code missing in .png generator (compared to 'render game window' code). I will fix it soon, but next week I start OTS and I don't have time :(

About black lines.. I don't know. What browser do you use? Lines are at same positions no matter what zoom you set?
Do you see same lines on my server map? My server map:
http://map.eloth.net/#zoom,14,position,32341,32216,7

Thanks for the reply.

I'm using Chrome. There is a link that can explain better this bug: https://imgur.com/a/foOeo

Your server map doesn't have black lines for me (you can see on this link as well).
 
Compiling on Windows is also waste of time for other reason:
Windows compilator users 32-bit libraries and it limits program RAM to ~2 GB, so you can't load map bigger then ~50MB

I got 2 ideas:
1. Make OTClient load part of map (from X1 to X2, all floors) to not exceeed ~1GB ram. Render images of that part, then reload map and load other part. I'm just not sure how look .otbm format and how it will work.
2. Put all rendering in C++. Maybe it will be faster then PHP version. I made most of it in PHP, because I had problem with 'shadow' effect (lower floors) in C++ and first versions of 'otclient_mapgen' crash every few minutes.
 
Compiling on Windows is also waste of time for other reason:
Windows compilator users 32-bit libraries and it limits program RAM to ~2 GB, so you can't load map bigger then ~50MB

Please stop trolling.

2. Put all rendering in C++. Maybe it will be faster then PHP version. I made most of it in PHP, because I had problem with 'shadow' effect (lower floors) in C++ and first versions of 'otclient_mapgen' crash every few minutes.

Are you really working as a programmer? It kinda makes me feel sorry for your employer.
 
I got 2 ideas:
1. Make OTClient load part of map (from X1 to X2, all floors) to not exceeed ~1GB ram. Render images of that part, then reload map and load other part. I'm just not sure how look .otbm format and how it will work.
2. Put all rendering in C++. Maybe it will be faster then PHP version. I made most of it in PHP, because I had problem with 'shadow' effect (lower floors) in C++ and first versions of 'otclient_mapgen' crash every few minutes.
1. Done. 115 MB ORTS map generated on 32 bit windows (use less then 1.6 GB ram).
2. Almost done. Rendering took only 1.5 hour, PHP version rendered same map in 13 hours. Now I need to add 'shadows' to images of lower floors, but it should be easy.
but I still don't know if it's problem with algorithm or map exceeded RAM limit:
QC9WoyM.png

I must rewrite algorithm to split map into parts by 'number of items' on each part, not 'width' (in tiles, by 'x').
 
I finished algorithm to split map into parts. Now I can release .exe, because no matter how big map is, you can make it use under 1GB ram.
1. Map rendered with shadows on lower floors in 91 minutes (multi core).
2. Tiles rendered in 90 minutes (single core - I have to rewrite this, it should take less then 50 minutes).
3. Tiles compressed to JPG (quality 80%) in 25 minutes (multi core) - from 38.7 GB (PNG) to 9.9 GB

I will try to commit it to gits this weekend (C++ and PHP), but first I want to update otclient to newest version with all new clients support.
 
Back
Top