1. AbdatyK

    Object not Working as Sensor

    Hello, I'm relatively new to GameMaker so I'm trying to follow along a youtube tutorial by HeartBeast (found here). I'm aware that he's using an outdated version of GameMaker but I've been able to get by using the manual to fill in the gaps. What I'm stuck on is the damage object that is...
  2. KyleRansford

    GMS 2.3+ How to Draw Pressed Controller Button to GUI?

    I've been looking for a way to draw the number of a pressed button on a controller to the GUI and I found this this bit of code, and have it in a Draw GUI Event, but it doesn't draw anything on the GUI. I'm using an Xbox One Controller to test it out. for (var i = gp_face1; i < gp_axisrv; i++)...
  3. D

    Quick question for help ;) (ask for multiple rooms)

    if(room = Leaderboards || lb_tutorial || lb_level_1 || lb_level_2 || lb_level_3 || lb_level_4 || lb_level_5) { //draw the leaderboard draw_leaderboard(room_get_name(room),32,32); } how can i check for all these rooms at once without listing them like that? thx ;)
  4. Morkinas

    SOLVED Creating a lot of objects in a code for random levels. +Idea for Game Maker

    Hello, so I'm making a platformer with random area generation, areas themselves are not random they are pre-set, but their order is random. Everything needs to be in one room. Currently to test how my game feels I made a sprite with a lot of images scaled up for pixel to match block size and I...
  5. GONE

    GML How can i make an animation transition for my wall jump

    So I am making a platformer and decided to add the feature wall jump to the game. I found the code on a youtube comment and it works well. the code is //Wall Jump if (place_meeting(x+hsp,y,Owall)) && (key_jump) { vsp = -7; } if (place_meeting(x+move,y,Owall)) && (key_jump) { vsp = -7; hsp...
  6. FoxyOfJungle

    SOLVED How many times can I call gml_pragma("global")?

    Hi! I have a question, can I assign a function to run in gml_pragma("global", ...) more than once? Example: gml_pragma("global", "init_global_variables();"); gml_pragma("global", "init_shader_uniforms();"); Will this work? Thanks! Edit: fixed typo.
  7. flyinian

    SOLVED Interact with a single instance

    I have instances that the player can set on fire. If these instances are close to one another, the player can interact with all of them at the same time. What can I do to prevent this from happening. Code(Step): if(distance_to_object(Obj_Player) < 30 && !_SetonFire){ _Close = true;} else{...
  8. KyleRansford

    GMS 2.3+ How to Use Custom Mapping for Direct Input Controllers? Like Nintendo Switch Pro Controller?

    Hello, now that I have a system that can detect which controller is connected and assign it to the correct player, I've noticed that when I connected a Nintendo Switch Pro Controller, the D-Pad doesn't work. Also, on a different project, the Left Analog Stick on the Nintendo Switch Pro...
  9. Shadowmancer

    GMS 2 Mouse 8 directional point and click movement? [GML]

    Soooooo after a binge of founding out I absolutely ADORE arpg's (diablolike arpgs to be clear) I have a determination to make as close to one as possible in 2D, but im like really really noob, and only picked this up yesterday, with zero coding experience. Possibly a fools errand but im trying...
  10. L

    GMS 2.3+ Help with Dialogue Box!

    Hi! I have been following tutorial of Peyton Burnham on Dialogue Boxes and I was planning to add my own things here and there but ran into a problem I am trying to setup the system where I can setup a WAIT function and being able to edit how long the text should wait before continuing typing...
  11. K

    Infinite Swinging Platformer

    I decided to make a swinging game, but I want it to be infinite. I'm new to GameMaker Studio 2 and I have no idea how to do so. I have watched a few tutorials but none of them seem to work. Does anyone have any idea how to do so? If it helps this is the tutorial that I followed for this...
  12. hans

    Mapping Room coordinates to Gui Layer

    I've been working on this game in which I want the mouse to be on the gui layer but be able to click on things in the instance layer. My issue is that to do that I need to know the coordinates of the mouse in the instance layer while it's in the gui layer. The gui layer and the space the camera...
  13. L

    Instance_create_layer not working on physics object

    When a object is destroyed, I want to create another object in a specific location, but idk why is doesn't appear. instance_create_layer(spawnx, spawny, "Instances", obj_Tank); Note: the object are physics objects.
  14. K

    GML Get image_index when drawing sprites manually

    This isn't really an issue, just wanted to share a solution I found in case anyone else runs into this. If you draw sprites manually (ex. draw_sprite_ext), image_index can get messed up because it can return a decimal, and it can also increase larger than the image_number, basically...
  15. FoxyOfJungle

    GMS 2.3+ How to return the view number [0...7] that the camera is associated with?

    I for example can return the camera from the view using view_camera[0...7]. But how to return the view the camera is associated with? Something like camera_get_view()... I need to return something from 0 to 7. This code needs to be executed outside the Draw Event. Thanks for listening.
  16. y Acid

    GMS 2.3+ game_restart but restarting on other room rather than the top room order one

    So, I recently started using GameMaker Studio 2, and also programming on its language, so, to help me out, I looked up a tutorial on how to make a game, and found the GML GameMaker tutorial "Your first game", where you build a game called Space Rocks, and after 2-3 days "making" the game, I...
  17. L

    Player moves instantly instead of going slowly

    I am struggling with a thing. I can't make this object go slowly to an object that is supposed to attract it with another object, so when it touches "TheZone", it should go up slowly until it reaches "traget", but it just teleports there. does anyone know what should i do? if place_meeting(x...
  18. L

    number of arguments for function approach expected 0 got 3

    does anyone know why i get the error from the title? vspd = approach(hspd, vInput, accel); the script: if (argument0 < argument1) { argument0 += argument2; if (argument0 > argument1) return argument1; } else { argument0 -= argument2; if (argument0 < argument2)...
  19. RyanC

    GML 2 Color Lighting System - Surfaces & bm_max Issue

    Hi All, I'm wondering if anyone can suggest a better way of doing this: My lighting system uses 2 separate surfaces, 1 for all the background sprites and 1 for the foreground with the player and floor blocks etc. I am trying to achieve a system that will render these surfaces in the GUI_Begin...
  20. SirCaliber

    GML Any way to find Socket IDs while using UDP?

    So the server object and the client object both exist at the same time. But the client object on the host's (server) game seems to intercept certain packets. Basically I have it set up like this: Client sends a little packet to the server Server gets that packet and returns a handshake packet...