Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fader.inc: infinite loop #50

Open
updatewv opened this issue Jan 7, 2024 · 1 comment
Open

fader.inc: infinite loop #50

updatewv opened this issue Jan 7, 2024 · 1 comment

Comments

@updatewv
Copy link

updatewv commented Jan 7, 2024

'OnPlayerTextDrawFaded' is not called when defined and neither is the timer killed when the animation ends. There is an infinite loop (I debugged).

PlayerTextDrawFade(playerid, playertextdraw_0[playerid], 0x000000FF, 0x00000000, fade_type_box, 25, 5);

@updatewv updatewv changed the title fader.inc fader.inc: infinite loop Jan 7, 2024
@updatewv
Copy link
Author

updatewv commented Jan 7, 2024

if (_textDrawFader[playerid][idx][E_FADER_FROM_COLOR] == _textDrawFader[playerid][idx][E_FADER_TO_COLOR] && (_textDrawFader[playerid][idx][E_FADER_TYPE] == fade_type_text && _textDrawFader[playerid][idx][E_FADER_FROM_OUTLINE_COLOR] == _textDrawFader[playerid][idx][E_FADER_TO_OUTLINE_COLOR]))

the error could perhaps be in the '&&' operator, I changed it to '||' to be able to kill the timer, I haven't studied much how include works in general, and I don't even know if I'll need the 'fade_type_text', I did it in a hurry, so the repo owner could see this more calmly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant