fixed error with multiple scene support