varaibles

  1. L

    GML Visual poor detection of global variables

    Hello, I am having a problem detecting the values of a global variable. The problem is the following: I assign a global variable when the player is created which detects how many bullets the player has and that every time he shoots a bullet is subtracted, when I wanted to animate the bullet...
  2. Cheap Shampoo

    Check for highest variable value at same position?

    I was wondering how I could check through all the objects at the same x,y position and find the highest value between them? If I have a block that is z = 0; also another block in the same x,y that is z = 20, and another at the same x,y with z = 40; How could I check that x,y position and have...
  3. R

    SOLVED variable returning absurd value

    Hello everyone, I have a problem with a variable that is returning absurd values and I don't know why. It all started when I was fixing my variables, making them more editable and easier (print below to understand better): when I went to fix the alarm code for one of my objects, I noticed that...
  4. giraffeman210

    Created Instance that can change creator's variables?

    I am trying to make something where an instance is activated and it creates a different instance. and I need it so the created instance knows the creator. This way when you activate the newly created instance it changes a variable on the instance that created it. Any ideas? Thanks!
  5. G

    Game maker studio no longer recognizing defined variables in room? Help?

    So I opened up my project today, which was fine earlier. and all of the sudden my enemies started behaving awkwardly. I did some digging, and found that the game is now completely ignoring the variables I set for instances in the room with the "variable definition" tab on the instances. It still...
  6. KPJ

    GameMaker gms2 variables (SOLVED)

    Hi everyone. I am making a top down shooter and I need help. I want the player's x and y position to be stored in a variable at a certain time in the game. How can I make it so that the variable never changes( when i set the variable to the player's x and y) it constantly is changing every...
  7. G

    GameMaker Create variables automatically

    Hey there, I need help with a mission system. The game automatically creates some missions (for example: with x amount of fuel you have to go y meters high) and the player then decides which 3 missions he would play. Now I have a problem with storing the values to reach (height, fuel, ...). Over...
  8. JEMcG

    GameMaker <unknown variable> not set?

    Hi, I've been following FriendlyCosmonaut's video series that instructs on how to make a Farming RPG. In the section about Item descriptions I get the following error: ___________________________________________...
  9. M

    GML Program Function Questions...

    Questions 1. Is there a function to figure out the direction to an object without actually pointing to that object? 2. Is there a way for an object to assign a variable to another object when the first object uses instance_create_layer Example: obj_player creates bullets...
  10. B

    Putting variable in a variable?

    Hello, I'm new and just looking for some help. I'm wondering if its possible to put a variable in a variable? Example: skin_stand_down = spr_stand_down[global.skin]; I'm trying to get skin_stand_down to be read as spr_stand_down0 etc. If this isnt possible is their any other solution for...
  11. G

    DND - Reduce Var while key is pressed

    I am trying to reduce a var while the Space is pressed, I have a var set to 100 and under the Space key pressed event I have it set to -10. It does reduce for each key press but I want it to reduce -10 for each 5 secs the key is pressed.
  12. T

    Help with random numbers and using those random numbers

    I'm trying to make a randomly generating item generator. that will make another item at that location that will repeat the same code but with different variables etc. let's say that the object before it picked 3 (down) So what it would do is R1X= 3 //from before when the object before picked...
Top