Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Anralore on Sat 04/09/2021 16:56:21

Title: How to Test For Room
Post by: Anralore on Sat 04/09/2021 16:56:21
Is there something along the lines of:

Code (ags) Select

if (currentroom = 1) {
   playvideo("Room_1_exit", )
}
if (currentroom = 2) {
   playvideo("Room_2_exit", )
}
if (currentroom = 3) {
   playvideo("Room_3_exit", )
}
Title: Re: How to Test For Room
Post by: Crimson Wizard on Sat 04/09/2021 17:14:02
Yes, it's "player.Room". There's also "player.PreviousRoom" to check what was the last room player came from.
Title: Re: How to Test For Room
Post by: Slasher on Sat 04/09/2021 17:15:24
Code (ags) Select

{
if {

}
else if {


}
else if {

}
}