Jumping

Levi

Veteran
Veteran
Joined
Jun 7, 2012
Messages
798
Reaction score
143
First Language
English
Primarily Uses
**Note** This Tutorial is not meant for new users. It would be a waste of time to type out every step... since most of the steps are very similar. Plus, this tutorial is not about jumping. It's about learning how to use Region IDs in a greater way... since very few people use them to their full potential.

So I'll just provide you the knowledge that you need, and leave it at that.

-This tutorial will hopefully shed some light on how remarkable Region IDs can be. Very few people seem to use them to their full potential.

============================================================================================================================

============================================================================================================================

"Jumping"


Info:

-This tutorial will show you how to check what Region ID the player is on, in real time, and use it as a condition.

Requirement:

Yanfly's "Button Common Events" script: http://yanflychannel...-common-events/

For details on set-up, read the header of the script.

1. Set up an event, as seen below:

Things to note** It must be Parallel Process.

-----What is Parallel Process? It is where an event is essentially "looping". It is best to use when you need to regularly check a Variable. So in this case... I have v[0001] receive the Player's X coordinate, and v[0002] receive the Y coordinate. I then "Get Location Info" (in this case, Region ID) using the the Player's X and Y as destination for the 'check' and have v[0003] receive that data.

This step is important, because branches that we set up later will need to check these Vars constantly, and the variables must be "current" or updated to ensure that everything goes smoothly. With this set-up, v[0003] will always contain the Region ID that the player is on at any given time.

You can imagine how useful this is. You can now set up events (parallel process, or otherwise) to pull v[0003] for whatever you want. For example:

1. Custom pass-ability.

2. "Proximity" processes that, for example, will reveal chests or items (or make a sound... like Nirnroot) once you're close enough to that item (on a certain ID).

3. Say you want your character to have a bonus in Tall Grass. You can mark that tall grass with an ID, and have an event to check that ID. If on the tall grass, a skill/state/buff can be added.

4. Custom sounds scape. Set up IDs for water, grass etc. and have a sound play while on that ID. Such as splashing, or rustling.

The list goes on and on. Really... any event you can imagine, can be triggered by ID.

2. You will want to set up a common event, as seen below:

Things to note** Make sure that the trigger is set to "None". Ensure that you set the player to "Through" during jumps to the left and right, as it will allow the player to jump in front of trees, walls etc (assuming there is no ID restricting it.)

-----What does this event do? Well, I first want to say that this is only one of 6 Branches set up (each independent of each other). As you can see by the comment, it is for Jumping to the Left. This event first ensures that the Player is not on a restricted ID (in this case, ID !). Why does it matter if the Player is on any given ID? Because I've placed Region IDs along the edges of "un-jumpable" things, such as Buildings and walls. If the player isn't on a restricted ID, the jump begins. A simple "Move Upper Left". At this point, it checks again to see if the Player is on ID 1. If not, the jump concludes with a "Move Lower Left". Note** If the player ends up on ID 1 mid-jump, it will simply move the Player down one tile to simulate hitting and sliding down the wall.

3. Place your Region IDs

As you can see... I've used ID 1 to restrict the Sides, and Top of areas. Restriction depends on the direction the player is facing. I've used a separate ID for the bottoms of things. This is because if you were to jump, while beneath ID 1, it would see you as facing left or right and treat you ask if you where trying to jump into a wall (perpendicular) even though you're moving parallel to i.t

4. Assign a button (in Yanfly's script) to your common event.

============================================================================================================================

============================================================================================================================

That is pretty well it. You can also set up additional IDs (see ID 63 in screenies above) to allow specialized movement. So, with the passage along that wall (removed a couple ID 1s) I can jump up onto that wall. Once on the wall, I could jump off it at the end (or you could simulate a "climb/ladder" event).

So you can do all sorts of cool pass-ability/movement tricks with Region IDs. For example, you could make an Assassin's Creed clone, with jumps and climbing.

If any of this in unclear, please let me know. If you have any questions, or need more info on a specific area, don't hesitate to ask!

.
 
Last edited by a moderator:

Mako

Veteran
Veteran
Joined
Mar 13, 2012
Messages
276
Reaction score
48
First Language
English
Primarily Uses
Thanks this is great I'll give it a try!
 
Joined
Jun 26, 2012
Messages
209
Reaction score
9
First Language
English
Primarily Uses
I can't view the script... it just download a file with " .rb " format. What do i have to do with that????

EDIT:- ok i got it.... :D somone delete it

Thanx to u LEVI W, now i understand what are region ids :D
 
Last edited by a moderator:

MooshraKun

Making Dreams Stand Up
Veteran
Joined
Jul 11, 2012
Messages
238
Reaction score
11
First Language
Lokota
Just open it up with a text program like microsoft word or notepad I had this problem before to its really simple. RB is a ruby text file that no matter what text program you open it in it won't screw up the script.

Also Victor just made an official jumping script system here requires three or four scripts but works don't want this comment to go against the tutorial or anything though.

Victor Jumping system:
 
Last edited by a moderator:
Joined
Jun 26, 2012
Messages
209
Reaction score
9
First Language
English
Primarily Uses
Yeah i know... i am using it... i just tested it so i could get to know what are region ids :D
 
Last edited by a moderator:

RyanA

Happy Cat
Veteran
Joined
Jun 28, 2012
Messages
2,423
Reaction score
230
First Language
English
Primarily Uses
Schweet, been waiting for this, great tutorial, Levi :3 But I think I've been too busy braining for summer contest as I'm alte by 7 days 3:
 

rodrrj

Villager
Member
Joined
Jul 25, 2012
Messages
5
Reaction score
0
First Language
English
Primarily Uses
I have a question.How do i setup and use the Yanfly's script?
 

Levi

Veteran
Veteran
Joined
Jun 7, 2012
Messages
798
Reaction score
143
First Language
English
Primarily Uses
I have a question.How do i setup and use the Yanfly's script?
1. Copy and Paste beneath "Materials" in the Script Editor

2. Assign a button (within the script, read the header for more detail) to a common event.
 

rodrrj

Villager
Member
Joined
Jul 25, 2012
Messages
5
Reaction score
0
First Language
English
Primarily Uses

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c
So I was playing with filters and this looked interesting...

Versus the normal look...

Kind of gives a very different feel. :LZSexcite:
To whom ever person or persons who re-did the DS/DS+ asset packs for MV (as in, they are all 48x48, and not just x2 the pixel scale) .... THANK-YOU!!!!!!!!! XwwwwX

Forum statistics

Threads
105,853
Messages
1,016,986
Members
137,561
Latest member
visploo100
Top