coding

  1. Luke Pierson

    (SOLVED) Need help with animation end...

    Help me please :) I'm trying to get an object to return to its idle animation after teleporting. Step event: if position_meeting(Fence.x, Fence.y, Fence) { sprite_index = spr_cleric_teleport; } if sprite_index = spr_cleric_teleport { if image_index = 5 {...
  2. Luke Pierson

    Programming Animation Hell. Please help :)

    Hello! So I've been working on an enemy for my game that will run away from the player and then teleport back to the center of the map if they reach the end. The whole time, they shoot projectiles which must be dodged. (Think Wizrobes from Zelda) The problem: I have it set to where if the...
  3. H

    Legacy GM Wall Sliding Animation Assistance.

    Hello, I am not sure if this is the right section on the forums for this, but I've been trying to figure out how to code so I can have my wall slide animation. I've coded it for my running and idle, but can anyone give me a sample of how to do it so it'll show and work when sliding down a wall...
  4. C

    [SOLVED] Problem with my player

    So, I am following this tutorial https://www.youtube.com/playlist?list=PLUQ0xH2XyXgHWa-wC1X1q2sG8lzEuqzGe (Made by Making Games 101), and I am in the perfect top collisions episode; And he made us change the step event code of the player, but now, the player walks super slow in the top and the...
  5. Luke Pierson

    (Solved) Hspd not set before reading

    So I'm pretty new to GameMaker, I've been following some videos to help me grasp some things, but this one has me stumped. I'll post the error and then my code below. ___________________________________________...
  6. D

    Windows How Can I make Auto Background Change?

    hello! i am trying to make a running game. In that game i want to change the background after every 40 seconds like in game like jetpack joyride. how can i ? any ideas..?? Also, A location in my game contains 4 backgrounds which are parallex. i want to change the location(backgrounds) every...
  7. O

    Game Mechanics Armour / weapons / Stats

    I'm looking for a way to implement a system in which the player can equip armour and weapons, that not only affect stats but also changes the appearence of the player, but I have no idea how I would code it I've though of 2 possible solutions but still, I've no idea how to code it in GML...
  8. S

    Drag And Drop Step Event Control questions

    So I'm using the step event to determine the controls being input into the game not everything is in there yet because I'm transferring across from Drag and Drop coding to executable code blocks. My problem is with that mess of a code going on in the "if RELEASE" part of the code, to explain...
  9. Luke Pierson

    (SOLVED) Need Help with collision coding

    Hello! I'm making a game with randomized level generation using the tutorial by Heartbeast (link below): The video is part 2 in his series, it's about collision with the randomized background walls. In the video, he uses keyboard controls for his player, setting them to variables (hspd and...
  10. D

    Android IAP Coding Issue (Android)

    I'm am totally lost with the IAP example when trying to create a IAP code to do just one simple little thing. I'm not trying to sell things over and over again I just want to offer people an option to open up a certain room after they buy a ticket. Attempting to follow the example and a few...
  11. R

    Legacy GM [SOLVED] About an object following the player

    Hi all! So, in my game, when I press '1', it creates a shield around the player, which will protect the player from enemies. Everything with that works fine. The problem is, the shield doesn't follow the player when the player moves and that's not what I want. I want the shield to always be...
  12. T

    Player Keeps Walking Right?

    Heya! I'm so pissed at this because I can't figure out what's causing it! I've been working on a Super Mario Bros. 3 clone and I'm trying to have the player slow down to a stop instead of just instantly stopping (like in the game), but something's keeping the player slowly walking to the right...
  13. T

    Legacy GM Block will not change state/Singular block

    I was trying to make it when enemy breaks the block until global.block1_hp = 0 then it should switches to broken state but it just glitches out. I've tried everything to fix it. Basically what happens is the enemy is stuck cause the block is still in full state and it won't change to destroy...
  14. F

    Alternative Multi Platform Code Editor for GML

    I'm a new kid on the block. Just wanted to share a link to my favorite external text / code editor ever, that works great for anything related to ... well, coding. Sublime Text is awesome, and you can use it for free for as long as you like. It works equally well on Linux, Mac and Windows...
  15. R

    Legacy GM how would you design a menu

    How would u design a menu like : would u have different rooms for each part of the menu, or u would u have 1 room and use images and when a click on 1 option it deletes all objects in room and replaces them with whatever objects is needed for the menu option u selected. if u go with making...
  16. A

    Random Draw Text

    I'm trying to display a random text message once an object is created. I have this in its "create" eventt. var randS = random(2); switch (randS) { case 0: draw_text(view_wview[0]/2,70,"Scripture 0."); break; case 1: draw_text(view_wview[0]/2,70,"Scripture 1.."); break...
  17. S

    Alarm Triggered by Movement Speed

    Ok, I'm trying to set up an event for an NPC so that when its speed reaches zero, it triggers an alarm that counts down and ends the game when it reaches 0 but resets when the NPC begins moving again. Basically, the player has to keep the NPC moving or the game ends. I've got it working to where...
  18. A

    Legacy GM Hiding and revealing "Player" object when pressing "C" key

    HI there, I want my player to hide in closet (called "obj_door") when I press "C". So my reasoning at the moment is to check to see if Player and closet objects are touching, then change the closet sprite and "hide" the Player object until you release "C" where it will go back to functioning...
  19. P

    Legacy GM How to make a button

    How to make button such that if a sprite exists at certain coordinates and the button is clicked it repeats a certain number of scripts again. I tried this code but it didn't work: if (mouse_check_button_pressed(mb_left) && point_in_rectangle(mouse_x, mouse_y, bbox_left, bbox_top, bbox_right...
  20. R

    Help with coding if a variable is relative

    Hey, I've been using Game maker for a while, and I've begun to develop practice games and such. So far, I have made a health system that uses purely code. I know that it is a little weird to not use the feature of drag and drop, but is there a way to make a variable relative or not through...
Top