View Poll Results: Should I make more tutorials?

Voters
12. You may not vote on this poll
  • Yes!

    6 50.00%
  • Nah..

    6 50.00%
Page 1 of 2 12 LastLast
Results 1 to 20 of 21

Thread: GameMaker: Studio - First Game! (With Pictures!)

  1. #1
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default GameMaker: Studio - First Game! (With Pictures!)

    Hi Guys! I figured, that because I have learned pretty much all there is to GameMaker, that i would help others get started with their dream of being a developer! To start off, you will need GameMaker: Studio, which you can download from their trusted website here:
    http://www.yoyogames.com/studio/download

    What we will do after it is done downloading and installing, is open it up of course

    You should be greeted with a window like this:

    Name:  111.PNG
Views: 262
Size:  36.2 KB

    Click "New" Right where I have circled it.

    Then, click where it says "Project Name", and make it whatever you want. Then press "Create"!

    You should now be greeted with a window like this:

    Name:  222.PNG
Views: 263
Size:  28.2 KB

    Now, there is a section called "Sprites", right click it and click "Create Sprite".

    A window like this will show up:

    Name:  333.PNG
Views: 260
Size:  15.0 KB

    Name it either "spr_player" or "player_spr". Everyone does things differently!

    Then click "Edit Sprite".

    Now, click this little folded page, and click "Ok". It should be auto set to 32x32.

    Name:  444.PNG
Views: 259
Size:  14.1 KB

    Next, we will draw a sprite. There are several tools, so draw whatever you want.
    Be sure you click the sprite you just created, otherwise you can't draw on it.

    Be creative :P :

    Name:  555.PNG
Views: 261
Size:  58.3 KB

    Click the check-marks, to automatically save, and exit. Be sure to center the origin from clicking "Center".
    Name:  666.PNG
Views: 260
Size:  18.5 KB

    So, now that our sprite is done, we will create an object. Our object is what is placed into the game and does the actions we code.
    We do this by the same exact thing we did wit sprites. Just right click the object section, and click "Create Object".

    Now we name it "obj_player" or "player_obj".

    We need to assign that sprite we just created, so to do this, we have to click under where the word "Sprite" is.

    Name:  777.PNG
Views: 261
Size:  26.4 KB

    Assign the sprite, then we add an event. We will add the step event.

    So, to add code, we click over on the tab bar, we click "Control".

    Name:  888.PNG
Views: 261
Size:  28.8 KB

    Now, drag in the "Execute Code" Function. It is under the "Code" Section.

    Name:  999.PNG
Views: 261
Size:  35.8 KB

    So, we have a code window. What we will do, simply because I need to save space in this post, is I will just put the code for copy and paste.

    Code:
    //Movement
    hspeed = 4 * (keyboard_check(ord('D')) - (keyboard_check(ord('A'))))
    vspeed = 4 * (keyboard_check(ord('S')) - (keyboard_check(ord('W'))))
    
    
    //Collision
    if hspeed!=0
    if !place_free(x+hspeed,y)
    {
        if hspeed>0 move_contact_solid(0,hspeed)
        if hspeed<0 move_contact_solid(180,-hspeed)
        hspeed=0;
    }
    
    if vspeed!=0
    if !place_free(x+hspeed,y+vspeed)
    {
        if vspeed>0 move_contact_solid(270,vspeed)
        if vspeed<0 move_contact_solid(90,-vspeed)
        vspeed=0;
    }
    We will also need a wall. So just like before, create a sprite, just a simple square will work PERFECT! Then, create an object, and assign the sprite, BUT in this object, we will need no code. We will need no events, just simply check "Solid".

    Name:  101010.PNG
Views: 262
Size:  27.7 KB

    So, we have our sprites, we have our objects, now we need a level. In GameMaker, we use "Rooms". They just mean level pretty much. So, just like objects, and sprites, we create a room the exact same way. Right click the room section, and "Create Room".

    The room's GUI, is kind of confusing at first look, but gets really easy after a while. Here is what it will look like:

    Name:  111111.PNG
Views: 261
Size:  43.4 KB

    Finished Product:

    Name:  131313.PNG
Views: 259
Size:  6.7 KB
    So, from the movement code we used, we walk with keys "A", "D", "S", "W".

    So, first of all, where it shows the "Width" and "Height" of the room, we want to set Width to 640, and the Height to 480. Now, go to the "Objects" Section in the rooms tab bar. Then, select obj_player, and place in, and throw in some walls. Then you can run the game and see what happens! If you guys encounter errors, post them and i will tell you what is wrong, and if it worked for you, and you want more tutorials, I am happy to do it!

    Oh, and by the way, if your player is not a perfect square, you have to do this to fix collision issues!

    Name:  121212.PNG
Views: 261
Size:  28.7 KB

    If your wall is not a perfect square either, create another sprite named "spr_mask" and make it a solid red square. Mask all imperfect objects to it for perfect collision.

    CYA!!!!!!!!


  2. #2
    Master Sorcerer MyLegGuy's Avatar
    Join Date
    Mar 2014
    Location
    United States
    Posts
    1,631

    Default

    There's already tons of Gamemaker tutorials everywhere.

  3. #3
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default

    Quote Originally Posted by MyLegGuy View Post
    There's already tons of Gamemaker tutorials everywhere.
    So? 10 letters

  4. #4
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default

    Quote Originally Posted by LordFawful View Post
    This is a good tutorial, and I might try it if I learn more programming. For now, I make games with MMF2.
    Never heard of it xD

  5. #5
    Master Sorcerer MyLegGuy's Avatar
    Join Date
    Mar 2014
    Location
    United States
    Posts
    1,631

    Default

    Quote Originally Posted by ModSim View Post
    So? 10 letters
    This isn't really needed.

    And this isn't really that good of a tutorial.
    You don't explain the step event, or any of the code.
    Somebody with no experience would be confused.

  6. #6
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default

    Quote Originally Posted by MyLegGuy View Post
    This isn't really needed.

    And this isn't really that good of a tutorial.
    You don't explain the step event, or any of the code.
    Somebody with no experience would be confused.
    Okay... Odds are, people aren't looking at RTsoft for gml tutorials

  7. #7
    Master Sorcerer mrthadawee's Avatar
    Join Date
    Apr 2013
    Location
    Wales: The land of sheep and cider!
    Posts
    5,911

    Default

    Personally I like Construct 2 better, but that's my opinion, both offer basically the same stuff, I find Construct 2 to be just that more simpler..

    Not a bad tutorial, but surely wouldn't someone with the program would look at the official site for some tutorials first?, just my thoughts initially at least...

    I'm gonna add in one more thing, generally I like my sprites on a 2d platformer to be generally small (memory isn't an issue, it's just it's much easier to make smaller sprites and have the camera pan in to that size), I'd go 32x32, because IMO it's easier to work with. Also I find a neat little trick to do is to warp the width based on a certain variable if you want the sprite to for whatever reason grow or distort, handy for making crazy mirrors *cough* like in Growtopia *cough*.
    That's just one of the thousands of things you can make using these game making programs, it's actually quite fun to tinker around and make stuff with, when you get the general idea, the rest falls into place over time. Still interesting to find out what people can do with stuff like this.
    ---> I have changed my in game name to Thadirth. <---
    WiiU ID: Thadadir

    Thada's box of stuff *Updated 16/5/2016*
    #22: ":^)" edition

  8. #8
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default

    Quote Originally Posted by mrthadawee View Post
    Personally I like Construct 2 better, but that's my opinion, both offer basically the same stuff, I find Construct 2 to be just that more simpler..

    Not a bad tutorial, but surely wouldn't someone with the program would look at the official site for some tutorials first?, just my thoughts initially at least...

    I'm gonna add in one more thing, generally I like my sprites on a 2d platformer to be generally small (memory isn't an issue, it's just it's much easier to make smaller sprites and have the camera pan in to that size), I'd go 32x32, because IMO it's easier to work with. Also I find a neat little trick to do is to warp the width based on a certain variable if you want the sprite to for whatever reason grow or distort, handy for making crazy mirrors *cough* like in Growtopia *cough*.
    That's just one of the thousands of things you can make using these game making programs, it's actually quite fun to tinker around and make stuff with, when you get the general idea, the rest falls into place over time. Still interesting to find out what people can do with stuff like this.
    True. Also why did you make that your profile pic, it would be cooler if it was you when you where a mod. Just my stupid judgmental behavior :P

  9. #9
    Master Sorcerer mrthadawee's Avatar
    Join Date
    Apr 2013
    Location
    Wales: The land of sheep and cider!
    Posts
    5,911

    Default

    Quote Originally Posted by ModSim View Post
    True. Also why did you make that your profile pic, it would be cooler if it was you when you where a mod. Just my stupid judgmental behavior :P
    Because I prefer the look of the One Ring.

    Also, it seems somewhat egotistical to have a profile picture that implies I am a mod when nowadays I'm not a mod. There's tons of screenshots out there of me when I was a mod, I just don't see it as something to flaunt around like that.
    ---> I have changed my in game name to Thadirth. <---
    WiiU ID: Thadadir

    Thada's box of stuff *Updated 16/5/2016*
    #22: ":^)" edition

  10. #10
    Master Sorcerer Kittens's Avatar
    Join Date
    Nov 2015
    Location
    in a dustbin
    Posts
    1,016

    Default

    this looks like a more complicated version of scratch.mit.edu
    Quote Originally Posted by Hamumu View Post
    If this is really your best friend... then punch them and demand your stuff back! Some friend.

    ⚜IGN: BIBLA⚜

  11. #11
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default

    Quote Originally Posted by mrthadawee View Post
    Because I prefer the look of the One Ring.

    Also, it seems somewhat egotistical to have a profile picture that implies I am a mod when nowadays I'm not a mod. There's tons of screenshots out there of me when I was a mod, I just don't see it as something to flaunt around like that.
    I like your logic m8. It does not really make sense to have a profile pic of a mod when your not a mod :P

    - - - Updated - - -

    Quote Originally Posted by Kittens View Post
    this looks like a more complicated version of scratch.mit.edu
    Personally, I find scratch useless .-. It doesn't really teach you anything about coding, but I guess it inspires them to learn??

  12. #12
    Master Sorcerer MyLegGuy's Avatar
    Join Date
    Mar 2014
    Location
    United States
    Posts
    1,631

    Default

    Quote Originally Posted by ModSim View Post
    Okay... Odds are, people aren't looking at RTsoft for gml tutorials
    Doesn't that just prove my point?

  13. #13
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default

    Quote Originally Posted by MyLegGuy View Post
    Doesn't that just prove my point?
    Mkay, some people on the forums may be looking around here, in the development section, looking for tips on making a game. I learned to code without my code being described in a way anyone could understand. I actually learned to code from the guidebook built in to GM: S. So if they need to see what it means, they could look at the functions in it ey???

  14. #14
    Master Sorcerer
    Join Date
    Mar 2015
    Location
    Michigan
    Posts
    875

    Default

    Im just going to critisize that move_to_contact and using gamemakers solid feature is few of the worst ways to do collision. The use of hspeed and vspeed is also very horrific if you wanted more control over the speed.
    You should be manipulating x and y over your own xspd and yspd variables and moving to contact would be more optimized to have been made yourself. The more you use built in functions and features the less you get to change.
    Code:
    //horizontal collision
    repeat(movespeed)
    if (!place_meeting(x+xspd,y,parSolid)
    x+=sign(xspd);
    Now with this, any object of your choice that has the parent of parSolid, is now solid.

  15. #15
    Banned
    Join Date
    Jan 2016
    Location
    Alabama, USA
    Posts
    191

    Default

    Quote Originally Posted by peck View Post
    Im just going to critisize that move_to_contact and using gamemakers solid feature is few of the worst ways to do collision. The use of hspeed and vspeed is also very horrific if you wanted more control over the speed.
    You should be manipulating x and y over your own xspd and yspd variables and moving to contact would be more optimized to have been made yourself. The more you use built in functions and features the less you get to change.
    Code:
    //horizontal collision
    repeat(movespeed)
    if (!place_meeting(x+xspd,y,parSolid)
    x+=sign(xspd);
    Now with this, any object of your choice that has the parent of parSolid, is now solid.
    That is more of simple collision, but it still does the exact same thing. It is really no different than doing:

    Code:
    if(!place_meeting(x+<SPD>,y,<WALL>)) {
          if(keyboard_check(vk_right)) {
                 x += spd;
          }
    }
    Then, just doing this to all keys and directions. I have chose to use that code above. Although it is not the "simplest", it works better than any of the other collsion.

  16. #16
    Master Sorcerer
    Join Date
    Mar 2015
    Location
    Michigan
    Posts
    875

    Default

    Quote Originally Posted by ModSim View Post
    That is more of simple collision, but it still does the exact same thing. It is really no different than doing:

    Code:
    if(!place_meeting(x+<SPD>,y,<WALL>)) {
          if(keyboard_check(vk_right)) {
                 x += spd;
          }
    }
    Then, just doing this to all keys and directions. I have chose to use that code above. Although it is not the "simplest", it works better than any of the other collsion.
    It is entirely different from the next piece you just posted.
    Your tutorial example is pixel perfect collison while using an absurd amount of cpu cycles. My piece is pixel perfect collison in an optimal way. And the code you just posted claiming to be the same thing has no pixel perfect collision and is a mistake all GM noobs make.

    Not only does your tutorial example use more cpu cycles with move_to_contact, but the use of built in variables will have a domino effect on how many more if statements you're going to have to write to account for these variables that will always take immidiate effect.

    If you dont understand what you're doing entirely and want to share it here, have it approved and criticized in gm forums before you start a generation of games that use 20mb ram for a hello world.
    Last edited by peck; 01-26-2016 at 05:53 PM.

  17. #17
    Lesser Wizard VendLolx's Avatar
    Join Date
    Jan 2016
    Location
    Finland, Kotka
    Posts
    341

    Default

    Quote Originally Posted by MyLegGuy View Post
    There's already tons of Gamemaker tutorials everywhere.
    So?

    ............

    - - - Updated - - -

    Quote Originally Posted by MyLegGuy View Post
    There's already tons of Gamemaker tutorials everywhere.
    So?

    ..............
    VendTheNub's box.

    #3.: No need to post same thing again.


  18. #18
    Master Sorcerer
    Join Date
    Mar 2015
    Location
    Michigan
    Posts
    875

    Default

    Quote Originally Posted by VendLolx View Post
    So?

    ............

    - - - Updated - - -



    So?

    ..............
    The point is hes making a copy of tutorials that already exist and are best found elsewhere, and his tutorial isnt even a good one. I think it wouldve been more helpful making a list of GM tutorials as introducing to the community instead of trying to make a new one. Though its cool for people to actually take a step up and be willing to spread it, I think they need to be a little more credible.

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •