Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: BerserkerTails on Tue 02/12/2003 00:21:02

Title: Moving an NPC from one room to another using specific coordinates...
Post by: BerserkerTails on Tue 02/12/2003 00:21:02
Is there a way to do this? Right now I'm using the code:

character[3].room = 10

Of course, this puts the character in the new room at the position it was at previously. Therefore I added a MoveCharacterBlocking for the character on the new room before it fades in, but this adds a ghastly pause while waiting for the character to move...

Thanks in advance for any help you can give me!
Title: Re:Moving an NPC from one room to another using specific coordinates...
Post by: on Tue 02/12/2003 00:33:10
I agree that it would be nice to have a NewRoomEx for NPCs.

The workaround is to add:

character[3].x=80;
character[3].y=72;

This can go right after your character[3].room=10 command.
Title: Re:Moving an NPC from one room to another using specific coordinates...
Post by: BerserkerTails on Tue 02/12/2003 00:40:22
Thanks Quintaros! That fixed my problem quite nicely!