mehah / otclient

An alternative tibia client for otserv written in C++20 and Lua, made with a modular system that uses lua scripts for ingame interface and functionality, making otclient flexible and easy to customize
Other
260 stars 198 forks source link

Moving behind the object - height 2 width 1 #788

Closed drewnydrzew closed 3 months ago

drewnydrzew commented 3 months ago

Priority

Low

Area

What happened?

When moving a character "behind" an object, the character appears "on" the object until the movement animation ends. The bug occurs when we create, for example, a "wall" 2 sprites height and 1 sprite width (in object builder). The problem does not occur when we create a "wall" 2 sprites height and 2 sprites otclient_dx_vZvEcYlBjL width (in object builder).

What OS are you seeing the problem on?

Windows

Code of Conduct

mehah commented 3 months ago

this is not a bug, you are placing top down spriters in a client where the rendering is isometric, you need to change the drawing order here:

https://github.com/mehah/otclient/blob/dfcf9db6e4366e82cba2636bb85c51f79985ac3d/src/client/mapview.cpp#L347

drewnydrzew commented 3 months ago

Thank you very much! I've already made it