Getting a Followers Coordinates

Status
Not open for further replies.

dubiousdeeds

Villager
Member
Joined
Aug 7, 2015
Messages
19
Reaction score
1
First Language
English
Primarily Uses
RMVXA
I'm trying to find a way to get the X and Y coordinate of a specific follower and then place those values into a variable.

This way when a specific event happens I can move my followers based upon where they are located. For example if my follower is a space below me I want them to move up beside me but, if they are already beside me I don't want them to move at all.

Thanks in advance to anyone who can shed some light on this.
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,141
Reaction score
12,416
First Language
English
Primarily Uses
RMMV
How are you making your followers move?

Control Variables: X = Script: $game_followers[#].x
Control Variables: Y = Script: $game_followers[#].y

where # is the follower number, remembering that the first follower is 0, not 1.
 

dubiousdeeds

Villager
Member
Joined
Aug 7, 2015
Messages
19
Reaction score
1
First Language
English
Primarily Uses
RMVXA
How are you making your followers move?

Control Variables: X = Script: $game_followers[#].x
Control Variables: Y = Script: $game_followers[#].y

where # is the follower number, remembering that the first follower is 0, not 1.
Thanks for your response, for moving the followers I'm using Nelderson's "Follower Move Route" script.

Unfortunately I'm getting the attached undefined method when I try your script in the control variable. I tried it on a fresh project too to rule out script conflicts and I received the same error. Any ideas?

This is what I have in the script section of the control variable $game_followers[0].y
 

Attachments

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
39,141
Reaction score
12,416
First Language
English
Primarily Uses
RMMV
Sorry - can you try $game_player.followers[#] instead?
 

slimmmeiske2

Little Red Riding Hood
Global Mod
Joined
Sep 6, 2012
Messages
6,488
Reaction score
4,404
First Language
Dutch
Primarily Uses
RMXP

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

 
Status
Not open for further replies.

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

Latest Threads

Latest Posts

Latest Profile Posts

Please do not buy games from g2a.com. The sellers have total power over you. The website has many scam sellers. It looks cheap, but the key code didn't work.
A while back I was having fun making my own custom tiles, then I hit carpet... why is it so difficult!? Lol.
Weekend is finally here... what would you like to see (?):
1) Pokemon into zelda minish-cap style
or
2) Pokemon into zelda gbc style
or
3) Zelda into pokemon style

#= Choose ===============#
||__[ Full mockup ]_[ Charset ]__||
#=======================#
I know someday I'll start working on this...

I'm so happy that I got Steam achievements to work in my game, thanks in large part to the posts by other RPG Maker devs on this issue!

Forum statistics

Threads
97,943
Messages
948,058
Members
129,191
Latest member
Homerx_666
Top