rectangle

  1. Edwin

    [Solved] How to make a custom roundrect with own corner sprites?

    Hello, people. I have a question about draw_roundrect() functions that draws a roundrect, so I have a sprite with 4 frames that keeps images of all roundrect corners. It looks lke this: Every corner image is a seperate frame. So how do I draw a simple rectangle and just change it's corners to...
  2. G

    GML Create rectangle made of objects

    I am trying to make a management game. I need the player to be able to assign different "areas" like in Prison architect or Rimworld, by pressing and holding a mouse button to draw a rectangle that defines an area. Since I'll need objects to detect wether they are in an area or not I'm trying to...
  3. Shadowblitz16

    GMS 2 (SOLVED) draw_rectangle draws semi transparent pixels on fill and some other things

    does anybody know why draw_rectangle(0,7,127,7,false) is drawing a semi transparent rectangle? also it seems that the lines top, left, and right lines are not drawing even though 0-7 is 8 pixels and 0-127 is 128 pixels which it should be drawing inside the rectangle like this.. here is my...
  4. MMM

    Asset - Demo Rectangle coloring

    If you love to change colors in the Final Fantasy 7 inventory this #GameMaker / #GameMakerStudio2 demo will show you how to code and implement such a system in your game - in three different ways. :) https://mmmfree2dwindowsgames.blogspot.com/p/game-maker.html
  5. Dr_Nomz

    GML How do I make this button work?

    So I have a working button from an inventory tutorial I saw, but when I tried to make a custom one it didn't work. ///Draw event\\\ var click = mouse_check_button_pressed(mb_left); var x1,x2,y1,y2; x1 = view_xview[0]; x2 = x1 + view_wview[0]; y1 = view_yview[0]; y2 = y1 + 104...
  6. Dr_Nomz

    GML Rectangles, drawing quirk (wtf)

    if (abs(mouse_x - x) < 48) && (abs(mouse_y - y) < 48){ draw_set_color(c_ltgray); draw_rectangle(x-48,y-48,x+47,y+47,0) So what this does is it creates a rectangle (duh), but the way it works is it creates a little square box on every CORNER from the center origin, meaning that instead of...
  7. Shavv

    GMS 2 Drawing a rotated rectangle from object position

    Heey guys! I found a neat little script here to draw a rotated rectangle, wich is really fun but I can't seem to solve the issue im having with it. its drawing the rectangle in the exact middle of the object, and i want it to draw from the object forward to the direction i want it to...
  8. D

    Android Icon problem

    Hello, I got problem with icon, it´s easy to describe. No screenshot needed (don´t want to place "ad" here). I have all icons placed in GM. But after I install it on phone it get smaller. So it looks like.. Shrinked icon of my app, but with white circle around it (it´s 50% rectangle and 50%...
  9. darijs1

    Legacy GM (Solved) Simple way to draw a rectangle under my text

    Based on this code: ///Script object = argument0 str = argument1 draw_set_halign(fa_center); draw_text_transformed(argument0.x, argument0.y-argument0.sprite_height, str,0.5,0.5,0); how can i draw a rectangle under this text in a way that would keep the rectangle the same width and height as the...
  10. Shadowblitz16

    GMS 2 separate rectangular collision masks per sub image?

    will this ever be possible to do in the sprite editor? I really want to use objects as tiles since tiles are hardcoded at compile time however I need to use separate rectangular collision masks per sub image. this is because some of the subimages are not completely 16x16 rectangles and I want...
  11. Shadowblitz16

     (Suggestion) Rectangle mask per frame

    simple suggestion the seems like it could be added very easily can the yoyo devs add a per frame option for every mask shape? I want to do auto tiling by using objects and their image_index's but I need to set their mask to be different depending on the frame. there isn't really a way to do...
  12. W

    draw_rectangle[solved]

    I'm having trouble setting this rectangle how I want. I want it to stretch from my enemy object to the right and left by a total of the width of my regular walls 300. That part looks correct but I can't get the vertical to match. It only covers as far as the enemy sprite, I want it to stretch...
  13. Freddie The Potato

    Legacy GM Find intersection in rectangle

    Heya, I've run into a problem and I'm having trouble coming up with a solution. I have a box with varying width and height. I have a center point (x1, y1) that is always directly in the center of said box. And lastly: I have a final point (x2, y2) that exists somewhere outside the box. If a line...
  14. B

    Question - IDE How to use the new features in the room editor?

    From the release notes for the lasts update: "Room Editor: Rectangle, line and fill tile tools added (these do not yet do auto-tiling)" http://gms.yoyogames.com/ReleaseNotes.html First of all, this is great! The thing that I disliked the most about GM:S1 was that I needed to work with Tiled or...
  15. A

    Controlling Direction of Bouncing Ball on Rectangular Paddles

    I am in the process of making an experimental game that is a combination of arcade classics Pong and Breakout. The following screenshot is a basic demonstration of this idea. As it stands, players are able to control the direction of the bouncing ball based on the vertical positions...
  16. T

    Precision mask not working. Rectangle Does.

    So I decided to finally not be lazy and work on slopes. I realized a problem when for a slope, i needed to use precise collision checking, so its not just a big rectangle, and on colliding, my character seems to not notice the mask at all. I then made it more basic for debugging, using my...
  17. Shadowblitz16

    Legacy GM [solved ]draw_rectangle_colour problem

    I have a small problem draw_rectangle_colour is drawing the boxes like they are not scaled with the view I thought thats what the draw_gui event was for? so that you can draw things without the view effecting them? am I wrong or is this a bug? here is a pic...
Top