1. flyinian

    SOLVED Randomize total damage between several enemies.

    I'm trying to get the damage value to randomly split its number between several enemy's health. I've attempted to use choose and random functions but, wasn't successful. I've also tried storing the unit's variables into another variable and using that in code. I am trying to take the value...
  2. Nathan

    GMS 2 Randomize position by multiples of 24

    I have a very simple spawning object which randomly spawns an object every 2 seconds. What I would like it to do the spawner creates the objects in the same y position of the spawner, but the x position I want to be randomized multiples of 24 (ie. x, x+24, x+48, x+72, x, x-24, x-48, x-72 etc)...
  3. RyanC

    GMS 2 Random_Set_Seed() seems different for GMS 2 and no longer consistent between platforms.

    I've just had to update my app to support 64 bit so I purchased GMS 2 and imported my game. Within a few hours I had it running on Android but now my game is totally different. I spent many days selecting random seeds that would generate levels and nearly 100 of them were tested which took...
  4. F

    Randomizing Spawn throughout the game [SOLVED]

    Hello! For my game I'd like to spawn cars in randomized places (either a or b), randomized gaps between the spawns and then also randomized speed (altough I havent written the code for that yet) However, I encountered the issue that it is random at the start of the game but then it continues to...
  5. N

    Legacy GM [SOLVED]HTML5 Randomize () function

    Hello ! Does anyone know if there is an alternative for the randomize() function in HTML5? I have used irandom(), random_range() I've gone through a lot of threads and forums but I haven't seen a solution to this problem.
  6. Turkish Coffee

    Legacy GM a little question about "randomize();"

    Hey, as I'm messing with randomized AI coding, I'm in need of an information about "randomize();" Here, I have a code bracket that does things with choose(n1, n2) and random_range(x1, x2); if (state == "wander") { //randomize(); <--- if (alarm[1] == -1) { alarm_set(1...
  7. BaconMuncher

    Please Help Me Slowly Flip 28 cards

    Okay, I am using Game Maker Studio 1.4 and have my game project showing 4 rows of 7 cards each on my screen. Right now I have the user selecting 5 cards as to which card holds the missing princess. Once the user selects these 5 cards, all I need help with is slowly (like ever 2 seconds)...
  8. DividingByZero

    Legacy GM choose()

    I am curious if anyone has had this issue: I am using choose(s_map_1,s_map_2); to randomly choose between two sprites. And before this is run I am running randomize(); to get a new seed. The problem I am seeing is that despite the fact that I am doing a randomize (which I can confirm is...
  9. D

    How to make random decision using irandom and how to use randomize

    I have a room in which I put an object caller obj_music That object has a create event that executes a piece of code: randomize(); n = irandom(3); switch(n){ case 0: sound_play(cell1); case 1: sound_play(cell2); case 2: sound_play(cell4); case 3...
  10. jb skaggs

    Legacy GM Randomize() fixed my irandom()

    I am working on a concept version of a game. When I run this game always creates the same irandom values on the first run of the game. I found to make it actually work was to rerun the creation code under an alarm. So i knew it could work, so I deleted the alarm event. Then realizing that...
  11. N

    How to randomize a series of numbers?

    I need the numbers 10-5 in a random order, existing at the same time. Is there a way to do that without a lot of if loops? EDIT: I was a bit too quick on asking. I'm going to try ds_lists.
  12. U

    Random room

    Hi guys, I've been using GM for about couple of weeks now so I decided to start simple I'm making a quiz game for kids. Each room has a question with answers. When the game starts there's a "start game" button and when it's pressed the player starts in a random room. The problem is some rooms...
  13. M

    Legacy GM [SOLVED] Generating Random Number

    The results are always the same even though I invoked randomize() during initialization of the room. So I have this simple script var rgb1 = script_utility_randomize_rgb(); var rgb2 = script_utility_randomize_rgb(); show_debug_message( rgb1.red ); show_debug_message( rgb2.red )...
  14. F

    Legacy GM irandom picks the same integer every time?

    Hi. So I have randomize() ; set at the start of my game. I have an object that, on creation, is meant to pick one of three options, which then determine what text it displays. So for the create event I have the line 'line = irandom(2)'. I'm finding that every single instance created within a...