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

MapIcon IDs are not always reused after calling Streamer_DestroyAllVisibleItems #451

Open
Naseband opened this issue Mar 3, 2023 · 0 comments

Comments

@Naseband
Copy link

Naseband commented Mar 3, 2023

When calling Streamer_DestroyAllVisibleItems(playerid, STREAMER_TYPE_MAP_ICON) it sometimes seems to not properly mark certain IDs as free. Over time this reduces the amount of visible MapIcons and eventually no MapIcons will be left on the player side.

To reproduce simply create for example 200 MapIcons in a large circle (style MAPICON_GLOBAL and large streamdistance) so the streamer tries to show as many as possible.
Then add a command that does the following and keep using it:

Streamer_DestroyAllVisibleItems(playerid, STREAMER_TYPE_MAP_ICON);

For the first few times it works as expected: all icons disappear for a short time and reappear. However the number of icons reappearing will reduce and eventually there will be no icons left.

This issue can sometimes be worked around by using Streamer_SetVisibleItems and setting the player's max map icons to 0 and back to 100 (or whatever amount you want to set). The only reliable way is changing virtual world/interior.

Tested on 2.9.2 -- 2.9.6 with both chunk streaming on and off.

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