• 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!

index

  1. J

    GML How to change object with no sprite to object sprite that created it?

    When an object(with sprite) creates another object(no sprite) How can I make the object with no sprite be set to the one it was made from. I need this one object with no sprite to do this to multiple different objects.
  2. Y

    Missing Object Index

    Hi, I am a new program who changed from Unity to Gamemaker Studio because of you know why. And I am currently stuck on something that I've been trying to fix all day. I followed this tutorial online (), but every time I try to get a button to do something this shows up. ERROR in action number 1...
  3. DrStupid87

    SOLVED Why are my tiles are being replaced by the wrong sprite?

    Hi all, So in my project so far, an isometric map gets rendered: The buttons at the top raise or lower the z height of a tile that is clicked on. A script I have looks at the tiles surrounding the tile that was clicked and should place slopes around it like this: The problem is that it...
  4. S

    Push Execution Error...

    Hi, im making a multiplayer system on my game, im desenvolving a menu, nothing uncommon.. but i receive this strange error when i enter the room that contains the object that this code is in... Push :: Execution Error - Variable Index [3] out of range [3] This is the code that is giving me...
  5. AndreLeier

    SOLVED Return the index of a child object

    Hi everyone, I'm making a game and I want to get the individual index of a object, but only if it's a child of the obj_enemy parent. So I came up with this code. // Check if the mouse button was pressed if (mouse_check_button_pressed(mb_left)) { // Get the ID of the object clicked on var...
  6. FoxyOfJungle

    SOLVED Unable to get object for index 100001 ???

    Hi! It's the first time I've seen this error specifically. I'm starting to think it's a bug (or I don't understand this behavior), but I'll try to explain: #1 - I have this code in a script file (GML): Code 1: enum ENUM { ITEM1, ITEM2 } function ftr_setup() { global.list_of_itens...
  7. isaacyoshimario

    Timeline index out of order

    I'm trying to make a tower defense game, and everything seems correct, but the waves go in the order 4-1-2-3 for some reason. Waves folder: Create event: image_speed = 0; global.wave = 0; running = false; canclick = true; Step event: if timeline_position > timeline_max_moment(timeline_index)...
  8. flyinian

    SOLVED Parent and first child have same index/id?

    I am having trouble updating data when switching what is being selected(think of items in a store and when you click different items, it gives different data for each item). This is determined by the object's index/id when clicked. I noticed that the parent and first child of said parent has the...
  9. T

    GameMaker [Solved] how to change image_index for a drawn sprite?

    hello guys. I was wondering how you change the image index for a sprite that you draw (not the sprite associated with the object)
  10. S

    (solved)getting index from ds_list

    Create event exampleList = ds_list_create(); ds_list_add(exampleList,1); ds_list_add(exampleList,10); ds_list_add(exampleList,10); ds_list_add(exampleList,30); choice = 0; weight_sum = 0; for(var i=0; i<ds_list_size(exampleList);i++) {weight_sum += exampleList[|i]} Draw event if...
  11. J

    Question - Code Need help with random cursor

    Hey guys, So I have a sprite with 10 images, all different coloured cursors. Here is my code: if (room != rMenu) and (room != rControls) and (room != rUpdatesAndNotes) and (room != rShop) and (room != rEnding) and (room != rCredits) { cursor_sprite = sCursorGun; } else { cursor_sprite =...
  12. Pfap

    [SOLVED]Resource order and saving

    This is probably not a big deal, but is there a solution to avoiding resource conflicts when updating a launched game other than: once a game has been released never change the order of resources and if adding to the game only add at the tail of the tree? I guess, maybe saving the string name...
  13. FacesOfMu

    GameMaker Get the script name within the script?

    I see there's script_get_name(scr), but that requires the input of the script index. Is there anyway to get the name of the script the code is in without knowing the index? For example, objects have the "self" and "id" keywords to reference themselves. I'm looking for a programmatic way to...
  14. S

    GameMaker (Help) Array index out of range

    I was making a scrolling system in gamemaker 2 and I got an error I cannot seem to figure out! Create: Draw: Step: Error:
  15. H

    (Solved) Deleting/destroying room duplicates?

    Hello! I am using DND, but understand a bit a coding/gamemaker language. I am making a game similar to Doodle jump. As the player sprite leaves the top of any room it moves to the next room and if it hits the bottom of any room it goes to the previous room - simulating an endless sky. I...
  16. FacesOfMu

    How do you solve "index out of bounds" errors?

    Do you have a special method or tip on how to solve "index out of bounds" errors? Do you know a neat trick on cutting your investigation time? Please post your GMS2 list and grid access tricks! Pre-reading...
  17. S

    Legacy GM DS_grids - non reproducible bug

    I have been getting this bug with my DS_grids that seems random when it shouldn't be and I highly suspect it is a bug on game maker's side. at the start of the game I have this object creating global ds_grid's in Game start event global.invT = ds_grid_create(0,3) //item id, modifier, upgrades...
  18. A

    Windows sprite_index not working properly

    So i just bought gms2 and started a new project. as i started inserting animations i noticed something. Unlike in gm1 if i set sprite_index = 0 it just locks on set index now here is my draw event: draw_self(); show_debug_message("image_index = "+ string(image_index)); if hsp_ == 0 { if...
  19. YoSniper

    [SOLVED] 1D/2D array confusion

    Hello community, I recently ran into an issue using arrays that I don't remember experiencing in Game Maker 8. Basically, I am trying to initialize values to be stored in a persistent object that basically tracks my game data, and is responsible for saving to files and loading data back from...
  20. andev

    GML String functions that start at 0 instead of 1

    GM Version: Studio Target Platform: All Download: Download Links: <N/A> It bothers me that the string functions start at id 1 and not 0, because it means you have to add offsets sometimes. So I wrote some pass-through scripts that fix it. Further reading. All scripts are ready to drag straight...
Top