Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Optimized (and improved support for Unity 5 to 2022)#1

Closed
saurondark22 wants to merge 1 commit into
stencg:masterfrom
saurondark22:master
Closed

Optimized (and improved support for Unity 5 to 2022)#1
saurondark22 wants to merge 1 commit into
stencg:masterfrom
saurondark22:master

Conversation

@saurondark22

Copy link
Copy Markdown

what I did:

  • Rearranged methods.
  • Added support for latest unity 5. (just tested unity 5 and unity 2022)
  • Optimized scroll view to update thumbnails, buttons and labels only when element visible in view.
  • Layout changes inside scroll view for maximum info visibility per element"

know issue:

  • scroll down to last element and resize window will throw some error on console.

what I did:
 - Rearranged methods.
 - Added support for latest unity 5. (just tested unity 5 and unity 2022)
 - Optimized scroll view to update thumbnails, buttons and labels only when element visible in view.
 - Layout changes inside scroll view for maximum info visibility per element"

know issue:
 - scroll down to last element and resize window will throw some error on console.
@builder-main

builder-main commented Feb 2, 2024

Copy link
Copy Markdown

Had to do this for it to compile. Can confirm the scroll view better performances !

#if UNITY_2021 || UNITY_2020 //L.305
					for (int i = 0; i < 3; i++) //TODO Get secondaries array length instead
					{
						if (tSpriteRenderer.sprite.getSecondaryTexture(i) == null) continue;
#if UNITY_2021_3
						var tSpriteSecondaryTextureDetail = GetTextureDetail(tSpriteRenderer.sprite.getSecondaryTexture(i));
#else
                        var tSpriteSecondaryTextureDetail = GetTextureDetail(tSpriteRenderer.sprite.getSecondaryTexture(i), renderer);
#endif
						if (!ActiveTextures.Contains(tSpriteSecondaryTextureDetail)) {
							ActiveTextures.Add(tSpriteSecondaryTextureDetail);
						}
					}

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

Successfully merging this pull request may close these issues.

2 participants