Looking to fix Somebody's Scroll effect

0 favourites
  • 5 posts
From the Asset Store
All popular touch mechanics - scrolling, zooming, swiping
  • Hello there, I recently noticed that the Scroll effect made by Somebody, which allow for a texture to scroll automatically over time worked fine in preview, but had a huge offset issue after export, and I am looking for someone with enough effect scripting knowledge that could help me investigate the cause of it, as it is a very useful effect with various application; here's the Drive link :

    drive.google.com/file/d/1Ds-GiqjZ24fqpM0iO0KeXm3AY18VlLZy/view

    Thank you in advance!

    (I would gladly upload gifs to compare the preview and export results but Giphy doesn't seem to work)

  • I don’t mess with effects but likely the fact images are put into spritesheets when exporting is throwing it off.

    The effect probably needs to be fixed so it wraps the texture coordinates around the sub texture instead of the whole texture.

    A workaround is to load the image at runtime. That way the image isn’t spritesheeted.

  • Hey, thanks for your answer, would you know how to do that? Or someone who could help? My knowledge of javascript is way too basic to understand how effects are coded

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • On the construct community discord there is skymen, mikal and Federico that have made effects, but c3 mostly.

    I’m no longer interested in any aspect of addon development but I can give general information.

    The fx file is glsl not js but it looks similar.

    The scrolling is probably done by shifting the texture coordinates its sampling from.

    Maybe: tex=mod(tex+vec2(offsetX,offsetY), 1)

    But that only works right if the image isn’t spritesheeted.

    To make it work you need the top left and bottom right texture coordinates. It would look similar to this but the names of the values may be different.

    tex = mix(texTopLeft, texTopRight, fact((tex-texTopLeft)/(texBottomRight-texTopLeft)+vec2(offsetX,offsetY)))

    You’d need to look up the correct names of things from the docs I think.

    Anyways I’m assuming a bit here. I haven’t looked at the effect. I’m not available to actually try doing it with the effect, but it’s the rough idea of a possible fix.

  • I think I understand yeah, I'll try to join the Discord, thanks a lot for your help~

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)