Scripts | Cutscenes [2]

Поділитися
Вставка
  • Опубліковано 18 гру 2024

КОМЕНТАРІ • 37

  • @FriendlyCosmonaut
    @FriendlyCosmonaut  6 років тому +16

    Note that some of the scripts in the video have > 2 arguments, however our system is currently set up to only handle 2. We address this in the next video! Also, some timestamps:
    0:50 - cutscene_play_sound
    2:03 - cutscene_instance_create
    2:51 - cutscene_instance_destroy
    3:39 - cutscene_instance_destroy_nearest
    4:51 - cutscene_change_xscale (change the "direction" the object is facing/drawing its sprite)
    7:31 - cutscene_change_variable
    8:58 - cutscene_move_character

  • @Capn_
    @Capn_ 6 років тому +8

    Your videos are soooo inspiring! I love your tutorials and how (for that one especially) you can create a simple and flexible system which are really adapted to every person who understands even just a bit of all the Gamemaker's stuff! Great job you're on the right way!!!

  • @MrYokashio
    @MrYokashio 6 років тому +4

    Only a week ago I submitted a game project for class and all of your videos have been super helpful! Using your cutscenes [1] video I had to try and make some of the scripts you made in this video. They worked just fine but yours always seem so much more refined. Thank you so much!

    • @FriendlyCosmonaut
      @FriendlyCosmonaut  6 років тому

      That's awesome - thank you!! Well done on adapting the system yourself, that's no easy feat :)

  • @Ver2ion
    @Ver2ion Рік тому

    had to rework some movement code but i gottt this working its so epic now all characters can move via code which is really cools

    • @QueenAceSpade
      @QueenAceSpade Рік тому

      I'm having problems with the cutscene_move_character. What did you do to fix it?

    • @Ver2ion
      @Ver2ion Рік тому

      i have a completely different movement system so i created my own cutscene functions that handle each player moving. you will likely need to make custom functions that are catered to your engine. once you understand how this cutscene system works you will be able to add pretty much anything to your game in a series of events. definetly a staple imo. @@QueenAceSpade
      for example in my game i have a system where when a player's move = true , it will move in its current direction 16 pixels or whatever the distance is. then when the movement is done the cutscene action ends. i created a cutscene function that tells a player to move, and sets their direction i want them to move, all npc's are built with the same movement as my player controller so that i can move any npc or player with the function.

  • @luminesparkz
    @luminesparkz 5 місяців тому

    You are just absolutely amazing at explaining things for me! I have been watching your videos for 2 years now and they have helped me so much! And I hate to ask this, but will you ever do a series on a cutscene system with sequences? (I’m so sorry I’m sure other people have probably asked this by now!)

  • @Occulydian
    @Occulydian 4 роки тому +6

    Would there be a way to make multiple scripts occur simultaneously? Being able to make two characters do different things would be valuable.

  • @duongvanphi862
    @duongvanphi862 4 роки тому +1

    So excited, I wanna be an game developer!

  • @Atma505
    @Atma505 3 роки тому +2

    Love this series, it's helped a lot! I wanna drop a quick question though, maybe somebody could help:
    Say you want o_npc to move to where the player is standing. You'd think the obvious solution would be to use cutscene_move_character(o_npc, o_player.x, o_player.y, false, speed). However, since all of the cutscene scripts exist in the Creation Code, this will return the player's X and Y values from when the room started, not the player's new X and Y values during the cutscene.
    Is there an easy solution for grabbing variable values that could change over time like this?

    • @MediaMotifs
      @MediaMotifs 2 роки тому +2

      Maybe this isn't the most efficient way to do it (and I know this reply is 10 months late lol) but could you not create a cutscene script that stores the players current x and y position in two variables just before the move object script is called? And then have the object move to the coordinates specified by those variables.

    • @Atma505
      @Atma505 2 роки тому

      @@MediaMotifs Yeah that seems like the right way to go about it =) The more stuff you can streamline in your obj_game or obj_cutscene object, the better

  • @_bubblezzzzzz_
    @_bubblezzzzzz_ 2 роки тому +1

    This has taught me so much. I have worked for a while trying to figure out why I can't change a global variable and ended up going about it another way. If anyone reads this and has an idea how to change a global variable with this cutscene system, please let me know. I can change a local variable, but when I try a global variable it doesn't work.

    • @_bubblezzzzzz_
      @_bubblezzzzzz_ 2 роки тому +1

      I finally figured it out. Going to share it here in case anyone else is having a problem.
      an example of one of my cutscene steps is this:
      scr_detect_and_answer_facing(object,distance,glob)
      in the function I put this:
      var answer = variable_global_get(glob)
      then check if it is true:
      if answer == true
      the problem I was having is I was trying to pass the entire global variable (global.whatever) in argument 3 but with variable_global_get it only expects the part of the global variable after the (global.) part.
      so for this function it would look like this : scr_detect_and_answer_facing(obj_player, 100, "whatever")

  • @nathan08085
    @nathan08085 6 років тому +2

    Thank you so much for these

  • @凋零地獄
    @凋零地獄 5 років тому +2

    is there textbox script for cutscene?

    • @vocenaoentendeunada2505
      @vocenaoentendeunada2505 2 роки тому

      Did you made it? I'm stuck in this too :/

    • @_bubblezzzzzz_
      @_bubblezzzzzz_ 2 роки тому +1

      I did Peyton Burnham's textbox tutorial and worked it in with this cutscene maker. It took a bit of adjusting but I got it to work with this. ua-cam.com/video/rEYSi0ahC5Q/v-deo.html

    • @MediaMotifs
      @MediaMotifs 2 роки тому +2

      I've simply done this:
      function cutscene_drawBoxes(argument0,argument1,argument2){
      ///@arg text
      ///@arg portrait
      ///@arg voice
      if !instance_exists(obj_textbox){
      create_textbox(argument0,argument1,argument2);
      }
      }
      And then in my cutscene object, I've added a statement to call "cutscene_endAction" with the cutscene object if there are no pages left, before the instance is destroyed.

  • @FirexXY
    @FirexXY 3 роки тому

    even making the fix you mentioned at the start of the video i still have the same error...
    Push :: Execution Error - Variable Index [1] out of range [1] - -1.scene_info(100080,1)
    at gml_Object_obj_cutscene_Other_10 (line 1) - current_scene = scene_info[scene]

  • @habarvaz
    @habarvaz 6 років тому +8

    Since you have a cutscene here that moves a character, I thought it would be fitting to mention that GMS 2 has a built-in path finding mechanism based on the A* algorithm. It's super easy to use, and can easily be incorporated into the farming RPG code that FC is teaching on, if you're working on that. This is a great video that shows how to use it: ua-cam.com/video/LUw78Tk70bM/v-deo.html

  • @GrandHighGamer
    @GrandHighGamer 6 років тому +1

    Nice video, though I'm not sure I see the utility of looping through the argument array just to assign it to another seperate array. Other than the minor benefit of an abbreviated name, you still have to do the exact same handling (i.e. making sure you only reference positions in the array if the argument_count is high enough).

    • @FriendlyCosmonaut
      @FriendlyCosmonaut  6 років тому

      Cheers - after reading through the docs I think you're right. I was under the impression that you couldn't reference the built-in variables argument0 etc at all if you don't supply the arguments, but I don't think this is true. I remember reading in the docs for argument_count that looping through the arguments was just a way to create optional arguments in the script - but I think as long as the logic works out, doing this is redundant!

    • @GrandHighGamer
      @GrandHighGamer 6 років тому

      You can't access them via the 'argument0' style when using optional arguments but instead have to treat it as an array i.e. 'argument[0]'. I had a look in the help file and I think I can see where you got the idea. I think it is just using a for loop as an example of quickly assigning the arguments to an array so that they can have their values altered further on in the script (just like you have to assign any ordinary arguments to a local var if you want to change their values), so it would be unnecessary if you only want read-only access to their value, or if you intend on assigning their individual values to more usefully named local variables.

    • @FriendlyCosmonaut
      @FriendlyCosmonaut  6 років тому

      Ah that makes perfect sense!! Thank you, I'll keep that in mind in the future.

  • @eleanorpolatch1092
    @eleanorpolatch1092 3 роки тому

    I’m trying to make a script that will make the object shake/jitter but I’m stuck - the object just moves and stays there. Any tips?

  • @juancarlosacunacanto8458
    @juancarlosacunacanto8458 4 роки тому

    Where did the event_perform in the create event come from? what does it do?

  • @FarronAnimations
    @FarronAnimations 4 роки тому

    What if the move character script was for a platformer game?

  • @Ragnark1
    @Ragnark1 5 років тому

    in a Json script, what is the difference between @param and @arg?

  • @joostkivits
    @joostkivits 6 років тому

    Really helpful tutorial!

  • @fierorecensione5828
    @fierorecensione5828 11 місяців тому

    TOP!

  • @cosmin4473
    @cosmin4473 6 років тому

    DO A Q&A GIRL

  • @Valehtelt
    @Valehtelt 6 років тому

    Woman? O?Rly?!