「When the plan was leaving Shinobu saw his friends through the window and said to himself」
計画が去ろうとしていたとき、シノブはウインドウで彼の友人に会って、自分自身に言いました
http://ejje.weblio.jp/sentence/content/When+the+plan+was+leaving+Shinobu+saw+his+friends+through+the+window+and+said+to+himself