GM:S 1.4 [SOLVED] draw_sprite_ext leaves trace of erased color as outline

Discussion in 'Programming' started by YoSniper, Jun 14, 2019.

  1. YoSniper

    YoSniper Member

    Joined:
    Jun 24, 2016
    Posts:
    409
    So, I'm working on a game that is very cutscene-heavy. In this particular shot, the camera is slowly zooming in.

    The character's body, arms, and head are each their own sprite, and they are drawn at a scale > 1.

    When I created the sprites in the editor, I used magenta as a marker color for parts I wanted to erase later. Then when I was done, I used Ctrl + Shift + E to erase the magenta background.

    However, it looks like some of that magenta creeped in when I draw at a larger scale. I don't recall this ever happening before.

    Anyone know a quick fix without having to completely redraw the sprites?

    [​IMG]
     
  2. flyingsaucerinvasion

    flyingsaucerinvasion Member

    Joined:
    Jun 20, 2016
    Posts:
    2,034
    I believe the magenta is still there, it just has an alpha of zero. However, when interpolating between colours, it can still creep in, even though it has zero alpha.

    If you're fine with black outlines instead, you can just fill in the background with transparent black... make sure you use the replace rather than the blend option when doing so.

    Other options are:

    To fill in the background with colors that match the edges of your sprite image (except with zero alpha). This can be difficult to do especially since you can't see what you're doing. It would be easier to do in a program that lets you handle alpha channels completely seperately, and that also allows you to toggle them on and off.

    You can also turn off texture interpolation, if you don't need it. This will cause your textures to look more jaggy, but the colors wont bleed into each other either.
     
    YoSniper likes this.
  3. YoSniper

    YoSniper Member

    Joined:
    Jun 24, 2016
    Posts:
    409
    Thank you! That worked like a charm. I still have to tweak the edge of the arm sprites with a different invisible color to remove the lines between them and the suit, but all the magenta is gone.
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice