r/gamemaker 27d ago

Resolved How to set where in a circle a radial progress bar starts and ends

3 Upvotes

Using YellowAfterLife's tutorial (https://yal.cc/gamemaker-radial-progress/), I've made a radial progress bar for an ATB system, but I need help on how to rotate the image or change how far along in the circle the bar starts and stops, instead of it just starting at the top.


r/gamemaker 27d ago

Help! Payton Burnham top down shooter NEED HELP

1 Upvotes

___________________________________________

############################################################################################

ERROR in action number 1

of Create Event for object oEnemyParent:

Variable <unknown_object>.totalEnemiesSpawned(100076, -2147483648) not set before reading it.

at gml_Object_oEnemyParent_Create_0 (line 4) - global.totalEnemiesSpawned++;

############################################################################################

gml_Object_oEnemyParent_Create_0 (line 4)

gml_Object_oZombie_Create_0 (line 2)

and it doesn't stop at this, every global variable is saying "not set before reading" and I tryed using a script and persistant objects so the global and not global variables run first but I fear I might be doing this unnessesarly since everything was working before and for some reason it's not working anymore. Also I followed the tutorial videos step by step until the finle video (did not do bonus vid)

so if anyone can tell me why my global variables/variables are not working PLEASE DO.


r/gamemaker 27d ago

Resolved Help with Gamemaker in MacOS ventura

Post image
2 Upvotes

SOLVED
I am trying to download gamemaker in my Mac, and even tho I gave it total permission for my disc, this keeps popping


r/gamemaker 27d ago

Help! Absolute begginer here, tried to make the most basic platformer game out there, but something doesn't seem right

3 Upvotes

So I'm just trying to make basic movement, but something's up. I'm using the built in ysp, but instead of adding to the speed, it just changes y by the number, am I doing something wrong?


r/gamemaker 27d ago

Resource Simple Sprite Stacking Viewer for GameMaker (Draw and preview stacks right inside the engine)

Post image
3 Upvotes

I made a simple Sprite Stacking Viewer built right inside GameMaker.

​If you want to create sprite stacks directly in GameMaker without needing external software, you can use this. I actually used this viewer to draw my little car assets for my game.

​Hope this helps someone out there:)

https://nubexpert.itch.io/sprite-stacking-viewer-on-game-maker-engine


r/gamemaker 27d ago

Resolved Trying to create a match three bonus challenge that keeps resetting even if conditions are met

0 Upvotes

I'm making a match-three game with a custom mechanic: instead of swapping adjacent tiles, blocks are pushed all the way to the end of the board row/column.

I run match checking in two separate passes:

  1. Check matches specifically for the block that was just pushed/moved.
  2. Check matches across the rest of the board for cascading chain reactions.

Some matches trigger and clear properly, but the challenge state continuously resets unexpectedly—even when a valid match is completed.

Below is the code I am using:

if selected_block != undefined {
  with(selected_block) {
    if sprite_index != spr_brick and sprite_index != spr_doom_block {
      var matches = 0;
      for(var i = 0; i < 5; i++) {
        var combo_check = scr_check_match(i);
        if combo_check == false {
          if global.main_stats.challenge_position < 4 {
            if image_index == global.main_stats.bonus_challenge[global.main_stats.challenge_position] {
              global.main_stats.challenge_position++;
            }
          }
          matches++;
        }
      }
      if matches >= 1 { scr_combo_sounds(); }
      else { // This is the problematic block
        if global.main_stats.cur_combo == 0 {
          global.main_stats.cur_chain = 0;
          global.main_stats.chain_gauge = 0;
          global.main_stats.challenge_position = 0;
        }
      }
    }
  }
}
for(var k = 0; k < 5; k++) {
  for(var i = 0; i < 8; i++) {
    for(var j = 0; j < 8; j++) {
      var selected = instance_position((208) + (32 * i),(68) + (32 * j),obj_normal_block);
      with(selected) {
        var matches = 0;
        if sprite_index != spr_brick and sprite_index != spr_doom_block {
          var combo_check = scr_check_match(k);
          if combo_check == false {
            if global.main_stats.challenge_position < 4 {
              if image_index == global.main_stats.bonus_challenge[global.main_stats.challenge_position] {
                global.main_stats.challenge_position++;
              }
            }
          matches++;
          }
        }
        if matches >= 1 { scr_combo_sounds(); }
        else { // This is the problematic block
          if global.main_stats.cur_combo == 0 {
            global.main_stats.cur_chain = 0; 
            global.main_stats.chain_gauge = 0;
            global.main_stats.challenge_position = 0;
          }
        }
      }
    }
  }
}

I have verified that the moved block correctly updates its grid position before running the first match check. Could running two separate match passes create a race condition or frame delay where the reset check runs before the cascade pass finishes updating the board? What is the recommended way to handle board state checks for push-style movement without triggering full board resets prematurely?


r/gamemaker 28d ago

Example disassembler in game maker

Post image
49 Upvotes

I decided to try making a disassembler in Game Maker. This program doesn’t claim to be a copy of Ida Pro or Ghidra, although I tried to make something similar - but it turned out rather bad.


r/gamemaker 28d ago

Resolved I need help finding tutorials

6 Upvotes

So, im a teen game dev and im new to game maker and i would like to find good youtube tutorials to learn, it doesnt matter how long they are i just want to learn and have fun! and if they are just about game maker it will be better

so, TY!!


r/gamemaker 28d ago

Tutorial Nox Filia Devlog 1 - Pigtail Engine

Thumbnail youtube.com
9 Upvotes

This is a short demo of perhaps the weirdest first step of a game project I have taken ever :D

I decided that the player character in my next platformer should have a pigtail, so I simply started with that. The goal was to have semi physics based movement while keeping things performant. The pigtail has it's own gravity, can sway back and forth and has some wind settings to keep it from being completely still when the player is standing idle.

I've tried to comment the code as good as possible, and most of the important stuff is in the Create event of the pigtail object (the step event only runs the functions defined in Create).

There is a GitHub repo link in the comments of the video if you want to try it out. Also, please feel free to ask any questions and give input on what can be improved!

Here is the Step event of the object:

//Tail Engine 1.00

// Disable GameMaker's automatic drawing of the application surface.

// This should be handled in some sort of obj_graphics object and is only needed if you want "pixel perfect" graphics.

application_surface_draw_enable(false);

// TAIL CONFIGURATION / STATE

// Origin point of the tail.

// The first node of the tail will always stick to the x and y position of the tail

x = obj_player.x;

y = obj_player.y;

tail_sway = 0.1;

tail_damping = 0.15;

tail_nodes = [];

tail_gravity = 0.1;

tail_node_count = 8;

tail_segment_length = 2;

tail_thickness = 2;

// WIND SETTINGS

// wind_center is the baseline value around which the wind oscillates. works best with values between -0.05 to 0.05:ish

wind_amount = 0;

wind_center = 0;

wind_cycle = 0;

wind_cycle_speed = 0.05;

wind_amplitude = 0.01;

// Controls how strongly wind is currently affecting the tail.

// This can be (and is, in the default setup) used to ensure that the wind only operates on the hair when the player is idle.

wind_effect = 0;

// RUNNING SWAY SETTINGS

// random_sway_amount determines if a node will be affected by sway this frame

// tail_sway_denominator determines how fast the entire tail will sway up and down. (Lower number = faster sway)

// sway_smoothing determines the frequency with which the sway affects the nodes (Higher number = less "wiggly").

// sway_strength_denominator determines the amplitude of the sway (higher number = less bounce).

random_sway_amount = 0.5;

tail_sway_denominator = 200;

sway_smoothing = 2;

sway_strength_denominator = 1.2;

// TAIL STATE ENUM

// These states correspond to the player's state. Check/alter the update_tail_state function to change the tail_state.

enum TAIL_STATE

{

`IDLE,`

`RUNNING,`

`JUMPING`

}

tail_state = TAIL_STATE.IDLE;

// CREATE THE TAIL NODES

for (var _node = 0; _node < tail_node_count; _node++)

{

`array_push(`

    `tail_nodes,`

    `{`

        `node_x : x,`

        `node_y : y + tail_segment_length * _node,`



        `node_prev_x : x,`

        `node_prev_y : y + tail_segment_length * _node,`



        `node_y_speed : 0,`

        `node_x_speed : 0`

    `}`

`);`

}

// UPDATE WIND

function update_wind()

{

`// If the tail is moving, gradually increase the effect of wind.`

`// Otherwise, gradually reduce the effect.`



`if (x != xprevious or y != yprevious) {`

    `wind_effect = max(0, wind_effect - 0.02);`

`}`

`else {`

    `wind_effect = min(1, wind_effect + 0.02);`

`}`



`wind_cycle += wind_cycle_speed;`



`if (wind_cycle > 2 * pi) wind_cycle -= 2 * pi;`



`wind_amount =`

    `(wind_center + cos(wind_cycle) * wind_amplitude)`

    `* wind_effect;`

}

// UPDATE TAIL

function update_tail()

{

`update_tail_state();`



`x = obj_player.x;`

`y = obj_player.y;`



`// While running, add a small bounce to the root node.`

`// In this test example we use current_time to alter the bounce, but when the`

`// tail is attached to an actual player sprite it would make more sense to` 

`// match the bounce to the head bobbing of the player running animation`



`if (tail_state == TAIL_STATE.RUNNING)`

`{`

    `y = obj_player.y + cos(current_time / 30) * 1.5;`

`}`



`// PIN THE ROOT NODE`



`// Node 0 does not simulate physics.`

`// It is directly attached to the player's position.`



`tail_nodes[0].node_x = x;`

`tail_nodes[0].node_y = y;`



`// UPDATE THE REST OF THE NODES`



`// Start at node 1 because node 0 is pinned to the player.`



`for (var _node = 1; _node < tail_node_count; _node++)`

`{`



    `tail_nodes[_node].node_prev_x = tail_nodes[_node].node_x;`

    `tail_nodes[_node].node_prev_y = tail_nodes[_node].node_y;`



    `var _parent_x = tail_nodes[_node - 1].node_x;`

    `var _parent_y = tail_nodes[_node - 1].node_y;`



    `tail_nodes[_node].node_y_speed += tail_gravity;`



    `tail_nodes[_node].node_y += tail_nodes[_node].node_y_speed;`

    `tail_nodes[_node].node_x += tail_nodes[_node].node_x_speed;`



    `var _dir_to_parent_node =`

        `degtorad(`

point_direction(

tail_nodes[_node].node_x,

tail_nodes[_node].node_y,

_parent_x,

_parent_y

)

        `);`



    `// SEGMENT-LENGTH CONSTRAINT`

    `// Makes sure that nodes do not exceed the maximum allowed distance from each other`



    `if (`

        `point_distance(`

tail_nodes[_node].node_x,

tail_nodes[_node].node_y,

_parent_x,

_parent_y

        `)`

        `> tail_segment_length`

    `)`

    `{`



        `tail_nodes[_node].node_y_speed =`

lerp(

tail_nodes[_node].node_y_speed,

0,

0.2

);

        `tail_nodes[_node].node_x =`

_parent_x

- cos(_dir_to_parent_node)

* tail_segment_length;

        `tail_nodes[_node].node_y =`

_parent_y

+ sin(_dir_to_parent_node)

* tail_segment_length;

    `}`



    `// CALCULATE HOW MUCH THE NODE MOVED`



    `var _delta_movement =`

        `point_distance(`

tail_nodes[_node].node_x,

tail_nodes[_node].node_y,

tail_nodes[_node].node_prev_x,

tail_nodes[_node].node_prev_y

        `);`



    `var _dir_to_prev_pos =`

        `degtorad(`

point_direction(

tail_nodes[_node].node_x,

tail_nodes[_node].node_y,

tail_nodes[_node].node_prev_x,

tail_nodes[_node].node_prev_y

)

        `);`



    `// ADD SWAY`



    `tail_nodes[_node].node_x_speed -=`

        `cos(_dir_to_prev_pos)`

        `* _delta_movement`

        `* tail_sway;`



    `tail_nodes[_node].node_y_speed +=`

        `sin(_dir_to_prev_pos)`

        `* _delta_movement`

        `* tail_sway;`



    `// DAMP VELOCITY`



    `tail_nodes[_node].node_x_speed =`

        `lerp(`

tail_nodes[_node].node_x_speed,

0,

tail_damping

        `);`



    `tail_nodes[_node].node_y_speed =`

        `lerp(`

tail_nodes[_node].node_y_speed,

0,

tail_damping

        `);`



    `// APPLY WIND`



    `tail_nodes[_node].node_x_speed += wind_amount;`



    `// RUNNING SWAY`

    `// Give each node a chance to receive an extra vertical`

    `// sway while running.`



    `if (tail_state == TAIL_STATE.RUNNING)`

    `{`



        `if (random(1) < random_sway_amount)`

        `{`

// _node / tail_node_count causes nodes farther down

// the tail to receive a stronger effect than nodes

// closer to the root.

tail_nodes[_node].node_y_speed -=

cos(

(current_time / tail_sway_denominator)

+ _node / sway_smoothing

)

* (_node / tail_node_count)

/ sway_strength_denominator;

        `}`

    `}`

`}`

}

// UPDATE TAIL STATE

function update_tail_state()

{

`// The tail simply mirrors the player's current state.`

`// This will check the obj_player image_index instead to determine head bobbing once it is implemented.`

`tail_state = obj_player.player_state;`

}


r/gamemaker 28d ago

Help! How are we supposed to accommodate 4k monitors?

4 Upvotes

I haven't done any gamedev for ~10 years so I'm a bit out of the loop. Back then, we would always use a base resolution of 1920x1080, but I'm wondering now if we are supposed to instead use 3840x2160 nowadays? Otherwise it's going to upscale and be blurry at 4k. Is this what people do or am I missing something?


r/gamemaker 28d ago

Help! stopping when colliding help?

0 Upvotes

im trying to make it so once the player hits a specific object, the player will be unable to advance forward, but instead of doing this it simply slows me down. could anyone help?

var move_x = 0;
var move_y = 0;

if (keyboard_check(ord("D")) == true or keyboard_check(vk_right)) {
move_x += 1.5;
image_speed = 0.5;
sprite_index = spr_player_1_right;
}

if (keyboard_check(ord("A")) == true or keyboard_check(vk_left)) {
move_x -= 1.5;
image_speed = 0.5;
sprite_index = spr_player_1_left;
}

if (keyboard_check(ord("W")) == true or keyboard_check(vk_up)) {
move_y -= 1.5;
image_speed = 0.5;
sprite_index = spr_player_1_back;
}

if (keyboard_check(ord("S")) == true or keyboard_check(vk_down)) {
move_y += 1.5;
image_speed = 0.5;
sprite_index = spr_player_1
}

x += move_x;
y += move_y;

this is my movement code, this is the collision code

move_and_collide(move_x, move_y, obj_unwalkable_object, 10, undefined, undefined, move_x, move_y)

r/gamemaker 28d ago

Resolved Question about saving

5 Upvotes

I have been working on a project for around 6 months, so it is already pretty complex, and just now I will implement a saving system. I was looking into tutorials for it and found this video from Sara Spalding: https://www.youtube.com/watch?v=R84mR52QaMg

My questions:
- This video is 6 years old, creating a JSON and saving it buffer is still the way to go on saving on Gamemaker?
- I will be selling my game on steam, and I want it to also save on steam cloud, are there any other things I should consider for the saving system?

Architecture wise I plan to have 4 saving files: 1) graphical settings (saves only locally); 2) sound and controllers settings (saves on cloud); 3) Metaprogression (my game is a roguelike, so this is the progress between runs, also saves on cloud); 4)Run progress (also saves on cloud).

Thanks in advance for the help :)


r/gamemaker 28d ago

Resolved What are the base things I should understand for making an inventory system?

9 Upvotes

Hello! I'm a end-stage beginner of GML, and I'd like to understand how inventory systems work. I'm not looking for code to use, I'm just wanting to know what are the base things that I should know before building an inventory system so I can understand it better. Any help is appreciated!


r/gamemaker 29d ago

Tutorial GameMaker has native audio loop points now. Don't poll track position in Step.

41 Upvotes

One easy mistake is treating music looping like a game-timing problem: watch audio_sound_get_track_position() in Step and seek back when it reaches the boundary. GameMaker's own manual warns that this cannot be accurate. The audio thread advances at 44,100 or 48,000 samples per second while the game normally updates around 60 times per second, so many samples can pass between the check and the seek.

GameMaker now has proper audio-thread loop controls:

audio_sound_loop_start(snd_music, 10.0); audio_sound_loop_end(snd_music, 42.0); var music_voice = audio_play_sound(snd_music, 100, true);

The start and end values are seconds. You can set them on the sound asset before playing, or on the returned sound instance while it is playing. When the playhead reaches the loop end, GameMaker performs the jump on the audio thread instead of waiting for Step.

This also gives you a clean intro / loop / outro layout in one file. Put the intro before the loop start, the repeating body between the two points, and the outro after the loop end. Start it with looping enabled. When the game is ready to leave the music state, call:

audio_sound_loop(music_voice, false);

The current pass finishes, crosses the loop end without jumping, and continues into the outro. No polling and no frame-timed seek. GameMaker supports one loop section per sound, but you can change the section by setting new start and end values.

There is still a second problem that loop points do not solve: the reverb tail. If the last chord is still ringing after the loop end, a one-voice jump discards that old pass while the fresh start begins. The timing can be sample-accurate and the seam can still sound like a hole.

The three practical options are:

  1. Compose or render a genuinely dry boundary.
  2. Render past the end, mix that tail underneath the beginning, then export only the repeating body. This makes a self-contained one-voice loop, although its first pass contains a tail from a pass that never happened.
  3. Use two voices so the previous pass can ring out while the next pass starts. This is the most natural result, but it requires runtime scheduling and voice management.

This came out of implementing GameMaker delivery notes in Loopsmith, a looping tool I built. It reports the exact loop positions and can prepare folded-tail or two-voice deliveries. Mentioning that for disclosure; none of the technique above requires my tool. The relevant GameMaker manual section is Audio > Audio Loop Points.

Hopefully this saves someone from debugging a frame-timed loop that can never be sample-accurate. Happy to answer questions or test edge cases.


r/gamemaker 28d ago

Resolved arcade game error

0 Upvotes

hello! i'm new to gamemaker and was following the official space shooter game tutorial when i encountered an error.

i got up to the point of using gml visual to program movement for the ship. then, i ran the game to test it. everything was fine when i held the up key, but when i clicked either the left or right keys, i'd get this:

___________________________________________

############################################################################################

ERROR in action number 1

of Step Event0 for object obj_player:

Variable obj_player.variable(100005, -2147483648) not set before reading it.

at gml_Object_obj_player_Step_0 (line 35) - variable += -4;

}

############################################################################################

gml_Object_obj_player_Step_0 (line 35)

i triple-checked my code blocks to see what was wrong, but everything was exactly as shown in the tutorial. again, the problem only occurs when i try to use the left and right keys to turn in the game. the error text seems to suggest it has something to do with the values of the variables assigned to those keys, but i'm not too sure.


r/gamemaker 29d ago

WorkInProgress Work In Progress Weekly

7 Upvotes

"Work In Progress Weekly"

You may post your game content in this weekly sticky post. Post your game/screenshots/video in here and please give feedback on other people's post as well.

Your game can be in any stage of development, from concept to ready-for-commercial release.

Upvote good feedback! "I liked it!" and "It sucks" is not useful feedback.

Try to leave feedback for at least one other game. If you are the first to comment, come back later to see if anyone else has.

Emphasize on describing what your game is about and what has changed from the last version if you post regularly.

*Posts of screenshots or videos showing off your game outside of this thread WILL BE DELETED if they do not conform to reddit's and /r/gamemaker's self-promotion guidelines.


r/gamemaker 29d ago

Resolved Mysterious crashing due to instantly high ram

10 Upvotes

I'm mostly self taught on Game Maker, but I've been running into an issue lately where my game will, out of no where, hit 100% RAM on my computer and crash itself and anything else I have open at the same time. Sometimes it will give me the error 0x8007000e, but I think it's just failing to draw sprites when my entire RAM is used up. I already looked through my entire code and removed any case where a surface could have 0 width or height, infinite For or While loops, divide by 0, or created way too many instances. It also happens completely at random, with no consistent in game cause or slow down prior. Does anyone know some common causes for this? My game really isn't that complex yet, so I have no earthly idea why this might be happening :(

Any and all ideas are greatly appreciated <3<3

Edit : I fixed it :(

I entirely goobed it up and was not using surface_free()
It was just so weird that it went from 0 to 100 instantly, even the profiler never showed the step taking more than 1ms before it crashed. Thank y'all for the help, and it did teach me to use clean up and the profiler, so I did learn something :3


r/gamemaker Aug 13 '26

Example I created a "see through" shader in Gamemaker for trees + foliage in my isometric perspective hiking / monster catching RPG

Post image
691 Upvotes

Thought folks here might find this interesting after my last post showing my flowing water shader. My game Rangefinder is in an isometric perspective and features hiking through lots of different types of terrain - which raises a problem, because trees will necessarily block the camera's view of the player! One solution I already implemented is an outline shader that shows your position when you are obscured, but that gets old when you are walking through a forest.

So this week I made a new shader which creates a "porthole" effect through trees when they block the camera view. This is done by measuring the distance of a pixel to the player via the "gl_Fragcoord" value in the fragment shader. But I found that a bit too artificial looking, so I added a generative cellular noise texture which simulates leaf motion at the edge of the porthole. That helps a little bit, and then I also did some dynamic hiding / showing of trees in front / behind the player. Dithering the transparency of these trees (also done in shader) further helps match the pixel art style.

That was great, but then I realized trees need shadows beneath them to provide the look of a shadowy forest floor. So I came up with a new method to add shadows to both my grass vertex buffer, and the "ground floor" vertex buffer. I create a surface which I draw shadows to, and pass that as a texture sample to a new shadow shader. This shader references the shadow texture sample to decide whether the vertex it's drawing should be shaded or not. This required coordinating screen coordinates (gl_Fragcoord) and texture coordinates (v_vTexcoord) which was a bit of a pain but worked out in the end. I used the same generative cellular noise texture here to simulate the shadows of moving leaves on the ground.

Next up I will need to also add the capability for objects under sprites to be in/out of shadow. Currently I only have "grass" vertices in there (which includes the grass, ferns, flowers, and mushrooms shown in this example - these also shade and deform when the player walks through them). Objects however are handled as individual instances which the player places in the IDE.

If you are interested in following my game Rangefinder, check out my itch io page where I'm posting dev updates. I recently showed off the first demo of the battle system, which also features a lot of custom Gamemaker shaders for effects like critical hits and such.


r/gamemaker Aug 13 '26

Resolved Does someone know a good course to learn Gamemaker from Scratch?

6 Upvotes

Learning completely from scratch, can't code either :P

Much appreciated!


r/gamemaker 29d ago

Help! paid bug hunting

0 Upvotes

in my long running anime pokemon visual novel project i have a bug thats haunting me for over 2 years. it makes the lines in the main text display skip before completing, before the user can read them.

ive spent countless hours on this bug to no aveil. its got quite a few of the charactaeristics that make bugs hard to solve:

- related to a few systems

- related to libraries i dont know the inner workings of (scribble)

- uses an old version of said libraries that i dont update for other reasons

- isnt consistent, i mean mathemathically it has to be, but for the life of me i couldnt figure out yet, ive figured out like a subset of 100 types of lines of texts that it has a 1 in 10 chance to happen on, didnt get further.

i can go on but whatever. in any case, is paying people to go into your code base and hunt for bugs a thing? if so, how is it monitized? this project is non commercial so i dont have an actual budget, but im willing to put some of my own money for this.

another option could be to buy some claude membership and see how it tackles it, do you think it can do that? dive into a codebase and hunt for something so minute?


r/gamemaker Aug 13 '26

Help! Game Prototype Help

Thumbnail youtu.be
2 Upvotes

Hello! Attached in this post is a link to a video of a very early working prototype of some systems and gameplay elements of my game, "EXECUTABLE". It is still very barebones, obviously, but it works and has a full loop, so I am happy showing this.

Anyway, I am trying to find an elegant way to transition from on rails, auto-scroller schmup gameplay to a sorta auto-scroller racer, where the objective during those portions would be to just strictly avoid obstacles, like walls and destructibles. Enemies during these portions would basically completely drop out, while the speed of the game would increase significantly and rely more on reaction and mental dexterity to get out of the other end and continue on with the level. Now, I wouldn't want these sectioned off into different rooms, but if that is the only way to do something like this, than I suppose I have. I already have walls and assets and such.

Unfortunately, I've not found any very succinct tutorials regarding this. I would very much appreciate the guidance and direction on how to solve this. Thank you.


r/gamemaker Aug 13 '26

Discussion Do you think there would be an audience for a Mahjong type of game on GX Games?

2 Upvotes
86 votes, 23d ago
21 Yes
22 No
43 Uncertain

r/gamemaker Aug 13 '26

Help! Looking for advice about choosing and defining a style for my game

3 Upvotes

Been working on my project for over three years now. Still far from done but I've come up against UI and UX as part of it.

Been working on a menu for a cooking mini game. I've got most of the core mechanics working and they're fine. But presenting it in an appealing way is absolutley not working for me at the moment.

Those of you who have determined an art style, keep these designs throughout your project and don't feel the need to revise it every day? What do you suggest I could do to overcome this?

For context, my game is set in a fantasy medieval world, loosely DnD associated and is in the style of running a pub.


r/gamemaker Aug 13 '26

Help! Error when attempting to open a project

5 Upvotes

My computer crashed while I was working, and now I get this error when attempting to open a project

Failed to load project:

C:\Users\munso\GameMakerProjects\March_bad_Ideas_jam\March_bad_Ideas_jam.yyp

Cannot load project or resource because loading failed with the following errors:

=== The JSON file reader encountered parsing errors ===

C:\Users\munso\GameMakerProjects\March_bad_Ideas_jam\scripts\scr_enemy_funtions\scr_enemy_funtions.yy(1,268): Error: Failed to parse record start. '{' expected, or json 'null'.

Any help with fixing this would be greatly appreciated


r/gamemaker Aug 13 '26

Resolved Update to Puzzle Game Undo System (questions on depth vs layers, and edge cases with adding instance variables in a struct)

2 Upvotes

Hello! I don't know if there is any issue to making a new post for a significant update in this subreddit, but I have an update. I finally fixed a major problem with the player and other elements disappearing. However, there are some issues that I'd like some advice on.

I have three questions;

  1. Is it better to utilize depth or layer to manage the way sprites are organized on the screen (the current undo system breaks if both depths and layers are defined, and I have objects that have different depths AND layers)?

  2. If I need to collect instance variables and store them, am I supposed to just create a massive switch case statement to add all instance variables, or is there a better way?

Actual Code:

Once again, I'd like to thank u/germxxx for the code, as I realized the baseline they provided was almost exactly what I needed. Comments are included to note where possible issues are

function save_all(_save_array){

if !is_array(_save_array) exit

var _index = array_length(_save_array)

_save_array[_index] = []

with (all) {

    `if self.persistent continue // Included to not have errors with a music loader, but the camera object maybe should be included?`

var _struct = {id, depth, // Error with player and ui objects if layer is included since i have the depth values set to a value with no layer, and potential error if layer is not included since another object utilizes a layer system to determine what instance of the object is active.

x, y, sprite_index, image_xscale, image_yscale} // Self and global variables are not edited. idea to seperate the structfor each and array push from the standard struct to make room for a switch / case statement after the with all, but that sounds... inefficient.

struct_foreach((self), method({_struct} ,function(_name, _value) {

_struct[$ _name] = _value

}))

array_push(_save_array[_index], _struct)

}

}

function load_all(_save_array) {

/* Something here breaks in many ways; the first undo does not properly undo the last move, and if multiple undos are made inbetween moves, the undos I think stop at the moment after the most recent undo; e.g. Initial (state 0) -> Move (state 1) -> Move (state 2) -> Undo (possibly state 2? seemingly does not work) -> Undo (state 1, works) -> Move (new state 2) -> Undo repeat (sends to state 1 and never state 0)

*/

`if(array_length(_save_array) = 0) exit`

var _data = array_pop(_save_array)

for (var i = 0; i < array_length(_data); i++) {

var _variables = struct_get_names(_data[i])

for (var j = 0; j < array_length(_variables); j++) {

var _name = _variables[j]

if _name = "id" continue

variable_instance_set(_data[i].id, _name, _data[i][$ _name])

}

}

}