The RPG Maker Resource Kit

RMRK RPG Maker Creation => RPG Maker General => General Tutorials and Eventing => Topic started by: Katwithkatana on July 30, 2008, 03:47:27 AM

Title: Will someone link me or tell me some stuff.
Post by: Katwithkatana on July 30, 2008, 03:47:27 AM
Hello everybody. I'd first off like to introduce myself. I'm a new maker and me and my friend made a Company(We plan to sell our best games) called Kat With Katana Productions. Well since were new we'd like to know how to script and do some certain things. If you could link me to a basic scripting and Variable tut it would help! Thanks! Also I'm trying to make it to where someone tells my guy to talk to someone then after my guy talks to that someone the guy that told my guy to talk to him disappears will you tell me how?
Title: Re: Will someone link me or tell me some stuff.
Post by: yaeyae on August 04, 2008, 01:58:32 AM
If you are making a chain of linked events such as talk to Guy A, then Guy B, then Guy C, etc., it is best to a variable. A variable (at least in this case) is like a switch with multiple values. In this example, let's pretend you have a variable called 'Guys'.

On the Guy A event, the event would take place if the variable 'Guys' is equal to or greater than 0. Guy A would then tell the character to talk to Guy B. The event would then increase the 'Guys' variable by 1. Make sure to include a new page on event Guy A that occurs when variable Guys is equal to or greater than 1. Otherwise, the player could continuously talk to Guy A to make the variable increase indefinitely. On the new page, you can repeat the message, but not increase the variable. Guy A should also have another new page for when the variable is equal to or greater than 2, but this time there will be no message and no graphic (Guy A disappears).

On the Guy B event, make sure the variable constraint is set to equal to or greater than 1 so that Guy B will not appear until you talk to Guy A. Supposing there will be a Guy C, you can make him tell the character to talk to Guy C. The event will then increase the variable 'Guys' by 1. At this point, 'Guys' will be 2, which will make Guy A disappear as per your specifications. Make sure to make a new page for Guy B to prevent continuous increases again and if you want him to disappear after Guy C, make another page for that too.

If Guy C is the last one, his event will appear when 'Guys' is equal to or greater than 2. Whatever happens next is your choice.

As a side note, you could set each guy's event to work only when 'Guys' is equal to a specific number, but as soon as you increase the variable, the guy will disappear (which doesn't look good in a game). Ultimately, the design choice is up to you.