draw

  1. DrScoop

    SOLVED Cropping an objects sprite with code

    Hello there, Im attempting to add a mini game to my game like a tower stacking game. In this game, we have a block the player drops which the player has to try their best align properly with blocks already dropped. So, when a player drops the block on another, if the block misses being aligned...
  2. D

    SOLVED How should i approach drawing sprites from my player?

    Hello everyone! I've been wondering about what method should i use to draw my player weapon when it attacks, since i have the weapon sprite separate from the player actual sprite. The reason for this is that i want to be able to change the weapon sprite in a easier way and independently from the...
  3. AnnoyingDoggoX

    GMS 2.3+ Printing on a sprite that is the background of a room.

    depth = -1; draw_set_halign(fa_center); draw_set_valign(fa_middle); draw_set_font(font_game); var camera = view_get_camera(view_current); var cx = camera_get_view_x(camera); var cy = camera_get_view_y(camera); var cw = camera_get_view_width(camera) draw_text(cx + cw div 2, cy + 24...
  4. B

    GML [HELP] LOOP PROBLEM and DRAW

    Hi Guys ! i need your help on this , cause i have been thinking and thinking and i cant get this solved out. i am making a simple Soccer Manager game , where there players info are all saved in player[0,0] array player[0,1] = name "vladimir" player[0,2] = pos player[0,3] = teamid player[1,1] =...
  5. N

    GMS 2.3+ Get rid of edges when two light circles cross each other

    Hi, I'm using this quick and simple lighting system: Most important code is: Draw Event: ///@desc Draw Lighting Surface if (!surface_exists(l_surface)) { l_surface = surface_create(RES_W,RES_H); } surface_set_target(l_surface); draw_clear_alpha(c_black, darkness); if (darkness >=...
  6. JEMcG

    GMS 2.3+ Object that draws mutiple overlapping sprites not working on a surface

    I have a pause screen for a game I'm making that copies the application surface to a new surface and then disables objects. Doing it this way means that when the objects draw event is cancelled they are still drawn the screen. My problem is that objects get a strange outline when this happens...
  7. Antikore

    GMS 2.3+ Draw begin draws below background layer in a project converted from GMS1.4 to GMS2.3.7

    When I converted my project into GMS 2.3.7, I got several issues, most of them are fixed but this one isn't Looks like Draw begin now draws below the background layer. I used draw begin for drawing shadows below any instance (so they don't overlap). IDE Version: GameMaker Studio 2.3.7.606 OS...
  8. Olivebates

    Autoscale text to width?

    Hello :) I would like to scale the width so it fits within a specified width, no matter how long it is. I tried looking at the manual but couldn't find anything. Is there a simple way to do that?
  9. smashencoo

    Need help drawing a rope sprite from one point to another

    So I just need a simple rope design where a rope sprite stretches from one object to another. I tried using the draw_sprite_general function so I could use the width and rotation to have it follow the objects: var angle; var distance; distance = distance_to_object(obj_Buck_Plane); angle =...
  10. H

    SOLVED draw a sprite on all objects

    To make doors in my game, I use 'draw_sprite' to draw an animation on a object (the object itself doesn't have a sprite assigned): draw_sprite(spr_door_animation, image_index, obj_door.x, obj_door.y); When placing multiple 'obj_door' in my room however, GameMaker chooses the coordinates of...
  11. R

    drawings coming out on top of each other

    hello guys, i have a visual problem in the draw GUI. I'm making a store for my game, and I've managed to do a lot of the visual stuff but I've noticed something. I noticed that all my drawings and texts were being made one on top of the other, basically it was a bunch of sprites and text, I'll...
  12. S

    GMS 2.3+ Question about designing

    1) I wanted to make glow and tried to use new layer behind my object's layer and reduce it's transparency, but : a) if object have an animation (24 frame for example) a new layer will be added to all 24 frames at once (what the hell ?) b) by changing the properties of a layer on one frame, you...
  13. S

    flashing label

    I have an idea to make flashing label. When the player will be near some object (for example rock) there will appear flashing label (press "H" to hide or sth like this). I know how to do it if the label will be an object. But i don't want to make one more object for such thing. I wanted to make...
  14. ZacKow264

    SOLVED Stop alpha from blending?

    How can I draw a primitive shape or a sprite with a certain alpha, but not have the alpha values add together when they overlap? I've tried disabling alpha blend, but that seems to set the alpha of everything back to 1. For instance if I have two rectangle draw at 0.5 alpha, if they overlapped...
  15. 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...
  16. 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...
  17. 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?
  18. 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...
  19. 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...
  20. 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...
Top