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
267 stars 207 forks source link

Windows / Lists show hidden content when moved/resized #655

Closed AvajiOT closed 11 months ago

AvajiOT commented 11 months ago

Priority

Medium

Area

What happened?

When moving windows, any widget that is has hidden content being farther down the widget then the size of the widget will constantly flash when the client is drawing more than 60 frames per second.

Example with the client locked to 60; https://github.com/mehah/otclient/assets/103899149/fe9acfea-bbae-45fe-828d-c3eb595a463c

When client is at 144FPS; https://github.com/mehah/otclient/assets/103899149/8c8d7fc6-5522-4369-87b2-4711c6ff9b98

What OS are you seeing the problem on?

Windows

Code of Conduct

conde2 commented 11 months ago

Screenshot_20231201-082915_GitHub.jpg

This is from the feat attached widget, sorry I'm on my cellphone.

Can you revert this changes and see if it fixes?

Only the changes related to setRect.

AvajiOT commented 11 months ago

I spent a bit of time and kept walking back commits until I no longer saw the issue, at commit fix widget shader it was not seen, however at commit build: compile fix it was seen.

Most commits after this one actually made the problem slightly worse, as I was not able to observe the issue of the inventory items flashing while resizing the window at the commit build: compile fix, however when moving the window around items were able to be seen.

Here's a quick video at 144 FPS at the commit build: compile fix https://github.com/mehah/otclient/assets/103899149/0452e317-c6a8-49cd-98f1-690f9ce5619c

Quick video at commit fix widget shader https://github.com/mehah/otclient/assets/103899149/b0ef5eae-28e9-46cd-8f90-1e3bcc307396

I was unable to build at v8 bot, but I suspect the problem first started appearing there.

patrykq112 commented 11 months ago

I confirm that this bug exists. I think this is a bug related to Drawpool 3.0, not widgets

EdwKing commented 11 months ago

I confirm that this bug exists. I think this is a bug related to Drawpool 3.0, not widgets

Please try to revert to commit before drawpool 3.0 and see if you still see the issue. It seems to possibly be a combination of a couple things

Here's a recording of commit 674ad54275b0ad0291240b96a8324bd0a2b8724f fix: function getItemCountOrSubType does not exist

https://github.com/mehah/otclient/assets/22525360/4e4a12a5-b30d-4ca9-958e-62235b84e7a5

Possible that the inventory issue happens after the drawpool 3.0 update, but the text issues happen after v8 bot update.

kokekanon commented 11 months ago

I confirm that this bug exists. I think this is a bug related to Drawpool 3.0, not widgets

Please try to revert to commit before drawpool 3.0 and see if you still see the issue. It seems to possibly be a combination of a couple things

Here's a recording of commit 674ad54 fix: function getItemCountOrSubType does not exist

commit.function.getitemcountorsubtype.does.not.exist.mp4 Possible that the inventory issue happens after the drawpool 3.0 update, but the text issues happen after v8 bot update.

to find out if bug was the bot I put the bot in version 3.11 and I can't reproduce that error in miniwindows or panellist

with 60 fps 144 fps

and max fps

AvajiOT commented 11 months ago

I confirm that this bug exists. I think this is a bug related to Drawpool 3.0, not widgets

Please try to revert to commit before drawpool 3.0 and see if you still see the issue. It seems to possibly be a combination of a couple things Here's a recording of commit 674ad54 fix: function getItemCountOrSubType does not exist commit.function.getitemcountorsubtype.does.not.exist.mp4 Possible that the inventory issue happens after the drawpool 3.0 update, but the text issues happen after v8 bot update.

to find out if bug was the bot I put the bot in version 3.11 and I can't reproduce that error in miniwindows or panellist

with 60 fps 144 fps

and max fps

Apologize for pushing the issue, but I just pulled the commit b0d5ff19e442af640925d5244de933de21bcd82f / build: compile fix , compiled it right now and tested it out.

https://github.com/mehah/otclient/assets/103899149/d5678693-3c9d-4ac8-842a-ab08962caeaf

If someone else could also test, to see if it's just completely localized to my compiler somehow that would be helpful

conde2 commented 11 months ago

Fixed in: https://github.com/mehah/otclient/commit/e131c7dfaff722071f944d17171d92d6de96d197