Tutorial: How to Use a Script

in Resources, Tutorials

RPG Maker VX is a powerful engine, and the thing that makes that engine powerful is RGSS2. All RPG Maker VX games run on RGSS2, which is a scripting language that uses the Ruby programming language. Today, I’m going to explain a little bit about how to take advantage of this powerful tool.

Now, I know what you are thinking, “I don’t know how to program! How am I supposed to make a script!”. Well, the good thing is that in most cases you won’t have to. The RPG Maker user base has a huge amount of coders in it, and they make premade scripts to be inserted into a game. You can search around on the net for scripts made to do any number of things.

To explain how to use this, let’s assume you want to have your characters heal their HP and MP on a level up. If you look through the database, you will quickly find there is no way to do this! That is where my good friend Jet will come in. He has made a short script titled Level Up Effects. You can grab it in a text file below (you can also visit his thread on rpgmakervx.net which contains a massive number of small scripts using the source thread button).

Now that you have the script we use, lets learn how to put it into your project.

  1. First open the script editor.

    You have three options for getting there. You only need to use one. No reason to get carried away.

  2. You will see an intimidating amount of text. Don’t be scared. We won’t be touching most of it. Scroll down the list on the left of all scripts in the project. Right click where it appropriately says ( Insert here ) and select Insert.
  3. Select the blank script are you inserted and type the name of your script in the Name: box.

    Since we are using Jet's Level Up Effects in this tutorial, name it Jets LUEffects (Hey, its almost like this script stuff makes sense)

  4. Select all of the text in the script linked above, and then paste it into the large box on the right side of the script editor (make sure the correct script is selected in the left box).
  5. Now that you have your script in the editor, lets read the instructions that are contained in it. Instructions will be written in comments, which are specially marked part of the script that the game will ignore when it is running. They will appear as green text in the editor. Instructions will generally contain how to adjust parts of the script to get what you want it to do. Always read all instructions in a script. Ignore them at your own peril.
  6. So we have the script in the editor, we need to set it to do what we wanted to originally. We were trying to make characters heal to full hp/mp at level up. So lets go through and turn ON that option in the script, and turn off any other. When reading the instructions you will notice that HP/MP max on level up is already on, so we just need to turn OFF other options. Read the instructions on how to do this. The image below shows what needs to be changed.

Things to Keep in Mind

  • Make sure to check the instructions of a script for any incompatibilities. Meaning two scripts that will not work together.
  • Check to make sure you insert the script in the proper place based on the instructions
  • ALWAYS CREDIT YOUR SCRIPTS. These guys do a lot of work to give you more options, give them some love too, put them in your game credits. (This goes for all resources)
  • If you are working on a commercial game (a game you plan to sell), make sure the script is allowed to be used in commercial products. Most scripts made are for noncommercial use only, but you can always contact the script creator to attempt to work out some sort of deal to use it legally in your game. (This also goes for all resources)

Thanks for reading! Any questions, comments, or unending praise you want to heap on me, just leave a reply in the comments section below.

12 comments… add one

Leave a Comment