1. P

    GMS 2 Limiting spawn rate of enemies?

    I'm creating a platform shooter in the trial version of GameMaker Studio 2 based off of HeartBeast's Platform Shooter series. I would like to create my own custom enemy spawning system, but I've run into a problem. Basically, I have a spawner object in my room that I've set two alarm events for...
  2. G

    How to use alarms to make a platform that appears and disappears

    I know that i can make this by using the alarms but i dont know how, i want to make a platform that is visible and solid for about 1.5/2 sec then it disappears and then appears again, can someone help me ?
  3. T

    Legacy GM Help with this Project

    Hello, I wanted to make some alarms as delays between bullets and when Reloading but I am really really lost with it. Nothing seems to be working for me. This is My Project -> The shooting system will be found inside obj_player_henry in the Global mouse...
  4. P

    Legacy GM [SOLVED] Understanding Alarms?

    I'm confused as to exactly how these alarms work in gamemaker because they're doing something unusual... If I use obj_switch.alarm[0] = 1; the alarm sets itself to a value of 2 for some reason. If I set the code as obj_switch.alarm[0] = 0; then the code sets it at 0 but doesn't run the code in...
  5. G

    Delta Time Alarms

    Okay, so I have recently got my game to a point where it is near completion and have been in the process of testing it on weaker computers to get a flavour of how it will perform. On my i7 laptop with a GTX960 graphics card it runs at a solid 200-300 FPS, this is good. However on other computers...
  6. S

    Legacy GM Problem with alarm on a script

    hi, i'm trying to set up a script that makes an object turn into a color when it takes damage: //damage_color(color) alarm[1] = 7 image_blend = argument0 if alarm[1] = 0{ image_blend = c_white } the problem is that when i call the function damage_color(), the object wont blend back into...
  7. The Last Random

    GML [SOLVED] Alarms, Delay and Decay.

    Hey everyone, I have run into a problem due to lack of knowledge. I am trying to make a little prototype to test an idea I have for a proficiency system (Irrelevant info) The Main functionality is that you start with 0XP, you click a button and you get +1XP, a small timer prevents you from...
  8. M

    Legacy GM GUI alarm issue

    I am trying to draw "Speed Up!" for 3 seconds after o_player collides with obj_powerup_speed I know how to draw "Speed Up!" to the screen but I do not know how to make it last for only 3 seconds. Currently "Speed Up!" will draw but it will never disappear Help would be appreciated Code in...
  9. D

    help with alarms

    when i run this code it instantly destroys the instance :/ alarm 0 is set to 40 and alarm 1 is set to 120 even tried 340 :bash: if alarm_get(1) < 30 {instance_destroy()} if (global.hp > 0) {if alarm_get(0) <30 {global.hp -= 20} }
  10. T

    Windows Having trouble figuring out how to get a projectile to fire upwards and then fall back down.

    I never really wanted to be part of this forum... I always feel awkward doing this, but I have been trying to solve this problem for some time. I'm working on my first game and I'm trying to get a thing like the fireballs that come out of the lava pits in Mario. Where a projectile launches...
  11. R

    GML [SOLVED] Problem with alarms

    Hello everyone In one of my objects, I have a piece of code where a for statement iterates through an array, and checks what is stored in all the array positions. According to what's in the given position of the array, an action will be performed. The thing is that I'd like to add a delay of 2...
  12. J

    Windows [SOLVED] Help with Projectiles

    Hello, everyone. I need some help with projectiles. I'm trying to limit how many projectiles my character can fire at a time based on a single key input, not held down and pressed. Here's a simple code for my archer character firing an arrow when pushing D key: if keyboard_check(ord('D'))...
  13. C

    GML Need help with collisions and alarms

    Hi - I've been having problems with how to collect resources with a collision event. What I want to happen is the player collides with the tree to cut some wood. The wood appears in their inventory every five seconds. The problem is that the alarm that I'm using never goes down due to it...
  14. Geners

    Shader interfering with code?

    So I have this game where so far when I hit an enemy I want him to blink (Achieved with some timers setting alpha to 0 and then back to 1 again) and then while he is blinking i wanted him to be brighter or shine. I was able to make the sprite brighter when he is hit through a shader. Hazzah...
  15. jana

    [SOLVED] function works different after click than after alarm

    I've set up a regular triggering effect, where I'm playing a string of piano notes, one note at a time, moving higher and higher in pitch. I start it with a mouse click on a button, then alarms are set, and the notes play indefinitely. The problem is, when I click the button, the first five...
  16. J

    Drag And Drop [HELP GMS2]Setting up Alarm

    Hi there. I am very new to GM2 and I am currently working through the drag/drop tutorial. In video 8 around 7:36 he adds set Alarm countdown. My set alarm countdown looks different and does not have a drop-down menu to select Alarm 0. I cannot figure out or find anything on setting up the...
  17. E

    Alarm Problems... [FIXED]

    MY ALARM ISN'T SETTING OFF! EXPLANATION: I have a piece of code in a create event of an object. global.playerturn = 0; alarm[0] = 1000; On the alarm[0] event I have this code: global.playerturn = 1; On the press z event I have: if (global.playerturn = 1) {...
  18. D

    (SOLVED) Can anyone figure out whats up with my alarm??

    My alarm only seems to end once I have took control of the enemy (which it shouldn't) it's set at a second (while i'm testing) but it won't run until the enemy goes into the control state. It's like the alarm only starts when the enemy enters the control state even tho I haven't told it to do...
  19. C

    GMS 2 [HELP] Reload System

    Hello everyone, I am new around here and with GML as well. So I am trying to make a reloading system for when my gun runs out of ammo. What I want to happen is when the "reload" variable gets to zero or when the user presses the "R" button, alarm[0] will get set to 2 seconds and then 11 will be...
  20. D

    Legacy GM Sprite Index won't change back after Alarm

    I changed my enemies sprite when they were hit with a bullet and set an alarm to reset it, but the alarm portion isn't working. Does anyone know what I forgot in my code? Create Event: hit = 0 Collision Event with obj_bullet: hit = 1; Step Event: /// Enemy Flash when Hit if (hit = 1 &&...