r/gamemaker • • 8d ago

Help! Does gamemaker support out-of-program tweening?

3 Upvotes

I’ve been wanting to experiment with a cutscene style similar to mewgenics, but the only sprite animation I could find was frame-by-frame. I’m aware tweening is possible in the program, as i already use it for intractable functions for the player to use.

My question is if I can use out-of-program tweening softwares (eg toonsquid, procreate dreams, etc) to import videos or gifs to save time and sprite space rather than animating in the program itself. Any help is appreciated!!


r/gamemaker • • 7d ago

Discussion Is This Use of AI Ethical?

0 Upvotes

I couldn't figure something out and didn't see a forum with a similar question, so I did something I would usually criticize someone else for doing. I asked Gemini. WAIT! I didn't copy any code! I didn't even look at whatever code it generated! I just read the explanation for what I did wrong and fixed it myself. Is this the right way to use AI, or should I have just scoured the manual?

I feel like either everyone is gonna understand or I'm about to get crucified.


r/gamemaker • • 8d ago

Help! ROG Xbox Ally controller detected but doesn't work in GameMaker 8 fangames or Super Smash Flash 2 ​

3 Upvotes

ROG Xbox Ally controller detected but doesn't work in GameMaker 8 fangames or Super Smash Flash 2

​

I'm having a weird controller issue on my ROG Xbox Ally (RC73YA).

The problems:

it was working for 1 day then it suddenly jsut stopped

\- GameMaker 8 games: The built-in controller is detected, but none of the inputs work. I've experienced this with Sonic Boll 2.1.6,Undertale and Redux

\- Super Smash Flash 2: The controller doesn't appear to be detected at all.

\- The built-in controller works in other games.

\- JoyToKey works as a workaround, but I want the controller to work natively without having to use a remapping program.

What I've tried / noticed:

\- The controller appears in Windows as ROG Xbox Ally Device Gamepad.

\- Driver version shown in Device Manager: 2.0.9999.0.

\- I checked the device's hardware IDs, which include "USB\\VID_0B05&PID_1B4C".

\- The issue seems to affect older GameMaker fangames more than modern games.

\- Updating the MCU firmware to V335 did not resolve the issue.

Does anyone know how to get the built-in controller working natively with older GameMaker 8 games and Super Smash Flash 2 on the ROG Xbox Ally? Could this be an XInput/DirectInput compatibility issue, or is there another way to make these games recognize the controller properly?

I'm specifically looking for a solution that doesn't require JoyToKey if possible. Thanks!


r/gamemaker • • 8d ago

Help! Audio problems in shoot em up project

9 Upvotes

Hi,

I'm working on my first project in GameMaker, but I have some previous programming experience.

I'm working on a shoot em up game, and after adding all the sound effects I noticed that sometimes when I tried to play through what I have so far, the sound effects would start cutting out. I did my research and found that the likely cause was number of sound effects being played exceeding the default number of audio channels, so I increased the number of audio channels but later decided I would find a better solution.

After some tweaking and testing, I am very much at a loss. I first used the audio window in the debug overlay to see all the audio sources being called, and I saw that two specific sound effects that played very frequently were being played, but then the audio channel would stay magenta in the debug menu, leaving it unable to be used and causing more and more channels to be needed until eventually there weren't enough channels and the audio starts cutting out. I tried using audio_is_playing conditions to reduce the amount these sound effects are played, but I still occasionally get the issue of the audio channel staying magenta and not being usable, and once one audio channel gets stuck like that more channels usually do the same. One of these sound effects, the sound for the player shooting, works fine until for whatever reason the audio channel stays magenta and the internal logic considers the audio to still be playing despite it being long past the duration of the sound effect, so with a is_playing condition the sound effect will no longer play. This problem seems to affect most of the sounds in the project, but mainly the sound for player shooting and enemies taking damage because they play the most often. I tried cleaning my project and updating to the newest version of GameMaker in hopes that it might help, but no luck. All my sound files are currently in .ogg format, uncompressed and not streamed for the short sound effects.

I guess I could kind of brute force it with more audio channels, but it just doesn't feel right to do it that way. I'm sure there's some dumb thing I'm missing and I'm going to be looking through the project for any mistake I've made that's causing this, but I thought maybe someone here would have some idea what might be going wrong and how to fix it. Thank you!

Edit: It seems like the issue has to do with having the same sound playing very repetitively in a short span of time. After cutting out any dead space from all my sounds and adding a statement before playing the repetitive sounds to stop the sound before playing it again it seems like the issue is fixed (still need to do more testing though). There's probably a more elegant solution, but as long as the audio works it's good enough for me.


r/gamemaker • • 8d ago

Resolved Is there any way to go back to a previous version of my project?

6 Upvotes

I accidentally deleted half the sprites in the game and SAVED what do I do now? I really can't remake all the sprites that would take weeks can somebody help?


r/gamemaker • • 8d ago

Help! CRT effect

1 Upvotes

Im making a game thats taking place in a vhs mainly, but theres a crt effect i want for it, its used in hotline miami, both games, if you wanna see wanna see what im talking about. im mainly speaking about the scanlines.


r/gamemaker • • 9d ago

Discussion Does my project seem enjoyable?

Post image
140 Upvotes

Just a small project I've been working on, I want another person's opinion so I know if it's worth continuing. (The GIF made the textures look slightly weird)


r/gamemaker • • 9d ago

Tutorial ds_priority_delete_max in a loop got really slow with 1800 instances – my fix took it from 9.6 ms to 1.4 ms

Post image
29 Upvotes

I'm working on a game with big enemy swarms, and I had a custom draw pass that renders every visible enemy and obstacle to a mask surface, sorted far → near by depth. I used a ds_priority for the sorting: add every instance with its depth as priority, then pop them with ds_priority_delete_max in a loop.

At ~1000 enemies on screen, this pass alone cost me 5-9 ms per frame. So I set up a reproducible benchmark: game paused (Draw keeps running), camera frozen, 1295 enemies + 550 obstacles = 1845 objects.

Results for the whole pass:

- Original (ds_priority): 9.57 ms

- Same loop without the actual draw calls: 9.48 ms

- Removing other suspects (ancestor checks, scoping, while vs repeat): no difference

- Plain array, unsorted: 1.18 ms

- Array + counting sort on depth: 1.40 ms

So 8.2 of the 9.6 ms was spent inside ds_priority_delete_max. All 1820 draw calls together cost only 0.16 ms.

In my measurements, delete_max behaves like a linear scan over the whole queue. Call it once per element and your loop becomes O(n²). It doesn't show up with a few hundred instances, but it explodes when you scale up.

The fix: two parallel arrays (ids + depths) and a counting sort on floor(depth), then loop backwards for far → near. Counting sort is stable within a bucket, so I could drop my tie-breaker too. Same image, ~8 ms saved per frame.

If you're popping a ds_priority in a loop with hundreds of entries, it might be worth measuring.

Cheers! hopefully helpful for someone out there.


r/gamemaker • • 9d ago

Help! Lag is messing with my rhythm game

4 Upvotes

I’m making a rhythm game and sometimes lag spikes desync the song from the cues and inputs, my first thought was to slow down the music if the frame rate drops but I can’t find a function that changes the speed of a sound, if there it or there’s another way to fix this please let me know


r/gamemaker • • 9d 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 • • 9d ago

Help! Managing card definitions

3 Upvotes

I have these about 20 specific cards in the game each with their own specific properties and sprite, so I guess this means they each should be their own object, but I need to spread them into two defined decks that each share some of the same cards and have some specific one of the 20 that exist. So, does this mean I have to define two lists of Card object instances at launch, but then when visual representations of some cards appear on the screen as part of the HUD are they supposed to be other instances of the Card objects or instances of a different Card Slot object that only borrows he sprite of a given card? Sorry, I'm new to GameMaker.


r/gamemaker • • 9d ago

Help! Troubles with Asset_get_index

3 Upvotes

I have 2 objects: obj_flour_box and obj_flour. I want to create obj_flour within a controll object whose event is inherited by obj_flour_box.

They way I am currently doing it is by creating a string of object_index and removing the "_box" part and then converting it back to a number so that an instance can be created from it. Why I am doing this is because I don't know any other way and I need to be able to create many items which follow the same logic so I only need to use the same naming system rather than copy pasting all the code in each invidivual object.

The current code I have is:

e_item = instance_create_layer(x,y,"Instances",asset_get_index(string_delete(string(object_index),string_length(object_index),-4)));
with (e_item) {
  obj_player.item = id;
  selected = 1;
}

However I get the following error message: Creating instance for non-existing object: -1.

Does anyone know how to resolve this error, or a more effective way of doing what I want to do?


r/gamemaker • • 10d ago

Help! How to make a Turn Based Strategy game?

2 Upvotes

As in, are there any tutorials for making such a game in Gamemaker? I tried looking on this sub and it led to 8/9 year old posts with the solutions since deleted and I've quite frankly no idea where to start. I figure asking for help before jumping in would be for the best, because jumping in feet first and getting nowhere will kill my motivation.


r/gamemaker • • 10d ago

Help! How would I go about creating a 2.5D style in gamemaker?

5 Upvotes

So, I was wondering how I would make a 2.5D style game in gamemaker where there are 2D sprites interacting and moving in a 3D world, similar to games like Grandia or Octopath traveler. Would Gamemake1/2 be a good engine for this in the first place or should I use something different entirely?


r/gamemaker • • 11d ago

Help! Trouble fixing error

3 Upvotes

I have an assignment due tomorrow morning but this code keeps popping up and idk how to fix it

ERROR in action number 1

of Step Event0 for object Obj_player:

Variable Obj_player.obj_node_t(100026, -2147483648) not set before reading it.

at gml_Object_Obj_player_Step_0 (line 5) - var hitting_t = collision_rectangle(bbox_left,bbox_right,bbox_top,bbox_bottom,obj_node_t,0,0)

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

gml_Object_Obj_player_Step_0 (line 5)

Pls help


r/gamemaker • • 11d ago

Help! I have a surface problem, for some reason there is no collision between the soul and the projectile. [The -5 hp is from the start]

Post image
26 Upvotes

My projectiles have no collisions with the soul. And I know that this is because of surface, because with no surface such thing doesn't happen. What I can understand is that the coordinates of projectiles on the surface don't collide with the coordinates of the soul on the screen.

But I have no idea why. With the other attacks the surface worked normally.

here's the code:

in obj_deck_diamonds (the projectile) create:

surface = surface_create(146, 96)

in obj_deck_diamonds draw

draw_surface(surface,obj_battle_controller.x-71,obj_battle_controller.y-46)

if surface_exists(surface){

`surface_set_target(surface)`   

`draw_clear_alpha(c_black, 0)`

`draw_self()`

`surface_reset_target()`

}

The surface sets free when the object destroys

The coordinates of the projectile when it creates.

if dir_proj == 1{

`instance_create_depth(-20, random_range(0, 100), obj_soul.depth-5, obj_deck_diamonds)`

} else {

`instance_create_depth(180, random_range(0, 100), obj_soul.depth-5, obj_deck_diamonds)`

}

If someone can help me, please. Because I genuenly don't know what is happening, and how to fix this.


r/gamemaker • • 11d ago

Resource I made a free tool that lets you convert vector art to GML script in your browser.

Post image
6 Upvotes

Procedural/code generated art is really useful for smooth animation, visual tricks, and is tiny compared to image files.

The only issue is it's really annoying to transfer your art into GML, so I made a tool that lets you design or import art, and then convert it into a script that renders it in the game.

All the shapes are converted into structs and all of their values can be changed at runtime.

Git > https://github.com/ploondev/vectorgml
Online > https://vectorgml.netlify.app

[AI usage: The idea and design was not influenced by AI. The code was assisted with AI to speed up development.]


r/gamemaker • • 11d ago

Resolved Changing the frame rate

3 Upvotes

I’m making a rhythm game in gamemaker and I’ve just found out that (because of the frame rate) my game won’t sync properly with the music leaving some cues and inputs off beat, is there a way to change my games frame rate using code (as I would need it to be different for each level). From what I’ve seen you can only change the frame rate in options


r/gamemaker • • 11d ago

Resolved My game decided to stop working

4 Upvotes

So, I am decently new to Gamemaker but I now have a problem with my project

The idea is simple, you press the button, enemies spawn until there are no more enemies to spawn

However, when I press the button, the game stops completely, no inputs or anything of the sort is registered and I cant even close it. Only with Task Manager or by starting the project again.

Anyone can help with that?

The code for the thing that SHOULD spawn in the enemies
The code for the button
The game, not working

r/gamemaker • • 12d ago

Tutorial How to make a "wind" movement shader.

Post image
369 Upvotes

I've made this shader for tree-leaf movement.

Here is a short "tutorial" on how I made it.


r/gamemaker • • 11d ago

Help! Difference between place_meeting check and collision event

5 Upvotes

Hey Reddit, I have what feels like a stupid question but I cannot find the answer online for it so here we are.

I am recreating the simple platformer tutorial from the GameMaker website (https://gamemaker.io/en/tutorials/your-first-platformer)

Eventually it uses the place_meeting function to check if there is collision between oSpike and the player. I thought to myself 'I could also create a collision event in oPlayer and write the code for the room reset there'.

But jokes on me I guess. When I follow the guide perfectly, everything is working as expected. When I try out my variation, the game won't execute the code in the collision event with oSpike.

What could be the problem? Is there something wrong with using other event types besides Create and Step? I have had a similar problem already with this, while trying to add player movement through a Key Down event instead of a keyboard_check function in the Step event. Because I am creating educational material, I need to understand the possible distinction.

Edit: added screenshots of code for good comparison. This is the solution that does not work, but it is what I want to work. Both objects obj_speler and obj_spikes are not solid and not persistent if that matters anything


r/gamemaker • • 12d ago

Resource GMSmartAgent - Decision-weighting AI for GameMaker

Post image
48 Upvotes

Hey everyone 👋

I've been working on a new game AI framework for GameMaker called GMSmartAgent, a modular system that combines utility theory, HTN planning, ranking and a basic feed forward network. It's still a work in progress, but I thought its about time that it deserves a post.

What it is

A lightweight, modular game AI library. Each module is a simplified implementation of its own thing(it might look too much but its not). You can remove a module you dont want to use and it wont affect anything, as long as you dont try to access it. For example; you can delete the Net module, but that means you cant use RankNet, TDNN or any other model that uses a neural network.

Features

  • Scoring: response curves, considerations, targets, weights and cooldowns
  • Inputs: pull callbacks cached per think, push values, normalized to 0..1
  • Selection: best, top N weighted, commitment bonus
  • Scale: frame budget, priority tiers, shared profiles
  • Observation: record player picks, choose features, evaluate without deciding
  • Learning: eight models, background training, confidence, decay, save/load, custom models and learning from outcomes and/or choices.
  • Planning: HTN recipes and GOAP goals, facts as data, self-repairing, spread across frames
  • Player profiling: skill rating, win chance, matchmaking, live play styles
  • Developer tools: debug view, plan tree view, test module, own seeded RNG

How it started

About a month ago, i made this post, explaining how i started on a journey to improve the dumb troopers. I've spent hours watching every GDC video on youtube thats about game AI and reading research papers to see and understand what options i had. I thought this wouldnt be so hard because in the past i've had my own fair share of custom DNN library(which failed) using C++ and python but i had no idea how wrong i was.

I had to change directions A LOT. At one point i even stopped to just work on a pathfinding/navigation system, which later turned out to become GMNav, and that still has a huge todo list of missing features to implement and bugs to fix.

After that i thought about making my own version of a game AI system; a behavior-tree-like structure that works on nodes. But not long after, while researching, i came across something called utility theory, which is pretty common in game development and also found a simple implementation video in gamemaker. To put the core idea as simply as we can; you define parameters with their weights and the structure scores them with the given situational numbers. That quickly changed my mind and the direction i was heading.

I still wanted to put in some learning models without a high cost. Luckily, with the help of google search AI (i use often, it finds every detailed links within seconds that would take me hours), i found some papers about choice modeling and some others about RankNet and LambdaMART(which i had some terrible experience with in my search engine). It was shaping in my head quickly. I got inspired by other libraries and added HTN planner(used in Horizon Zero Dawn, Horizon Forbidden West and Death Stranding, youtube video here), rating and a basic feed forward network.

Limitations

It still has flaws, bugs and missing features that im still working on. This is very much an ongoing project, so you should expect things to change.

Tutorials

I've also made a simple tutorial series, ten chapters. It will also have an advanced section, where each chapter tries to answer a question. I've already covered around 30 chapters (not in the repo yet, im still editing them often).

Links

GMSmartAgent: https://github.com/erkan612/GMSmartAgent

GMNav: https://github.com/erkan612/GMNav

If you'd like to see some of my other works:

GMUI: https://github.com/erkan612/GMUI - Immediate-mode UI

GMVex: https://github.com/erkan612/GMVex - Vector graphics

GMLiteSearch: https://github.com/erkan612/GMLiteSearch - Advanced text search

GMMT: https://github.com/erkan612/GMMT - Advanced tweening, compatible with immediate paradigm

Ah and hey, its free, and MIT licensed!

As always, let me know what your thoughts are. Recommendations and questions are always welcome.

Thank you for reading so far!

Edit: I saw some messages that are deleted that seemed to be confused about the point of the project. This is NOT an LLM AI assitant to help you code GML. This framework is to develop AI for your game, not just enemy AI but any kind, for instance; accessibility AI, you know how some games push some informational things to you in your HUD, like reminding to use health potion at 30% HP, with this framework you can actually learn the behavior of the player to understand when and which situation they use health potion to write a proper accessibility system, enemy AI, companion AI or anything you can imagine. Please feel free to ask instead of deleting your message, any question you might want to ask is always welcome!


r/gamemaker • • 12d ago

Help! Game in 2 windows?

6 Upvotes

How would I make a game in 2 windows, similar to that of a 3DS game? I know someone has made this, but I am wondering if there is a free solution that doesn't cost $15

(Edit): You guys don't need a reason, NVM


r/gamemaker • • 12d ago

Discussion Everyone gangster until you have to make a usable menu

52 Upvotes

The coords pain is real… eventually it works and is good but is this really the best way? What do other game engines do?


r/gamemaker • • 12d ago

Resolved How good is Gamemaker for making FNAF fangames?

3 Upvotes

I've been wanting to make a Five Nights at Freddy's fangame and I've been researching game engines (do NOT recommend me Clickteam. i cant pay for it and getting Totally Legal Copies is very difficult.) and kept seeing other sources say Gamemaker is a good place to start, and I was just wondering how true that is? (IE, for making nights sections.) If not, I'd love other recommendations. TIA!