Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: xenogia on Tue 05/05/2009 01:39:10

Title: Moving to character easier without having to specific x and y
Post by: xenogia on Tue 05/05/2009 01:39:10
I was wondering if there was an easier way to specify the playable to character to walk to another character.  At the moment I have to trial and error the x-y coordinates which can be painful.. Is there another way?
Title: Re: Moving to character easier without having to specific x and y
Post by: Gilbert on Tue 05/05/2009 01:53:31
You can just do something like:

player.Walk(eDog.x, eDog.y);
Title: Re: Moving to character easier without having to specific x and y
Post by: Trent R on Tue 05/05/2009 01:56:47
player.FollowCharacter(cPerson);
player.Walk(cPerson.x-5, cPerson.y-42);

I'm out the door, but these should both push you in the right direction.

~Trent