coding help

  1. JelleB

    global hp?

    Is there a way to have an hp variable that can be accessed anywhere in the game? I want the variable to stay the same until i change it. I'm pretty sure you use global variables?
  2. A

    GML How do I customize a menu inserted into o_game?

    Hey everyone, I am trying to create a customized menu as a separate object, however, the code in the object is not working. It should show a list of text options as the you'll see in the code below, however, currently it shows a black screen. Previously, the menu was drawn as a non-interactive...
  3. C

    Mac OSX GML: hp bar using hp sprites not working

    hi, im fairly new to game maker studio, and im having trouble with my healthbar. i coded it myself, but i cant get it to work, when i try to run the game i get an error upon running. this is the error message: ERROR!!! ...
  4. W

    How to code breeding in game

    I am wanting to make a web browser breeding game, or at least a game with breeding mechanics. A example of the type of game I want to create would be lioden. Basicly each character can have up to 10 markings in slots 1-10. There will be a list of markings made but each character can only have 1...
  5. M

    GML mark of the ninja visual queue for sounds

    Hi i'm having trouble imitating the ringlike visual queue to represent the sounds. I got the the rings appearing every .5 seconds when running but I cant figure out how to erase them. they just stay there and slowly fill up the map. i was wondering if anyone can help me with that?
  6. MegaJim73

    GML Toggling dual-wielding with one key

    I have 3 gun objects for an FPS I'm making. One is the main gun object (pstl) and two are when the gun is dual wielded (leftpstl and rightpstl respectively). All are children of the parent gun object (par_gun). The main problem I have with this system is that when I press the toggle key to...
  7. N

    How to get Gamemaker to remember the last room you were in?

    I am trying to get Gamemaker to remember the last room I was in so that every time I enter a room I can choose the starting location based on what direction my character came in from. My first idea was labeling the lastroom = room right before I transitioned from room to room, but the first...
  8. I

    Legacy GM [NEED HELP!!!] PAUSE MENU

    Thanks for looking, I have this code for a pause menu for 4 options: The "{# #}" Just represents the code group as a whole when I copied and pasted them. I am only getting 3 of the four options to show. Create: {# /// Initialize the menu title = "Game Paused"; option[0] = "Return"...
  9. S

    Need to run the game automatically at windows startup. Help!

    Hey Everyone. I'm working on a Mining-Simulation game. I wanna create an option/button within the game itself, which if enabled/pressed would automatically run the game at windows startup every time. Any idea how it can be done? Any code? Your guidance would be most appreciated. Btw, I'm using...
  10. D

    GMS 2 Help needed with code, collision_free

    I need some help coding this. What I want is to collide with solid objects but the things I wrote are either a) too long to read or b)not exactly what i wanted. (edit: the game is more like a Zelda/Pokemon platform) This here allows me to move and also collide with solid objects, which I want...
  11. B

    GMS 2 Continuing a dialogue

    HI, I need some advice to continue a dialogue. I follow the steps on this guy's dialogue tutorial. I have no plans on making a dialogue choice game. I just wanted to make a simple dialogue that continues the text. I add this dialogue code in my game. This is the blue dog's dialogue code...
  12. D

    fatal error when using particles to make blood! :(

    I am making a topdown shooter and am trying to code the blood effects below is all my code in all the areas that pertain to the blood code: this is the actual particle code in the create step of obj_blood_cont this is from following a video tutorial //Blood system partblood_sys =...
  13. L

    GMS 2 Trouble with attack animation not working/playing only one frame

    Hello! I'm really new to programming and game dev, and have run into a problem with my code. No matter what I've looked up and tired nothings been able to fix my problem. Does anyone know what i'm doing wrong? Any help would be appreciated, thank you. Below is my step code. I have a creation...
  14. N

    Malformed If Statement

    Gamemaker won't compile and says this code has a malformed If statement, but I can't find any out of place semicolons. //get the players input key_right = keyboard_check(vk_right); key_left = -keyboard_check(vk_left); key_jump = keyboard_check_pressed(vk_space); //react move = key_left +...
  15. D

    GML How to keep direction of player and use arrow keys to shoot?

    Hey everyone, I'm new to Game Maker and also new to this forum. I currently need help with keeping the player facing the direction it was moving. As of now, whenever the player is done moving the sprite resets and faces to the right when done moving. I want it to face whichever direction it was...
  16. J

    My player object is sinking, please help!

    I have a well functioning room and there's a portal. When I go to the portal with my player object I teleport to another room. In that room there is a different type of blocks on which player object should be able to jump and move on. BUT, the player is sinking. I assume there is a mistake in my...
  17. X

    i need help with a health bar issue

    Hi all, I'm currently working on a game for my college course, everything seems to be working fine, but the issue is the health bar, when the game starts up the health bar isn't at 100% more like 70% I think it might be a sequence issue but I'm not sure :/ I'll be ever so grateful if someone...
  18. G

    GML Problems in reading INI files

    Hello, I created a code in which, when an object collides with another object (obj_X) and you press spacebar something happens. Here is the code: My problem is that it will always send me to the room "Menu" even when in the ini file it says 1. What is happening??! Thank you so much
  19. M

    i need coding help

    i need an piece of code wich makes "monster" ignore and dont touch the "engerd" and still grab the "appel" and the "gouden appel"
  20. P

    How to create a timer?

    So I'm making a game for my friends and I, who love speedrunning, and so I want to implement a super-precise timer. How would I go about doing so? Is there a built-in function for timers? If what I want isn't clear, I want something that would begin counting up when a room begins, and that I...
Top