draw

  1. Gunnar the Clovis

    SOLVED [SOLVED] Engine Bug / Objects drawing WRONG image_index in odd but reproducible ways based on image_number

    Hello, I sincerely plead that someone helps me with this, as I am going insane pulling my hair out trying to resolve this issue... This is a critical problem for me, and if I can't resolve it, I'll have to scrap months of professional work and move to different game engine. All code is posted...
  2. P

    SOLVED [Spine] draw_self works but not draw_sprite(sprite_index,image_index,x,y)

    Hello, I'm using Gamemaker 2.3.2.426. I have trouble with drawing the spine sprite. Before I used skeleton functions to draw sprite but now I need to mix animations so I need to fix this problem. The sprite draws fine using draw_self() but when using anything else (even simply...
  3. S

    How to draw dynamic tile-based background?

    I have a room divided into lots (1000+) of square tiles, the tiles can be things like grass or dirt. The tiles are dynamic because if I have an explosion or something of the sort the grass tiles become dirt tiles. How can I draw these tiles while maximizing performance?
  4. S00T

    Windows Draw Functions Stopped Working in Every Object

    while working on my game today i ran it and suddenly everything that was supposed to be drawn to the screen stopped being drawn. objects still render and the code outside of the draw scripts run perfectly fine, but it's like the draw scripts aren't even running. this happened at random to every...
  5. TheCheeseMaster

    SOLVED Surface Drawing Stuttering

    Hi there, Basically what I'm trying to achieve is this: -have "cloud shadows" moving across the screen -draw the cloud shadows with an alpha I can control (all with the same value at any given time) -have the cloud shadows create a uniform shadow colour when overlapping, rather than having two...
  6. H

    SOLVED Question about Draw Pipeline (I think)

    In a case like this: // in Draw GUI surface_set_target ( blur_surface ) ; shader_set ( shd_blur ) ; draw_surface_stretched ( application_surface , 0 , 0 , blur_surface_width , blur_surface_height ) ; // where blur surface is smaller does the shader apply to the app_surface before or after it's...
  7. S

    view_surface_id question

    Is it possible to set the view_surface_id for a view to a surface, draw only a few sprites to that surface, then set the view_surface_id to another surface and draw everything else there? I can't seem to do this and I'm wondering if you can only set the view_surface_id to one surface per frame...
  8. SentientPenguin

    GMS 2.3+ Does GMS2 only "draw" sprites, tiles, backgrounds, etc. when they are in the player's view?

    Are sprites, tiles, background images, etc. only "drawn" by GMS2 when they are on screen and visible to the player? Or are there, in theory, performance efficiencies to be gained by, for example, manually telling GMS2 to draw only those tiles or portion of a background image surrounding/visible...
  9. JacobSyndeo

    SOLVED Add "3D" Perspective/Depth to 2D Platformer

    Hey, I'm making a sidescrolling 2D platformer similar to what you would find on a Game Boy Color or GBA. I'm pretty new to GameMaker and game development in general, but I have about a decade of experience with mobile app development and general software engineering. Progress has been going...
  10. SirCaliber

    GMS 2.3+ draw_sprite lagging behind 1 frame

    Hey guys! So I've got a bit of a problem - when using draw_sprite, the player object is drawn first, then the glasses sprite in draw_sprite is being drawn on top of it, which is intended. However, the problem is that the glasses sprite is being drawn 1 frame after the object is being drawn. I'm...
  11. C

    Pixel Perfect and "Pixel Snapped" GUI

    Hi guys, I need to make my GUI layer "pixel-perfect", and found no clue around here.. The blue cube is being drawn in the "Draw GUI" event The white cube is being drawn in the "Draw" event //I want the blue cube to behavior like the white one while rotating. //But found nothing like this for...
  12. S

    GMS 2 Hightlighting mouse over text

    I'm going to have a lot of text based menus in the game I'm making, and I'm trying to make it so that when I mouse over clickable text it highlights in a different color. I have an object that draws text to the screen and is supposed to highlight when you mouse over it. I also have another...
  13. B

    GMS 2 Scripts drawing surfaces, memory leak.

    So originally I've got 16 sets of this code block messily creating a surface each all within a single draw event; since they're all similar blocks I decided to figure out scripts and tidy it up since the variables are easy enough. I translated it directly into a script with no changes in logic...
  14. D

    Calculate Tile Size?

    So I'm trying to make a map that loops horizontally, but not vertically; this was easy enough. My code goes through and reads each cell of a ds grid and draws a different colour pixel on the screen depending on what value it holds. I have a "zoom" variable that is somewhere between 1 and 0, then...
  15. b-wb

    Debug Profiler shows DrawTheRoom being called twice-- what would I have done to make that happen?

    Hello everyone I'm working right now on trying to optimize my game and looking at performance hogs. Strangely, it looks like in the debug profiler "DrawTheRoom" and everything that falls in it is happening twice. Rather than launching into an explanation of my game's graphical code, I am...
  16. A

    Android [Optimization] drawing text using draw_sprite instead of draw_text?

    Hi. Not sure if this is already posted in forums or a similar thread exist but I tried looking and there was no exact thread similar to this. Anyway, I would like to know your insights and experiences regarding this topic. Have you tried to draw or display texts, words (messages, pop-up...
  17. Storm1208

    GMS 2.3+ [Solved] Grid Generation Code Not Printing All Lines

    Hey all! I've been working on some grid creation code and I ran into an issue with it last night. I've been trying to fix it for the past day but I haven't had any luck. The code is supposed to generate a 5x8 size grid within the screen (not based on the room's height and width, but within a...
  18. sivispacem

    SOLVED Draw Instance Score - prints double (overlapping) text

    ---If you duplicated your room, ensure you do not have more than one persistent object placed in more than one room.--- Thank you to @TheouAegis, @Slow Fingers for the assistance. As the title suggests, I have been following the "Space Rocks" tutorial and all parts of the game work as the...
  19. J

    Instance creation not working

    Hi there, long time user and lurker of GM. I'm currently having a problem with instance creation, none of the instance functions seem to draw to screen despite being in the draw method. Here is my simple test code, which does not draw: create_instance_depth(room_width, room_height, 10000...
  20. G

    Sleep Margin on Linux?

    Currently trying to make a headless dedicated server with GMS2 running on an AWS linux machine. I need it to perform GameMaker's collision functions to make the server more authorative (replicating these functions are incredibly difficult in other languages/engines). I'm very close, I've...
Top