Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Studio Chat / Using visual designer & UV scrolling problem

Author
Message
Richard Stevens
4
Years of Service
User Offline
Joined: 14th Jan 2020
Location:
Posted: 31st Oct 2020 16:31
Hi Gents

I'm having a bit of an issue with the visual editor for my menus, specifically when I scroll the background of them with the built-in UV scrolling.

I have a few different menus. On each one I call menu_setup() on entering, and menu_cleanup() when exiting

When I first enter them, first time they are fine. If I back out of a menu and 'respawn' the menu, the background becomes corrupt.. just vertical lines.

This only seems to happen with UV scrolling turned on.. is there something else I need to reset when I enter or exit a menu?

TIA!
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 31st Oct 2020 19:59
That would suggest to me something to do with the UV Scale setting
Richard Stevens
4
Years of Service
User Offline
Joined: 14th Jan 2020
Location:
Posted: 31st Oct 2020 20:23
Thanks Blink0k -the X & Y scale seem to be 1.00 on my backgrounds. Is that normal? - it's not something I've changed.
blink0k
Moderator
11
Years of Service
User Offline
Joined: 22nd Feb 2013
Location: the land of oz
Posted: 31st Oct 2020 20:33
I'm not sure how you can determine that as there is not command to get the UV Scale. have you tried setting UV scale to 1,1?
SFSW
21
Years of Service
User Offline
Joined: 9th Oct 2002
Location:
Posted: 31st Oct 2020 20:43
Make sure your UV wrap modes are set to '1' before you do anything else in code, like so in Tier1:

SetDefaultWrapU(1)
SetDefaultWrapV(1)

Otherwise, your offsets and scaling won't wrap and will just streak at the edges when they clip.
Richard Stevens
4
Years of Service
User Offline
Joined: 14th Jan 2020
Location:
Posted: 31st Oct 2020 22:10 Edited at: 31st Oct 2020 22:11
Blink0k -I was looking at the scale X and scale Y just under the rotation slider on the sprite properties - not that then!

SFSW - My hero forever! Thank you that's fixed it!

Not that it matters greatly,. but out of interest, why isn't that the default setting?

Login to post a reply

Server time is: 2024-04-16 09:09:22
Your offset time is: 2024-04-16 09:09:22