get

  1. DGNNY

    SOLVED Get X POSITION of sprite

    Henlo on my draw GUI event, I draw an icon for an ability and draw text over it to represent the cooldown i want the position of the text to be relative to the position of the icon, but i don't know how to get the x position of it. sprite_get_xoffset returns 0 because it only gives the position...
  2. Posho

    GMS 2 [SOLVED] HTTP GET/POST Help for GraphQL

    Hello, I am trying to get access to an API using HTTP functions. Normally you would make queries using JSON files but apparently GM:S forcefully uses ds_maps, which is a tad different. I am also having trouble sending the Auth Token, which from my understanding is done through the Header of a...
  3. M

    GMS 2 A variable that "Holds" another variables name

    Hello all :), I have been making some headway on my game and have been somewhat trying to polish/ fix up my code to be easily expanded on so that I can start adding "Content". My question, does something like this exist? variable_get_name() or maybe, reference_variable() I am simply trying...
  4. F

    GMS 2 http_request not sending a GET method

    Hello, I'm trying to send a GET request with http_request, but it sends a POST. I've wrote this in create: var url, headers, data; url = "http://localhost:3000/"; headers = ds_map_create(); data = ds_map_create(); req = http_request(url, "GET", headers, json_encode(data))...
  5. F

    Checking the sprite of a colliding object.

    Hey there I'm currently working on a tetris like game and i want the score gained when you clear a line to multiply based on the number of blocks with the most occurring sprite in the cleared line. However the only way I can think to do this is by checking the sprite of each block in the line...
  6. matharoo

    Asset - Graphics sprite_getpixel (Sprite Pixel Data)

    Matharoo presents... sprite_getpixel sprite_getpixel() gets the color of a sprite's pixel. • Returns the data in an array, in RGBA order. • Values are in the 0-255 range. • Uses buffers, which are fast! • Automatically handles buffer creation & usage, so it only has to go through the...
  7. U

    GMS 2 GET and POST requests

    Is it possible to send GET and POST requests, and recive a answer? In most languages, this is done simply, and what about GML? Like in delphi --- var some_variable:string; begin some_variable:=IdHTTP1.Get('http://forum.yoyogames.com/'); end; ---
  8. Shadowblitz16

    GMS 2 run code in virtual children?

    can someone help me understand how to loop though all the virtual children and run code inside them? basicly I want to be able to run code in widget that are children of the widget I click on. each widget has a parent variable pointing to the instance of the parent widget I want to be able to...
  9. J

    Legacy GM (SOLVED) Get Rotation Speed

    I am wanting to have and object that the player can spin. I got the spinning all set up, but how can I make it to where when the player swipes the object, it keeps spinning with the same speed as when the player let go. This is what I have in the step event: phy_rotation += velocity; if velocity...
  10. Misu

    Asset - Scripts buffer_getpixel: 10x faster than normal surface_getpixel (GMS1 and GMS2)

    Get buffer_getpixel at the marketplace! Need a faster surface_getpixel? You come to the right place! This asset comes with a small list of scripts that will help you get a pixel color super fast and its totally free. How to use each command: buffer_getpixel_begin(surface) = creates the buffer...
  11. Misu

    Shaders Shader not picking up color from another sampler

    I am working on a very complex shader as an experiment with 3D shadering. At this point, the shader I wrote came out excellent base on my calculations. However, it is not working. I tried testing out each algorithm in the fragment shader to see which line is working or not, and I reach my...
  12. zendraw

    Legacy GM [SOLVED]:Getting keys that are not constants

    Hi, how do you get a key that is not a constant in gms1? for instance the brackets [ ]. i was thinking about the chr() but im not sure how wuld work. any ideas?
  13. zendraw

    Legacy GM Get colour from sprite

    Hi, so im trying to get a certain colour from a sprite lets say the green colour and lets say with the lowest value. how do you do that?
Top