Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: tombom62 on Thu 05/02/2009 18:32:41

Title: function room_Leave(x) problem. HELP!
Post by: tombom62 on Thu 05/02/2009 18:32:41
OK, so, I'm crazy, and I JUST upgraded from AGS 2.7x, and I made a new room, and I need it to go to a new room when you go to the left or right, so my script is like this:

Quote
// room script file

function room_LeaveLeft()
{
player.ChangeRoom(6, 16, 15);
}

function room_LeaveRight()
{
player.ChangeRoom(5, 16, 187);
}
what the heck did I do wrong?
Title: Re: function room_Leave(x) problem. HELP!
Post by: monkey0506 on Thu 05/02/2009 19:37:31
Do you have it linked in the events pane? If you imported it should have done it automagically, otherwise, open the room. Select the lightning bolt icon on the right hand-side. Enter the name of the functions appropriately. Save.