• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

draw_rectangle

  1. R

    [SORTED OUT]adaptable textbox

    hello guys, i'm trying to make a text box that change its size according to the size and line break. Well, I even managed to get the code to work, see: //this code is part of an algorithm, so I'm just showing the main part var string_w = string_width(global.item_info[_item]); var string_h =...
  2. I

    Solved - Drawing Rectangle over time in GUI

    Hi, I have some semi-working code in my project that runs a script when the player clicks on certain tiles in-game. I'm struggling with slowing things down to get a smooth look! What I want to happen is: The player clicks the tile. A small blue bar appears in the tile below and fills from...
  3. S

    Legacy GM draw_rectangle() doesnt draw over backround

    I made a pausing function based on this video of shaun spaulding All instances get deactivated as they should when I am pressing space button but it doesnt draw a black rectangle over my screen. All I can see now is my modified backround. The depth of my pause object is the highest of all my...
  4. Dr_Nomz

    GML How do I make a button with draw_rectangle and room_view?

    So I have this button: if (abs(mouse_x - x) < 50) && (abs(mouse_y - y) < 50) && showInv == true{ draw_set_color(c_white); draw_rectangle(x-47,y-47,x+46,y+46,0)That basically allows it to draw a rectangle whenever it's hovered over, and then it allows you to click on it, which executes some...
  5. R

    GML Draw_rectangle coordinates not same as point in rectangle

    if point_in_rectangle(mouse_x, mouse_y,105, 150, 295, 190){hover_ = true}else{hover_ = false} draw_set_color(c_blue); draw_roundrect(105, 150, 295, 190, hover_); //draw_button(105, 150, 295, 190, true); draw_set_color(c_white); draw_set_halign(fa_center) draw_set_valign(fa_center)...
  6. N

    Just found interesting thing about draw line or outline

    I got frustrated why my bounding bbox_left and bbox_top had offset by +1 when I used draw rectangle outline or simply line. Turned out that in line or outline situations they ar drawn BETWEEN pixels right side or bottom side of pixel you are drawing. Food for thought, dunnoo if this should be...
  7. K

    Using draw_set_blend_mode for hover-effect

    I want to create an hover-effect for my moving boxes, so that the box creates a rectangle, that is blended from white to 100% transparency. I am using 2 kinds of objects in the room to create this effect: "obj_box" (the present box, that is moving around) "obj_rect_blend_up" (the blending...
  8. Zhanghua

    GameMaker draw_rectangle Set the Outline Width ?

    It's only 1px with outline of "draw_rectangle", So how can I set the border width for this function? TKS.
Top