Move Route Script

● ARCHIVED · READ-ONLY
Started by celebrus 11 posts View original ↗
  1. Hi everyone!

    I am getting a bit sick of the way Move Routes appear in the Event box and how cumbersome it can be to make them.

    I'd really like to be able to, within the Move Route, put something in the "Script..." box like "ROUTE_MOVE_UP = 10" and that would take the place of:

    Move Up

    Move Up

    Move Up

    Move Up

    Move Up

    Move Up

    Move Up

    Move Up

    Move Up

    Move Up

    It would be dynamite if someone could make that possible. Thanks!!
  2. Be aware that the script may have bugs. For example, it doesn't repeat properly, so if you were to say something like



    Code:
    moves("4R4U4L4D")
    Which is basically moving in a square, you can't say "repeat forever" and expect the event to repeat forever.

    I have not figured out a way to deal with it.

    However, for cut-scene purposes, it should be fine...
  3. I actually found that one... It didn't work for me. After the movement is complete, the player is stuck. I have an event, which when triggered sets a move route for the player. The player moves but then gets frozen at the destination. Maybe I'm doing something wrong?
  4. Probably a bug. Maybe someone else can post a proper move route script.
  5. Actually, I haven't been able to use the moves("...") command successfully in anything I've tried. I have been playing with it for awhile. I've tried asking other events to move, reduced it to one step at a time... a lot of things. It always freezes when it reaches the end of the first moves("") command. I think it must be that I'm doing something wrong...
  6. Well, I found one problem.

    It's set to repeat forever because I didn't explicitly set it to false.

    Kind of stupid.

    So if you just add the three lines



    Code:
    def moves(string)
        move_route = RPG::MoveRoute.new
        move_route.repeat = false
        move_route.skippable = true
        move_route.wait = true
        ...
    You should not have the freezing issue.

    However, the fact that I'm creating a new move route is of concern.

    I'm going to try to copy the custom move route into the original list, so that these custom scripts are sort of like a macro.
  7. Thanks! It's an awesome idea for a script! Are you saying I should use those new lines or that you are going to post something different though?
  8. Download a new copy of the script. I just updated it to be a little better.

    The idea is simple: if the game sees one of my custom move commands, it will build a new list of move commands and then REPLACE my command with the actual instructions.

    Haven't really thought about any issues that might come out of this, but it means the list is no different from what the default engine provides.

    eg:



    Code:
    move up
    moves("DLR")
    move down
    Will be translated to



    Code:
    move up
    move down  # replace my command with the actual instructions
    move left  #
    move right #
    move down
    when the event starts running. You can use "repeat" and it should work fine because there's nothing surprising about the list.
  9. Sweet! Works great. Looks great.
  10. This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.