Skip to main content

On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines
(5 edits)

I'm using this shader in my project and it worked fine. But images, processed by the shader, started to appear incorrectly, simply after I add a large sprite in my project. Not even after trying using the large sprite. Efforts to fix this were fruitless. Can you help me out, please?

(5 edits)

After adding another sprite to the project, the bug was gone. I think the shader has some calculation problems - I guess, it works incorrectly when it takes a sprite from the game's texture sheet if processing the numbers of the texture's size can't give integer or something.

(1 edit) (+1)

This sounds like a GameMaker cache issue. If importing a big sprite has caused your texture pages to be rearranged it might simply have confused GM's internal knowledge about where a sprite is kept on what sheet. The shader doesn't do *any* calculations as such when it comes to a sprites location or position. It just uses the built in GM functions for finding these things.

Try running the 'clean' option on your project, reloading the IDE, etc. As you discovered, simply adding another sprite was one potential fix.

I'm not discounting the possibility of it being an issue on my code's end but given that it doesn't manually interact with any texture sheet positioning I'm finding it hard to identify what an issue on my end could be.

PS. Apologies for such a late response, I only just caught your comment on one of my videos.