Check Vehicle Location

Is there any way to create a conditional based on the location of your vehicles?

I have a game with a lot of different means of transportation, including fast travel. It creates a lot of problems with continuity to have your ship's crew stranded on the other side of the world, and I'd like to be able to move the ship around based on conditionals.

Thanks!
Hi there!
Sure it's a way!
But I don't use vehicles very often, but in the console, you can see this:
Spoiler
bTSwvvI.png
So if you put in a script call:
Code:
$gameMap._vehicles[0].x
It will return to you the position X of the vehicle in array 0.
If you put
Code:
$gameMap._vehicles[0].type
It will return the type of the vehicle.
So, with a little eventing, you can find your way.

I don't know if the $gameMap._vehicles[0] will be always the boat. Or it depends on the order that you put the vehicles on the map.
If no one helps you, tomorrow I will try to find a way. It too late here in Brazil now ^^
there is also a nice vehicle location plugin (using region) using this plugin.
it doesn't really check, but it let you decide where to go on board and off the vehicle
so they just cant go on and off where they pleased 🙂
Hi there!
Sure it's a way!
But I don't use vehicles very often, but in the console, you can see this:
Spoiler
bTSwvvI.png
So if you put in a script call:
Code:
$gameMap._vehicles[0].x
It will return to you the position X of the vehicle in array 0.
If you put
Code:
$gameMap._vehicles[0].type
It will return the type of the vehicle.
So, with a little eventing, you can find your way.

I don't know if the $gameMap._vehicles[0] will be always the boat. Or it depends on the order that you put the vehicles on the map.
If no one helps you, tomorrow I will try to find a way. It too late here in Brazil now ^^
Thanks for this! I'll play around and try to figure it out.
Download the Demo and play with that, if it suit your needs, good luck on your project ^^.

Original thread: https://forums.rpgmakerweb.com/threads/check-vehicle-location.115019/