void main() { object oPC = GetClickingObject(); if(GetLocalInt(GetObjectByTag("room12counter"), "exitcounter") == 0) { AssignCommand(oPC, ActionJumpToLocation(GetLocation(GetWaypointByTag("wp_a3_to_r12e")))); } else { if(GetLocalInt(GetObjectByTag("room12counter"), "exitcounter") == 1) { AssignCommand(oPC, ActionJumpToLocation(GetLocation(GetWaypointByTag("wp_a3_to_r12n")))); } else { if(GetLocalInt(GetObjectByTag("room12counter"), "exitcounter") == 2) { AssignCommand(oPC, ActionJumpToLocation(GetLocation(GetWaypointByTag("wp_r3_to_r12")))); } else { if(GetLocalInt(GetObjectByTag("room12counter"), "exitcounter") == 3) { AssignCommand(oPC, ActionJumpToLocation(GetLocation(GetWaypointByTag("wp_a3_to_r12s")))); } } } } }