Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Grizzly on Tue 21/11/2017 17:38:23

Title: How to make the character start in the place I want for each room?
Post by: Grizzly on Tue 21/11/2017 17:38:23
Let's say I make my character take a door to the left in a room. I want him to start at the right side of the other room for it to make sense. How do I do that?
Title: Re: How to make the character start in the place I want for each room?
Post by: Crimson Wizard on Tue 21/11/2017 18:17:35
From the manual:

Quote
ChangeRoom

Character.ChangeRoom(int room_number, optional int x, optional int y, optional CharacterDirection direction)

Changes the room that the character is in.
If you call this on the player character, then the game will move into the new room with them.

<...>

Optionally, you can include an X and Y co-ordinate (you must include either both or neither). If you do so, then the character will also be moved to the specified co-ordinates in the new room.

Optionally, you can also include direction parameter, that determines which direction this character will be facing after room change.
Title: Re: How to make the character start in the place I want for each room?
Post by: Snarky on Tue 21/11/2017 18:19:39
And yes, you really should read the manual, at least get to know the different sections so you know where to look stuff up.
Title: Re: How to make the character start in the place I want for each room?
Post by: Grizzly on Wed 22/11/2017 00:50:09
Oh my! I really looked everywere in the manual and coudn't find it! So sorry! But thank you!!