Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

Sprite disappears...

A topic by PolarticDev created Aug 24, 2022 Views: 227 Replies: 5
Viewing posts 1 to 4

Dude, someone knows why the sprite disappears at the moment when I apply the shader?

This is code

///Create
current_pal = 6
my_pal_sprite = sprite7
override_surface=noone;
override_pal_index=0;
pal_swap_init_system(shd_pal_swapper,shd_pal_swapper_html_sprite,shd_pal_swapper_html_surface);


///Draw
pal_swap_set(my_pal_sprite,current_pal,false);
    draw_sprite_ext(sprite_index,image_index,x,y,image_xscale,image_yscale,image_angle,image_blend,image_alpha);
pal_swap_reset();
Developer(+1)

I would need to see your sprite and your pal sprite to figure out what might be going on.

Okie

These are the sprites used for testing the shader.



But, in the game, the sprite disappear...




Do you know why happens that?

Note: I use GameMaker Studio 1.4.9999

Developer

So you need to combine those two palette sprites into one sprite. Brown one on the left, green one on the right. That's what your pal sprite should look like.
If that doesn't work, I recommend joining the GM Discord server and asking there. I could look at your project if you'd like.

Okie, thank you very much!