1. Hey! Guest! The 34th GMC Jam will take place between August 22nd, 12:00 UTC (Thursday noon) and August 26th, 12:00 UTC (Monday noon). Why not join in! Click here to find out more!
    Dismiss Notice

GM:S 1.4 Bug when using draw event

Discussion in 'Programming' started by GamemakerFreak123, Jun 25, 2016.

  1. GamemakerFreak123

    GamemakerFreak123 Member

    Joined:
    Jun 25, 2016
    Posts:
    18
    Hi everyone.

    A friend of mine has this annoying problem. Typically when using the draw event or using custom backgrounds, instead of just a blank color, the game draws letters and symbols all over the screen (Please see the first screenshot). It looks like it's drawing all the symbols supported by a normal font, but i'm not sure. Other strange things has happened too, when exporting the game, for android (See second screenshot). Has anyone experienced this before? He did try to reinstall GMS but without luck.

    Thank you for your time.

    [​IMG]
    [​IMG]
     
  2. Surgeon_

    Surgeon_ Symbian Curator

    Joined:
    Jun 22, 2016
    Posts:
    248
    This happened to me a few times. The problem was usually fixed by clearing the compiler cache. Though one time I found out that I was using draw_sprite_part() (or draw_background_part()) and had accidentally put arguments which attempted to draw a part of the sprite (or background) larger than the resource itself. Once I fixed that I had no further problems.

    -Surgeon_
     
  3. GamemakerFreak123

    GamemakerFreak123 Member

    Joined:
    Jun 25, 2016
    Posts:
    18
    Thanks for your reply. He tried clearing the cache. Didn't help, though nothing happened when he clicked the button. When i click it i get a message saying target cleaned. We didn't do anything odd when drawing, like using draw_sprite_part. We just set the background in the room editor.
     
  4. CoderJoe

    CoderJoe Member

    Joined:
    Jun 22, 2016
    Posts:
    166
    Could you maybe post the code? It definitely looks like a font set. Not sure why this would happen.
     
  5. GamemakerFreak123

    GamemakerFreak123 Member

    Joined:
    Jun 25, 2016
    Posts:
    18
    Yes. I thought about font set too. Just can't figure out why. The code that causes it is this:

    When deleting this code, the game works fine... Weird though.
     
  6. Surgeon_

    Surgeon_ Symbian Curator

    Joined:
    Jun 22, 2016
    Posts:
    248
    Did you try using a different font? (draw_set_font(font))

    -Surgeon_
     
  7. zDami

    zDami Guest

    (i'm his friend) Yes, i tryed.. deleting the string of code of the message "press r to restart" the bug disappear.... but there is the visual bug ,like in the second screenshot, on android test...
     
  8. Nocturne

    Nocturne Friendly Tyrant Forum Staff Admin

    Joined:
    Apr 13, 2016
    Posts:
    6,775
    Do you use surfaces? This kind of issue is most commonly seen when using surfaces and not clearing them first.
     
  9. zDami

    zDami Guest

    can "draw_clear_alpha(c_white,0)" resolve the second bug?
     
  10. GamemakerFreak123

    GamemakerFreak123 Member

    Joined:
    Jun 25, 2016
    Posts:
    18
    Hello everyone and thank you for your answers.

    Yes we are using surfaces, but i tried removing the objects that uses surfaces, and the bug is still there.
    I think i should also mention that when i run the same project on my computer, the game works fine, so it's only on his computer it doesn't work.
     
  11. Nocturne

    Nocturne Friendly Tyrant Forum Staff Admin

    Joined:
    Apr 13, 2016
    Posts:
    6,775
    Okay, so what makes his PC different? List your specs and his specs (processor, GPU, OS version) and we'll see what we can see there...
     
  12. zDami

    zDami Guest

    ive got a hp laptop , windows 8, intel i7 4500U cpu 1.80 GHz 2.40 ghz , 6 GB RAM, 64 bit
     

    Attached Files:

    • gpu.PNG
      gpu.PNG
      File size:
      31.2 KB
      Views:
      2
  13. GamemakerFreak123

    GamemakerFreak123 Member

    Joined:
    Jun 25, 2016
    Posts:
    18
    Asus Laptop
    Windows 10
    Intel Pentium CPU N3530 2.16 GHz 64-bit
    8 GB DRAM

    GPU:
    [​IMG]
     
    Last edited: Jun 26, 2016
  14. GamemakerFreak123

    GamemakerFreak123 Member

    Joined:
    Jun 25, 2016
    Posts:
    18
    Please help. He did even reinstall Windows. Didnt help.
     
  15. R34LD34L

    R34LD34L Member

    Joined:
    Jun 21, 2016
    Posts:
    112
    Could that be a texture page problem this is so weird:eek:
     
  16. HermitPal

    HermitPal Member

    Joined:
    Jun 21, 2016
    Posts:
    9
    Out of curiosity what version of GM:S are you using?
     
  17. jackhigh24

    jackhigh24 Member

    Joined:
    Jun 21, 2016
    Posts:
    604
    also are you using texture_set_repeat any where

    actually that would show same problem on both if it was that, its more likly its winodws 8 64bit that the problem as i know you have to do extra things with that to get some things working right in GMS id go for windows 7 as you can then release the game for windows 7 and upwards if its built on windows 10 or windows 8 it cant go on a system lower than the one built with
     

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