Make Your Own Game Tutorial X

Transcription

Make Your Own Game Tutorial X
Make Your Own Game Tutorial X: Events Part 3
Introduction
In Tutorial IX, we started learning how to store
information as switches and variables, and also learned
how to implement flow control into our events. In an even
earlier tutorial, we learned how to set the appearance of
events. But the thing we haven’t really examined is how
events start, and how to change events permanently.
In this tutorial, we will expand on the eventing
knowledge we have by learning those exact skills.
First we will cover how events START. This is done
with Event Triggers. There are five event triggers:
1. Action Button
Event Page Conditions
2. Player Touch
After that, we will move on to learning to use Event
Pages! Event pages are like superpowered conditional
branches, allowing events to be permanently changed.
3. Event Touch
4. Autorun
After the conditions are met, you basically have a
whole new event to play with, allowing you to set different
graphics, different event triggers, different move routes,
and an entirely new effect!
5. Parallel Process
While few in number, these five event triggers can
cover everything you will need to do.
http://www.rpgmakerweb.com/
1
Make Your Own Game Tutorial X: Events Part 3
Event Triggers
Event Triggers are pretty simple. All you have to do is
think: How and why do I want this event to start?
You have two main groupings of Event Triggers,
which I call:
1. Interaction Triggers. Interaction Triggers use
some form of player input or control to start. Such
as touching an object, allowing an object to touch
them, or pressing the action button while on top of
or adjacent to the object.
2. Automation Triggers. Automation Triggers start
automatically. As soon as the player is on a map with
one, it starts.
Setting the Event Trigger of an Event is incredibly
simple. You can see in the image to the right that there is a
easy to find selection box in the bottom left section of each
event.
Just select the Trigger you want and you are ready to
go. Now let’s look at these closer!
http://www.rpgmakerweb.com/
2
Make Your Own Game Tutorial X: Events Part 3
Interaction Trigger: Action Button
What is this used for
This is probably the most common type of event
trigger. It gives the Player the most control over when they
want to activate the event.
Any time you want the player to activate the event,
you should probably use Action Button triggers. We’ve
already used this quite a few times in what we’ve made so
far.
Examples of use include talking to NPCs, flipping a
lever, opening a treasure chest, or any other situation where
the player should be in control of whether to start the event
or not.
Things to keep in mind
How it works
There generally isn’t any special considerations with
Action Button events.
When the player presses the action button while
in the proper position (when on the same tile for events
that are above or below the characters, when adjacent and
facing the event for events that are at the same level as the
characters) the event starts.
The only thing that occurs to me to keep in mind is
that facing doesn’t matter on above or below level events,
so if your scene will need the character facing a certain way,
make sure to use a Set Move Route command so they are
facing the direction you want them to.
http://www.rpgmakerweb.com/
3
Make Your Own Game Tutorial X: Events Part 3
Interaction Trigger: Player Touch
What is this used for
Player Touch events are also incredibly common. Any
time that you want something to happen when the player
enters a specific spot on your map, regardless of whether
they start it themselves, you use Player touch.
Examples of use include depression switches on floors,
all types of transfer events (stairs, edge of town, etc.), and
starting cutscenes.
Player touch is generally used either when you want
something to happen the MOMENT the character moves
to a square on the map, OR when it is just faster than
making them have to push a button just to travel to the
next map.
Things to keep in mind
How it works
The biggest thing to keep in mind when dealing with
Player Touch events is that it comes into effect only when
the player moves INTO the event.
This is also a relatively simple trigger. The moment the
character moves into contact with the event (either bumps
into it for events that are set to the same level as characters,
or moves into the same square as the event for those set
below or above the characters) the event starts.
http://www.rpgmakerweb.com/
If the player is standing still and the event bumps
into him, it will not activate.
4
Make Your Own Game Tutorial X: Events Part 3
Interaction Trigger: Event Touch
What is this used for
The main use for this is anything that MOVES that
should affect the player. Combined with movement routes,
this can create a variety of things.
Examples include: Monsters that chase the players,
moving boulders, spinning blades, or any other event that
you want to be able to “hit” the player.
Event touch is important for when you want the
environment to interact with the player, as opposed to the
player interacting with the environment.
Things to keep in mind
Remember that unlike Player Touch, this activates
whether the player touches the event or the event touches
the player. This means that the Player standing still will not
prevent the event from activating.
How it works
This works a lot like Player Touch, except it activates
whether you touch the event, or the event touches you.
Remember that event priority, much like with Player
Touch determines whether the event needs to bump intot
he player, or needs to be in the same square as the player.
http://www.rpgmakerweb.com/
Also, if the event does not move, this operates
identically to Player Touch. Since the event can’t move into
the player, it only activates when the Player moves into it,
exactly like Player Touch.
5
Make Your Own Game Tutorial X: Events Part 3
Automation Trigger: Autorun
What is this used for
Autorun triggers are used most often with cutscenes
that start the moment you walk onto a map.
You can also use it to reset a puzzle in a room, or set
any conditions that need to be set when certain conditions
are met.
Things to keep in mind
The biggest thing to keep in mind with autorun
triggers is that as long as they are running, the player will
not be able to do anything, and that until you end them,
they will repeat forever.
If something needs to happen every time you enter
a map, you can use erase event after it runs. If something
needs to happen once and then never happen again, you
will need to use some form of switch/self switch condition
and event pages to keep it from occuring again.
How it works
The Autorun trigger will start whenever the conditions
are met. If the event page conditions are met (event pages
will be talked about later in this tutorial), and you are on the
same map as the event, it triggers. It will loop indefinitely
until the conditions are no longer met.
http://www.rpgmakerweb.com/
You don’t need to worry about this RIGHT now,
as we are going to be covering using event pages to end
events further into this tutorial. Just remember that this is
a consideration you will need to make.
6
Make Your Own Game Tutorial X: Events Part 3
Automation Trigger: Parallel Process
What is this used for
Parallel Process triggers can be used for anything
where you need to constantly check for certain conditions.
Examples of use include: Keeping track of the state of
a timer, checking for a button press by the player, keeping
track of the coordinates of the player or certain events,
having a flash of lightning occur at certain intervals, etc. It
can also be used in a lot of timed events, such as farming
systems.
Things to keep in mind
How it works
As with autorun events, you will need to keep in
mind that to stop it from repeating, you will need to end
the process in some way, either through Erase Event (if you
want it to start again the next time you enter the map), or
using Event Pages and conditions.
Parallel Process triggers work similar to autorun
triggers in that they start whenever the Event Page conditions
are met, but instead of stopping player action, they run in
the background allowing the player character to continue
on while the process is working.
Another thing though to keep in mind with parallel
process triggers is that you do not want to run too many
at a time. The more of these events you have running, the
more chance you will encounter a drop in your Frame Rate.
No one wants to play a laggy game!
http://www.rpgmakerweb.com/
7
Make Your Own Game Tutorial X: Events Part 3
Event Pages
As I said before, event pages are basically conditional
branches, but superpowered. Conditional branches only
change how an Event acts once it has started, event pages
on the other hand, can change EVERYTHING about the
Event.
Every event page allows you to change its priority,
autonomous movement (we’ll get to this later), graphic, as
well as the event trigger.
You also get an entire new box to put your event
commands in, meaning that every new page basically acts
like a completely different event.
Page 1 and 2 of a Treasure Chest Event, showing the
Conditions box as well as the Standard Event Options.
To create a new Event Page, just click the “New Event
Page” button. This will create a new tab with another event
page.
The last thing to keep in mind about Event pages
is that the Event Page with the HIGHEST number has
priority. That means that if all the conditions are met for
one or more pages, the one with the hisest page number
will be active.
In the upper left of each event page is the Conditions
box. In this box, you will find options very similar to
the Conditional branches we looked at in Tutorial IX.
Remember that ALL event conditions you have listed must
be met for the page to be active.
http://www.rpgmakerweb.com/
Now let’s look at some common uses for event pages!
8
Make Your Own Game Tutorial X: Events Part 3
Ending an Event
This is by far the most common use of event pages.
When you want an event to “end” and never do anything
anymore, you DON’T use Erase Event.
Instead, you use a conditon, and an event page.
We’ll look again at our Treasure Chest event to learn
how to do this.
First, create a second page. Then, put a condition in
which the event should never do anything any more on this
page.
Generally, if the event is going to be ended from itself,
you will be using a self-switch. In the case of this Treasure
Chest, we will be using this method.
Back on the first page (shown above), include a
command in the event to turn the switch on. Now you no
longer have to worry about that event being triggered!
This is useful, of course, for way more than just
treasure chests. You can use it for any one time event, such
as boss fight events. Its also really useful in combination
with the autorun event trigger to create cutscenes.
http://www.rpgmakerweb.com/
9
Make Your Own Game Tutorial X: Events Part 3
Dividing Up Large Events
Tutorial Wrapup
In this tutorial, we covered Event Triggers, an
important part of the event system that allows you to have
the events start based on different in game situations.
We also covered the basics of Event Pages, and covered
the two most common uses of them.
You won’t be able to use this to divide every large
event, but any event that has a large amount of different
conditional branches at the BEGINNING of the event,
you can divide it into separate pages. Above, I borrowed an
example from a spike trap puzzle I had created previously.
Each page of the event is just as complicated.
It should be mentioned that there are tons of other
reasons to use Event Pages, mostly to do with wanting to
use different Graphics, Movement Routes, or Triggers for
them, but most of these are self-evident once you start
trying to make the event. Keep experimenting and you will
find plenty of other uses for these tools.
Next Tutorial Preview
If your branching is further into the event, its still
possible to use event pages, but you would have to duplicate
the early portions of the event commands.
In the next tutorial, we will finish out our discussion
of Events, first by covering movement routes, and then after
that, we will finally get back to directly creating our game,
making several events for it from start to finish using all the
tools we have learned in the last three tutorials.
http://www.rpgmakerweb.com/
10